1// Copyright 2019 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 DCM/DFA Reporting And Trafficking 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.1"
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.1"
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	gensupport "google.golang.org/api/gensupport"
57	googleapi "google.golang.org/api/googleapi"
58	option "google.golang.org/api/option"
59	htransport "google.golang.org/api/transport/http"
60)
61
62// Always reference these packages, just in case the auto-generated code
63// below doesn't.
64var _ = bytes.NewBuffer
65var _ = strconv.Itoa
66var _ = fmt.Sprintf
67var _ = json.NewDecoder
68var _ = io.Copy
69var _ = url.Parse
70var _ = gensupport.MarshalJSON
71var _ = googleapi.Version
72var _ = errors.New
73var _ = strings.Replace
74var _ = context.Canceled
75
76const apiId = "dfareporting:v3.1"
77const apiName = "dfareporting"
78const apiVersion = "v3.1"
79const basePath = "https://www.googleapis.com/dfareporting/v3.1/"
80
81// OAuth2 scopes used by this API.
82const (
83	// Manage DoubleClick Digital Marketing conversions
84	DdmconversionsScope = "https://www.googleapis.com/auth/ddmconversions"
85
86	// View and manage DoubleClick for Advertisers reports
87	DfareportingScope = "https://www.googleapis.com/auth/dfareporting"
88
89	// View and manage your DoubleClick Campaign Manager's (DCM) display ad
90	// campaigns
91	DfatraffickingScope = "https://www.googleapis.com/auth/dfatrafficking"
92)
93
94// NewService creates a new Service.
95func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
96	scopesOption := option.WithScopes(
97		"https://www.googleapis.com/auth/ddmconversions",
98		"https://www.googleapis.com/auth/dfareporting",
99		"https://www.googleapis.com/auth/dfatrafficking",
100	)
101	// NOTE: prepend, so we don't override user-specified scopes.
102	opts = append([]option.ClientOption{scopesOption}, opts...)
103	client, endpoint, err := htransport.NewClient(ctx, opts...)
104	if err != nil {
105		return nil, err
106	}
107	s, err := New(client)
108	if err != nil {
109		return nil, err
110	}
111	if endpoint != "" {
112		s.BasePath = endpoint
113	}
114	return s, nil
115}
116
117// New creates a new Service. It uses the provided http.Client for requests.
118//
119// Deprecated: please use NewService instead.
120// To provide a custom HTTP client, use option.WithHTTPClient.
121// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
122func New(client *http.Client) (*Service, error) {
123	if client == nil {
124		return nil, errors.New("client is nil")
125	}
126	s := &Service{client: client, BasePath: basePath}
127	s.AccountActiveAdSummaries = NewAccountActiveAdSummariesService(s)
128	s.AccountPermissionGroups = NewAccountPermissionGroupsService(s)
129	s.AccountPermissions = NewAccountPermissionsService(s)
130	s.AccountUserProfiles = NewAccountUserProfilesService(s)
131	s.Accounts = NewAccountsService(s)
132	s.Ads = NewAdsService(s)
133	s.AdvertiserGroups = NewAdvertiserGroupsService(s)
134	s.AdvertiserLandingPages = NewAdvertiserLandingPagesService(s)
135	s.Advertisers = NewAdvertisersService(s)
136	s.Browsers = NewBrowsersService(s)
137	s.CampaignCreativeAssociations = NewCampaignCreativeAssociationsService(s)
138	s.Campaigns = NewCampaignsService(s)
139	s.ChangeLogs = NewChangeLogsService(s)
140	s.Cities = NewCitiesService(s)
141	s.ConnectionTypes = NewConnectionTypesService(s)
142	s.ContentCategories = NewContentCategoriesService(s)
143	s.Conversions = NewConversionsService(s)
144	s.Countries = NewCountriesService(s)
145	s.CreativeAssets = NewCreativeAssetsService(s)
146	s.CreativeFieldValues = NewCreativeFieldValuesService(s)
147	s.CreativeFields = NewCreativeFieldsService(s)
148	s.CreativeGroups = NewCreativeGroupsService(s)
149	s.Creatives = NewCreativesService(s)
150	s.DimensionValues = NewDimensionValuesService(s)
151	s.DirectorySiteContacts = NewDirectorySiteContactsService(s)
152	s.DirectorySites = NewDirectorySitesService(s)
153	s.DynamicTargetingKeys = NewDynamicTargetingKeysService(s)
154	s.EventTags = NewEventTagsService(s)
155	s.Files = NewFilesService(s)
156	s.FloodlightActivities = NewFloodlightActivitiesService(s)
157	s.FloodlightActivityGroups = NewFloodlightActivityGroupsService(s)
158	s.FloodlightConfigurations = NewFloodlightConfigurationsService(s)
159	s.InventoryItems = NewInventoryItemsService(s)
160	s.Languages = NewLanguagesService(s)
161	s.Metros = NewMetrosService(s)
162	s.MobileApps = NewMobileAppsService(s)
163	s.MobileCarriers = NewMobileCarriersService(s)
164	s.OperatingSystemVersions = NewOperatingSystemVersionsService(s)
165	s.OperatingSystems = NewOperatingSystemsService(s)
166	s.OrderDocuments = NewOrderDocumentsService(s)
167	s.Orders = NewOrdersService(s)
168	s.PlacementGroups = NewPlacementGroupsService(s)
169	s.PlacementStrategies = NewPlacementStrategiesService(s)
170	s.Placements = NewPlacementsService(s)
171	s.PlatformTypes = NewPlatformTypesService(s)
172	s.PostalCodes = NewPostalCodesService(s)
173	s.Projects = NewProjectsService(s)
174	s.Regions = NewRegionsService(s)
175	s.RemarketingListShares = NewRemarketingListSharesService(s)
176	s.RemarketingLists = NewRemarketingListsService(s)
177	s.Reports = NewReportsService(s)
178	s.Sites = NewSitesService(s)
179	s.Sizes = NewSizesService(s)
180	s.Subaccounts = NewSubaccountsService(s)
181	s.TargetableRemarketingLists = NewTargetableRemarketingListsService(s)
182	s.TargetingTemplates = NewTargetingTemplatesService(s)
183	s.UserProfiles = NewUserProfilesService(s)
184	s.UserRolePermissionGroups = NewUserRolePermissionGroupsService(s)
185	s.UserRolePermissions = NewUserRolePermissionsService(s)
186	s.UserRoles = NewUserRolesService(s)
187	s.VideoFormats = NewVideoFormatsService(s)
188	return s, nil
189}
190
191type Service struct {
192	client    *http.Client
193	BasePath  string // API endpoint base URL
194	UserAgent string // optional additional User-Agent fragment
195
196	AccountActiveAdSummaries *AccountActiveAdSummariesService
197
198	AccountPermissionGroups *AccountPermissionGroupsService
199
200	AccountPermissions *AccountPermissionsService
201
202	AccountUserProfiles *AccountUserProfilesService
203
204	Accounts *AccountsService
205
206	Ads *AdsService
207
208	AdvertiserGroups *AdvertiserGroupsService
209
210	AdvertiserLandingPages *AdvertiserLandingPagesService
211
212	Advertisers *AdvertisersService
213
214	Browsers *BrowsersService
215
216	CampaignCreativeAssociations *CampaignCreativeAssociationsService
217
218	Campaigns *CampaignsService
219
220	ChangeLogs *ChangeLogsService
221
222	Cities *CitiesService
223
224	ConnectionTypes *ConnectionTypesService
225
226	ContentCategories *ContentCategoriesService
227
228	Conversions *ConversionsService
229
230	Countries *CountriesService
231
232	CreativeAssets *CreativeAssetsService
233
234	CreativeFieldValues *CreativeFieldValuesService
235
236	CreativeFields *CreativeFieldsService
237
238	CreativeGroups *CreativeGroupsService
239
240	Creatives *CreativesService
241
242	DimensionValues *DimensionValuesService
243
244	DirectorySiteContacts *DirectorySiteContactsService
245
246	DirectorySites *DirectorySitesService
247
248	DynamicTargetingKeys *DynamicTargetingKeysService
249
250	EventTags *EventTagsService
251
252	Files *FilesService
253
254	FloodlightActivities *FloodlightActivitiesService
255
256	FloodlightActivityGroups *FloodlightActivityGroupsService
257
258	FloodlightConfigurations *FloodlightConfigurationsService
259
260	InventoryItems *InventoryItemsService
261
262	Languages *LanguagesService
263
264	Metros *MetrosService
265
266	MobileApps *MobileAppsService
267
268	MobileCarriers *MobileCarriersService
269
270	OperatingSystemVersions *OperatingSystemVersionsService
271
272	OperatingSystems *OperatingSystemsService
273
274	OrderDocuments *OrderDocumentsService
275
276	Orders *OrdersService
277
278	PlacementGroups *PlacementGroupsService
279
280	PlacementStrategies *PlacementStrategiesService
281
282	Placements *PlacementsService
283
284	PlatformTypes *PlatformTypesService
285
286	PostalCodes *PostalCodesService
287
288	Projects *ProjectsService
289
290	Regions *RegionsService
291
292	RemarketingListShares *RemarketingListSharesService
293
294	RemarketingLists *RemarketingListsService
295
296	Reports *ReportsService
297
298	Sites *SitesService
299
300	Sizes *SizesService
301
302	Subaccounts *SubaccountsService
303
304	TargetableRemarketingLists *TargetableRemarketingListsService
305
306	TargetingTemplates *TargetingTemplatesService
307
308	UserProfiles *UserProfilesService
309
310	UserRolePermissionGroups *UserRolePermissionGroupsService
311
312	UserRolePermissions *UserRolePermissionsService
313
314	UserRoles *UserRolesService
315
316	VideoFormats *VideoFormatsService
317}
318
319func (s *Service) userAgent() string {
320	if s.UserAgent == "" {
321		return googleapi.UserAgent
322	}
323	return googleapi.UserAgent + " " + s.UserAgent
324}
325
326func NewAccountActiveAdSummariesService(s *Service) *AccountActiveAdSummariesService {
327	rs := &AccountActiveAdSummariesService{s: s}
328	return rs
329}
330
331type AccountActiveAdSummariesService struct {
332	s *Service
333}
334
335func NewAccountPermissionGroupsService(s *Service) *AccountPermissionGroupsService {
336	rs := &AccountPermissionGroupsService{s: s}
337	return rs
338}
339
340type AccountPermissionGroupsService struct {
341	s *Service
342}
343
344func NewAccountPermissionsService(s *Service) *AccountPermissionsService {
345	rs := &AccountPermissionsService{s: s}
346	return rs
347}
348
349type AccountPermissionsService struct {
350	s *Service
351}
352
353func NewAccountUserProfilesService(s *Service) *AccountUserProfilesService {
354	rs := &AccountUserProfilesService{s: s}
355	return rs
356}
357
358type AccountUserProfilesService struct {
359	s *Service
360}
361
362func NewAccountsService(s *Service) *AccountsService {
363	rs := &AccountsService{s: s}
364	return rs
365}
366
367type AccountsService struct {
368	s *Service
369}
370
371func NewAdsService(s *Service) *AdsService {
372	rs := &AdsService{s: s}
373	return rs
374}
375
376type AdsService struct {
377	s *Service
378}
379
380func NewAdvertiserGroupsService(s *Service) *AdvertiserGroupsService {
381	rs := &AdvertiserGroupsService{s: s}
382	return rs
383}
384
385type AdvertiserGroupsService struct {
386	s *Service
387}
388
389func NewAdvertiserLandingPagesService(s *Service) *AdvertiserLandingPagesService {
390	rs := &AdvertiserLandingPagesService{s: s}
391	return rs
392}
393
394type AdvertiserLandingPagesService struct {
395	s *Service
396}
397
398func NewAdvertisersService(s *Service) *AdvertisersService {
399	rs := &AdvertisersService{s: s}
400	return rs
401}
402
403type AdvertisersService struct {
404	s *Service
405}
406
407func NewBrowsersService(s *Service) *BrowsersService {
408	rs := &BrowsersService{s: s}
409	return rs
410}
411
412type BrowsersService struct {
413	s *Service
414}
415
416func NewCampaignCreativeAssociationsService(s *Service) *CampaignCreativeAssociationsService {
417	rs := &CampaignCreativeAssociationsService{s: s}
418	return rs
419}
420
421type CampaignCreativeAssociationsService struct {
422	s *Service
423}
424
425func NewCampaignsService(s *Service) *CampaignsService {
426	rs := &CampaignsService{s: s}
427	return rs
428}
429
430type CampaignsService struct {
431	s *Service
432}
433
434func NewChangeLogsService(s *Service) *ChangeLogsService {
435	rs := &ChangeLogsService{s: s}
436	return rs
437}
438
439type ChangeLogsService struct {
440	s *Service
441}
442
443func NewCitiesService(s *Service) *CitiesService {
444	rs := &CitiesService{s: s}
445	return rs
446}
447
448type CitiesService struct {
449	s *Service
450}
451
452func NewConnectionTypesService(s *Service) *ConnectionTypesService {
453	rs := &ConnectionTypesService{s: s}
454	return rs
455}
456
457type ConnectionTypesService struct {
458	s *Service
459}
460
461func NewContentCategoriesService(s *Service) *ContentCategoriesService {
462	rs := &ContentCategoriesService{s: s}
463	return rs
464}
465
466type ContentCategoriesService struct {
467	s *Service
468}
469
470func NewConversionsService(s *Service) *ConversionsService {
471	rs := &ConversionsService{s: s}
472	return rs
473}
474
475type ConversionsService struct {
476	s *Service
477}
478
479func NewCountriesService(s *Service) *CountriesService {
480	rs := &CountriesService{s: s}
481	return rs
482}
483
484type CountriesService struct {
485	s *Service
486}
487
488func NewCreativeAssetsService(s *Service) *CreativeAssetsService {
489	rs := &CreativeAssetsService{s: s}
490	return rs
491}
492
493type CreativeAssetsService struct {
494	s *Service
495}
496
497func NewCreativeFieldValuesService(s *Service) *CreativeFieldValuesService {
498	rs := &CreativeFieldValuesService{s: s}
499	return rs
500}
501
502type CreativeFieldValuesService struct {
503	s *Service
504}
505
506func NewCreativeFieldsService(s *Service) *CreativeFieldsService {
507	rs := &CreativeFieldsService{s: s}
508	return rs
509}
510
511type CreativeFieldsService struct {
512	s *Service
513}
514
515func NewCreativeGroupsService(s *Service) *CreativeGroupsService {
516	rs := &CreativeGroupsService{s: s}
517	return rs
518}
519
520type CreativeGroupsService struct {
521	s *Service
522}
523
524func NewCreativesService(s *Service) *CreativesService {
525	rs := &CreativesService{s: s}
526	return rs
527}
528
529type CreativesService struct {
530	s *Service
531}
532
533func NewDimensionValuesService(s *Service) *DimensionValuesService {
534	rs := &DimensionValuesService{s: s}
535	return rs
536}
537
538type DimensionValuesService struct {
539	s *Service
540}
541
542func NewDirectorySiteContactsService(s *Service) *DirectorySiteContactsService {
543	rs := &DirectorySiteContactsService{s: s}
544	return rs
545}
546
547type DirectorySiteContactsService struct {
548	s *Service
549}
550
551func NewDirectorySitesService(s *Service) *DirectorySitesService {
552	rs := &DirectorySitesService{s: s}
553	return rs
554}
555
556type DirectorySitesService struct {
557	s *Service
558}
559
560func NewDynamicTargetingKeysService(s *Service) *DynamicTargetingKeysService {
561	rs := &DynamicTargetingKeysService{s: s}
562	return rs
563}
564
565type DynamicTargetingKeysService struct {
566	s *Service
567}
568
569func NewEventTagsService(s *Service) *EventTagsService {
570	rs := &EventTagsService{s: s}
571	return rs
572}
573
574type EventTagsService struct {
575	s *Service
576}
577
578func NewFilesService(s *Service) *FilesService {
579	rs := &FilesService{s: s}
580	return rs
581}
582
583type FilesService struct {
584	s *Service
585}
586
587func NewFloodlightActivitiesService(s *Service) *FloodlightActivitiesService {
588	rs := &FloodlightActivitiesService{s: s}
589	return rs
590}
591
592type FloodlightActivitiesService struct {
593	s *Service
594}
595
596func NewFloodlightActivityGroupsService(s *Service) *FloodlightActivityGroupsService {
597	rs := &FloodlightActivityGroupsService{s: s}
598	return rs
599}
600
601type FloodlightActivityGroupsService struct {
602	s *Service
603}
604
605func NewFloodlightConfigurationsService(s *Service) *FloodlightConfigurationsService {
606	rs := &FloodlightConfigurationsService{s: s}
607	return rs
608}
609
610type FloodlightConfigurationsService struct {
611	s *Service
612}
613
614func NewInventoryItemsService(s *Service) *InventoryItemsService {
615	rs := &InventoryItemsService{s: s}
616	return rs
617}
618
619type InventoryItemsService struct {
620	s *Service
621}
622
623func NewLanguagesService(s *Service) *LanguagesService {
624	rs := &LanguagesService{s: s}
625	return rs
626}
627
628type LanguagesService struct {
629	s *Service
630}
631
632func NewMetrosService(s *Service) *MetrosService {
633	rs := &MetrosService{s: s}
634	return rs
635}
636
637type MetrosService struct {
638	s *Service
639}
640
641func NewMobileAppsService(s *Service) *MobileAppsService {
642	rs := &MobileAppsService{s: s}
643	return rs
644}
645
646type MobileAppsService struct {
647	s *Service
648}
649
650func NewMobileCarriersService(s *Service) *MobileCarriersService {
651	rs := &MobileCarriersService{s: s}
652	return rs
653}
654
655type MobileCarriersService struct {
656	s *Service
657}
658
659func NewOperatingSystemVersionsService(s *Service) *OperatingSystemVersionsService {
660	rs := &OperatingSystemVersionsService{s: s}
661	return rs
662}
663
664type OperatingSystemVersionsService struct {
665	s *Service
666}
667
668func NewOperatingSystemsService(s *Service) *OperatingSystemsService {
669	rs := &OperatingSystemsService{s: s}
670	return rs
671}
672
673type OperatingSystemsService struct {
674	s *Service
675}
676
677func NewOrderDocumentsService(s *Service) *OrderDocumentsService {
678	rs := &OrderDocumentsService{s: s}
679	return rs
680}
681
682type OrderDocumentsService struct {
683	s *Service
684}
685
686func NewOrdersService(s *Service) *OrdersService {
687	rs := &OrdersService{s: s}
688	return rs
689}
690
691type OrdersService struct {
692	s *Service
693}
694
695func NewPlacementGroupsService(s *Service) *PlacementGroupsService {
696	rs := &PlacementGroupsService{s: s}
697	return rs
698}
699
700type PlacementGroupsService struct {
701	s *Service
702}
703
704func NewPlacementStrategiesService(s *Service) *PlacementStrategiesService {
705	rs := &PlacementStrategiesService{s: s}
706	return rs
707}
708
709type PlacementStrategiesService struct {
710	s *Service
711}
712
713func NewPlacementsService(s *Service) *PlacementsService {
714	rs := &PlacementsService{s: s}
715	return rs
716}
717
718type PlacementsService struct {
719	s *Service
720}
721
722func NewPlatformTypesService(s *Service) *PlatformTypesService {
723	rs := &PlatformTypesService{s: s}
724	return rs
725}
726
727type PlatformTypesService struct {
728	s *Service
729}
730
731func NewPostalCodesService(s *Service) *PostalCodesService {
732	rs := &PostalCodesService{s: s}
733	return rs
734}
735
736type PostalCodesService struct {
737	s *Service
738}
739
740func NewProjectsService(s *Service) *ProjectsService {
741	rs := &ProjectsService{s: s}
742	return rs
743}
744
745type ProjectsService struct {
746	s *Service
747}
748
749func NewRegionsService(s *Service) *RegionsService {
750	rs := &RegionsService{s: s}
751	return rs
752}
753
754type RegionsService struct {
755	s *Service
756}
757
758func NewRemarketingListSharesService(s *Service) *RemarketingListSharesService {
759	rs := &RemarketingListSharesService{s: s}
760	return rs
761}
762
763type RemarketingListSharesService struct {
764	s *Service
765}
766
767func NewRemarketingListsService(s *Service) *RemarketingListsService {
768	rs := &RemarketingListsService{s: s}
769	return rs
770}
771
772type RemarketingListsService struct {
773	s *Service
774}
775
776func NewReportsService(s *Service) *ReportsService {
777	rs := &ReportsService{s: s}
778	rs.CompatibleFields = NewReportsCompatibleFieldsService(s)
779	rs.Files = NewReportsFilesService(s)
780	return rs
781}
782
783type ReportsService struct {
784	s *Service
785
786	CompatibleFields *ReportsCompatibleFieldsService
787
788	Files *ReportsFilesService
789}
790
791func NewReportsCompatibleFieldsService(s *Service) *ReportsCompatibleFieldsService {
792	rs := &ReportsCompatibleFieldsService{s: s}
793	return rs
794}
795
796type ReportsCompatibleFieldsService struct {
797	s *Service
798}
799
800func NewReportsFilesService(s *Service) *ReportsFilesService {
801	rs := &ReportsFilesService{s: s}
802	return rs
803}
804
805type ReportsFilesService struct {
806	s *Service
807}
808
809func NewSitesService(s *Service) *SitesService {
810	rs := &SitesService{s: s}
811	return rs
812}
813
814type SitesService struct {
815	s *Service
816}
817
818func NewSizesService(s *Service) *SizesService {
819	rs := &SizesService{s: s}
820	return rs
821}
822
823type SizesService struct {
824	s *Service
825}
826
827func NewSubaccountsService(s *Service) *SubaccountsService {
828	rs := &SubaccountsService{s: s}
829	return rs
830}
831
832type SubaccountsService struct {
833	s *Service
834}
835
836func NewTargetableRemarketingListsService(s *Service) *TargetableRemarketingListsService {
837	rs := &TargetableRemarketingListsService{s: s}
838	return rs
839}
840
841type TargetableRemarketingListsService struct {
842	s *Service
843}
844
845func NewTargetingTemplatesService(s *Service) *TargetingTemplatesService {
846	rs := &TargetingTemplatesService{s: s}
847	return rs
848}
849
850type TargetingTemplatesService struct {
851	s *Service
852}
853
854func NewUserProfilesService(s *Service) *UserProfilesService {
855	rs := &UserProfilesService{s: s}
856	return rs
857}
858
859type UserProfilesService struct {
860	s *Service
861}
862
863func NewUserRolePermissionGroupsService(s *Service) *UserRolePermissionGroupsService {
864	rs := &UserRolePermissionGroupsService{s: s}
865	return rs
866}
867
868type UserRolePermissionGroupsService struct {
869	s *Service
870}
871
872func NewUserRolePermissionsService(s *Service) *UserRolePermissionsService {
873	rs := &UserRolePermissionsService{s: s}
874	return rs
875}
876
877type UserRolePermissionsService struct {
878	s *Service
879}
880
881func NewUserRolesService(s *Service) *UserRolesService {
882	rs := &UserRolesService{s: s}
883	return rs
884}
885
886type UserRolesService struct {
887	s *Service
888}
889
890func NewVideoFormatsService(s *Service) *VideoFormatsService {
891	rs := &VideoFormatsService{s: s}
892	return rs
893}
894
895type VideoFormatsService struct {
896	s *Service
897}
898
899// Account: Contains properties of a Campaign Manager account.
900type Account struct {
901	// AccountPermissionIds: Account permissions assigned to this account.
902	AccountPermissionIds googleapi.Int64s `json:"accountPermissionIds,omitempty"`
903
904	// AccountProfile: Profile for this account. This is a read-only field
905	// that can be left blank.
906	//
907	// Possible values:
908	//   "ACCOUNT_PROFILE_BASIC"
909	//   "ACCOUNT_PROFILE_STANDARD"
910	AccountProfile string `json:"accountProfile,omitempty"`
911
912	// Active: Whether this account is active.
913	Active bool `json:"active,omitempty"`
914
915	// ActiveAdsLimitTier: Maximum number of active ads allowed for this
916	// account.
917	//
918	// Possible values:
919	//   "ACTIVE_ADS_TIER_100K"
920	//   "ACTIVE_ADS_TIER_1M"
921	//   "ACTIVE_ADS_TIER_200K"
922	//   "ACTIVE_ADS_TIER_300K"
923	//   "ACTIVE_ADS_TIER_40K"
924	//   "ACTIVE_ADS_TIER_500K"
925	//   "ACTIVE_ADS_TIER_750K"
926	//   "ACTIVE_ADS_TIER_75K"
927	ActiveAdsLimitTier string `json:"activeAdsLimitTier,omitempty"`
928
929	// ActiveViewOptOut: Whether to serve creatives with Active View tags.
930	// If disabled, viewability data will not be available for any
931	// impressions.
932	ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
933
934	// AvailablePermissionIds: User role permissions available to the user
935	// roles of this account.
936	AvailablePermissionIds googleapi.Int64s `json:"availablePermissionIds,omitempty"`
937
938	// CountryId: ID of the country associated with this account.
939	CountryId int64 `json:"countryId,omitempty,string"`
940
941	// CurrencyId: ID of currency associated with this account. This is a
942	// required field.
943	// Acceptable values are:
944	// - "1" for USD
945	// - "2" for GBP
946	// - "3" for ESP
947	// - "4" for SEK
948	// - "5" for CAD
949	// - "6" for JPY
950	// - "7" for DEM
951	// - "8" for AUD
952	// - "9" for FRF
953	// - "10" for ITL
954	// - "11" for DKK
955	// - "12" for NOK
956	// - "13" for FIM
957	// - "14" for ZAR
958	// - "15" for IEP
959	// - "16" for NLG
960	// - "17" for EUR
961	// - "18" for KRW
962	// - "19" for TWD
963	// - "20" for SGD
964	// - "21" for CNY
965	// - "22" for HKD
966	// - "23" for NZD
967	// - "24" for MYR
968	// - "25" for BRL
969	// - "26" for PTE
970	// - "27" for MXP
971	// - "28" for CLP
972	// - "29" for TRY
973	// - "30" for ARS
974	// - "31" for PEN
975	// - "32" for ILS
976	// - "33" for CHF
977	// - "34" for VEF
978	// - "35" for COP
979	// - "36" for GTQ
980	// - "37" for PLN
981	// - "39" for INR
982	// - "40" for THB
983	// - "41" for IDR
984	// - "42" for CZK
985	// - "43" for RON
986	// - "44" for HUF
987	// - "45" for RUB
988	// - "46" for AED
989	// - "47" for BGN
990	// - "48" for HRK
991	// - "49" for MXN
992	// - "50" for NGN
993	CurrencyId int64 `json:"currencyId,omitempty,string"`
994
995	// DefaultCreativeSizeId: Default placement dimensions for this account.
996	DefaultCreativeSizeId int64 `json:"defaultCreativeSizeId,omitempty,string"`
997
998	// Description: Description of this account.
999	Description string `json:"description,omitempty"`
1000
1001	// Id: ID of this account. This is a read-only, auto-generated field.
1002	Id int64 `json:"id,omitempty,string"`
1003
1004	// Kind: Identifies what kind of resource this is. Value: the fixed
1005	// string "dfareporting#account".
1006	Kind string `json:"kind,omitempty"`
1007
1008	// Locale: Locale of this account.
1009	// Acceptable values are:
1010	// - "cs" (Czech)
1011	// - "de" (German)
1012	// - "en" (English)
1013	// - "en-GB" (English United Kingdom)
1014	// - "es" (Spanish)
1015	// - "fr" (French)
1016	// - "it" (Italian)
1017	// - "ja" (Japanese)
1018	// - "ko" (Korean)
1019	// - "pl" (Polish)
1020	// - "pt-BR" (Portuguese Brazil)
1021	// - "ru" (Russian)
1022	// - "sv" (Swedish)
1023	// - "tr" (Turkish)
1024	// - "zh-CN" (Chinese Simplified)
1025	// - "zh-TW" (Chinese Traditional)
1026	Locale string `json:"locale,omitempty"`
1027
1028	// MaximumImageSize: Maximum image size allowed for this account, in
1029	// kilobytes. Value must be greater than or equal to 1.
1030	MaximumImageSize int64 `json:"maximumImageSize,omitempty,string"`
1031
1032	// Name: Name of this account. This is a required field, and must be
1033	// less than 128 characters long and be globally unique.
1034	Name string `json:"name,omitempty"`
1035
1036	// NielsenOcrEnabled: Whether campaigns created in this account will be
1037	// enabled for Nielsen OCR reach ratings by default.
1038	NielsenOcrEnabled bool `json:"nielsenOcrEnabled,omitempty"`
1039
1040	// ReportsConfiguration: Reporting configuration of this account.
1041	ReportsConfiguration *ReportsConfiguration `json:"reportsConfiguration,omitempty"`
1042
1043	// ShareReportsWithTwitter: Share Path to Conversion reports with
1044	// Twitter.
1045	ShareReportsWithTwitter bool `json:"shareReportsWithTwitter,omitempty"`
1046
1047	// TeaserSizeLimit: File size limit in kilobytes of Rich Media teaser
1048	// creatives. Acceptable values are 1 to 10240, inclusive.
1049	TeaserSizeLimit int64 `json:"teaserSizeLimit,omitempty,string"`
1050
1051	// ServerResponse contains the HTTP response code and headers from the
1052	// server.
1053	googleapi.ServerResponse `json:"-"`
1054
1055	// ForceSendFields is a list of field names (e.g.
1056	// "AccountPermissionIds") to unconditionally include in API requests.
1057	// By default, fields with empty values are omitted from API requests.
1058	// However, any non-pointer, non-interface field appearing in
1059	// ForceSendFields will be sent to the server regardless of whether the
1060	// field is empty or not. This may be used to include empty fields in
1061	// Patch requests.
1062	ForceSendFields []string `json:"-"`
1063
1064	// NullFields is a list of field names (e.g. "AccountPermissionIds") to
1065	// include in API requests with the JSON null value. By default, fields
1066	// with empty values are omitted from API requests. However, any field
1067	// with an empty value appearing in NullFields will be sent to the
1068	// server as null. It is an error if a field in this list has a
1069	// non-empty value. This may be used to include null fields in Patch
1070	// requests.
1071	NullFields []string `json:"-"`
1072}
1073
1074func (s *Account) MarshalJSON() ([]byte, error) {
1075	type NoMethod Account
1076	raw := NoMethod(*s)
1077	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1078}
1079
1080// AccountActiveAdSummary: Gets a summary of active ads in an account.
1081type AccountActiveAdSummary struct {
1082	// AccountId: ID of the account.
1083	AccountId int64 `json:"accountId,omitempty,string"`
1084
1085	// ActiveAds: Ads that have been activated for the account
1086	ActiveAds int64 `json:"activeAds,omitempty,string"`
1087
1088	// ActiveAdsLimitTier: Maximum number of active ads allowed for the
1089	// account.
1090	//
1091	// Possible values:
1092	//   "ACTIVE_ADS_TIER_100K"
1093	//   "ACTIVE_ADS_TIER_1M"
1094	//   "ACTIVE_ADS_TIER_200K"
1095	//   "ACTIVE_ADS_TIER_300K"
1096	//   "ACTIVE_ADS_TIER_40K"
1097	//   "ACTIVE_ADS_TIER_500K"
1098	//   "ACTIVE_ADS_TIER_750K"
1099	//   "ACTIVE_ADS_TIER_75K"
1100	ActiveAdsLimitTier string `json:"activeAdsLimitTier,omitempty"`
1101
1102	// AvailableAds: Ads that can be activated for the account.
1103	AvailableAds int64 `json:"availableAds,omitempty,string"`
1104
1105	// Kind: Identifies what kind of resource this is. Value: the fixed
1106	// string "dfareporting#accountActiveAdSummary".
1107	Kind string `json:"kind,omitempty"`
1108
1109	// ServerResponse contains the HTTP response code and headers from the
1110	// server.
1111	googleapi.ServerResponse `json:"-"`
1112
1113	// ForceSendFields is a list of field names (e.g. "AccountId") to
1114	// unconditionally include in API requests. By default, fields with
1115	// empty values are omitted from API requests. However, any non-pointer,
1116	// non-interface field appearing in ForceSendFields will be sent to the
1117	// server regardless of whether the field is empty or not. This may be
1118	// used to include empty fields in Patch requests.
1119	ForceSendFields []string `json:"-"`
1120
1121	// NullFields is a list of field names (e.g. "AccountId") to include in
1122	// API requests with the JSON null value. By default, fields with empty
1123	// values are omitted from API requests. However, any field with an
1124	// empty value appearing in NullFields will be sent to the server as
1125	// null. It is an error if a field in this list has a non-empty value.
1126	// This may be used to include null fields in Patch requests.
1127	NullFields []string `json:"-"`
1128}
1129
1130func (s *AccountActiveAdSummary) MarshalJSON() ([]byte, error) {
1131	type NoMethod AccountActiveAdSummary
1132	raw := NoMethod(*s)
1133	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1134}
1135
1136// AccountPermission: AccountPermissions contains information about a
1137// particular account permission. Some features of Campaign Manager
1138// require an account permission to be present in the account.
1139type AccountPermission struct {
1140	// AccountProfiles: Account profiles associated with this account
1141	// permission.
1142	//
1143	// Possible values are:
1144	// - "ACCOUNT_PROFILE_BASIC"
1145	// - "ACCOUNT_PROFILE_STANDARD"
1146	//
1147	// Possible values:
1148	//   "ACCOUNT_PROFILE_BASIC"
1149	//   "ACCOUNT_PROFILE_STANDARD"
1150	AccountProfiles []string `json:"accountProfiles,omitempty"`
1151
1152	// Id: ID of this account permission.
1153	Id int64 `json:"id,omitempty,string"`
1154
1155	// Kind: Identifies what kind of resource this is. Value: the fixed
1156	// string "dfareporting#accountPermission".
1157	Kind string `json:"kind,omitempty"`
1158
1159	// Level: Administrative level required to enable this account
1160	// permission.
1161	//
1162	// Possible values:
1163	//   "ADMINISTRATOR"
1164	//   "USER"
1165	Level string `json:"level,omitempty"`
1166
1167	// Name: Name of this account permission.
1168	Name string `json:"name,omitempty"`
1169
1170	// PermissionGroupId: Permission group of this account permission.
1171	PermissionGroupId int64 `json:"permissionGroupId,omitempty,string"`
1172
1173	// ServerResponse contains the HTTP response code and headers from the
1174	// server.
1175	googleapi.ServerResponse `json:"-"`
1176
1177	// ForceSendFields is a list of field names (e.g. "AccountProfiles") to
1178	// unconditionally include in API requests. By default, fields with
1179	// empty values are omitted from API requests. However, any non-pointer,
1180	// non-interface field appearing in ForceSendFields will be sent to the
1181	// server regardless of whether the field is empty or not. This may be
1182	// used to include empty fields in Patch requests.
1183	ForceSendFields []string `json:"-"`
1184
1185	// NullFields is a list of field names (e.g. "AccountProfiles") to
1186	// include in API requests with the JSON null value. By default, fields
1187	// with empty values are omitted from API requests. However, any field
1188	// with an empty value appearing in NullFields will be sent to the
1189	// server as null. It is an error if a field in this list has a
1190	// non-empty value. This may be used to include null fields in Patch
1191	// requests.
1192	NullFields []string `json:"-"`
1193}
1194
1195func (s *AccountPermission) MarshalJSON() ([]byte, error) {
1196	type NoMethod AccountPermission
1197	raw := NoMethod(*s)
1198	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1199}
1200
1201// AccountPermissionGroup: AccountPermissionGroups contains a mapping of
1202// permission group IDs to names. A permission group is a grouping of
1203// account permissions.
1204type AccountPermissionGroup struct {
1205	// Id: ID of this account permission group.
1206	Id int64 `json:"id,omitempty,string"`
1207
1208	// Kind: Identifies what kind of resource this is. Value: the fixed
1209	// string "dfareporting#accountPermissionGroup".
1210	Kind string `json:"kind,omitempty"`
1211
1212	// Name: Name of this account permission group.
1213	Name string `json:"name,omitempty"`
1214
1215	// ServerResponse contains the HTTP response code and headers from the
1216	// server.
1217	googleapi.ServerResponse `json:"-"`
1218
1219	// ForceSendFields is a list of field names (e.g. "Id") to
1220	// unconditionally include in API requests. By default, fields with
1221	// empty values are omitted from API requests. However, any non-pointer,
1222	// non-interface field appearing in ForceSendFields will be sent to the
1223	// server regardless of whether the field is empty or not. This may be
1224	// used to include empty fields in Patch requests.
1225	ForceSendFields []string `json:"-"`
1226
1227	// NullFields is a list of field names (e.g. "Id") to include in API
1228	// requests with the JSON null value. By default, fields with empty
1229	// values are omitted from API requests. However, any field with an
1230	// empty value appearing in NullFields will be sent to the server as
1231	// null. It is an error if a field in this list has a non-empty value.
1232	// This may be used to include null fields in Patch requests.
1233	NullFields []string `json:"-"`
1234}
1235
1236func (s *AccountPermissionGroup) MarshalJSON() ([]byte, error) {
1237	type NoMethod AccountPermissionGroup
1238	raw := NoMethod(*s)
1239	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1240}
1241
1242// AccountPermissionGroupsListResponse: Account Permission Group List
1243// Response
1244type AccountPermissionGroupsListResponse struct {
1245	// AccountPermissionGroups: Account permission group collection.
1246	AccountPermissionGroups []*AccountPermissionGroup `json:"accountPermissionGroups,omitempty"`
1247
1248	// Kind: Identifies what kind of resource this is. Value: the fixed
1249	// string "dfareporting#accountPermissionGroupsListResponse".
1250	Kind string `json:"kind,omitempty"`
1251
1252	// ServerResponse contains the HTTP response code and headers from the
1253	// server.
1254	googleapi.ServerResponse `json:"-"`
1255
1256	// ForceSendFields is a list of field names (e.g.
1257	// "AccountPermissionGroups") to unconditionally include in API
1258	// requests. By default, fields with empty values are omitted from API
1259	// requests. However, any non-pointer, non-interface field appearing in
1260	// ForceSendFields will be sent to the server regardless of whether the
1261	// field is empty or not. This may be used to include empty fields in
1262	// Patch requests.
1263	ForceSendFields []string `json:"-"`
1264
1265	// NullFields is a list of field names (e.g. "AccountPermissionGroups")
1266	// to include in API requests with the JSON null value. By default,
1267	// fields with empty values are omitted from API requests. However, any
1268	// field with an empty value appearing in NullFields will be sent to the
1269	// server as null. It is an error if a field in this list has a
1270	// non-empty value. This may be used to include null fields in Patch
1271	// requests.
1272	NullFields []string `json:"-"`
1273}
1274
1275func (s *AccountPermissionGroupsListResponse) MarshalJSON() ([]byte, error) {
1276	type NoMethod AccountPermissionGroupsListResponse
1277	raw := NoMethod(*s)
1278	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1279}
1280
1281// AccountPermissionsListResponse: Account Permission List Response
1282type AccountPermissionsListResponse struct {
1283	// AccountPermissions: Account permission collection.
1284	AccountPermissions []*AccountPermission `json:"accountPermissions,omitempty"`
1285
1286	// Kind: Identifies what kind of resource this is. Value: the fixed
1287	// string "dfareporting#accountPermissionsListResponse".
1288	Kind string `json:"kind,omitempty"`
1289
1290	// ServerResponse contains the HTTP response code and headers from the
1291	// server.
1292	googleapi.ServerResponse `json:"-"`
1293
1294	// ForceSendFields is a list of field names (e.g. "AccountPermissions")
1295	// to unconditionally include in API requests. By default, fields with
1296	// empty values are omitted from API requests. However, any non-pointer,
1297	// non-interface field appearing in ForceSendFields will be sent to the
1298	// server regardless of whether the field is empty or not. This may be
1299	// used to include empty fields in Patch requests.
1300	ForceSendFields []string `json:"-"`
1301
1302	// NullFields is a list of field names (e.g. "AccountPermissions") to
1303	// include in API requests with the JSON null value. By default, fields
1304	// with empty values are omitted from API requests. However, any field
1305	// with an empty value appearing in NullFields will be sent to the
1306	// server as null. It is an error if a field in this list has a
1307	// non-empty value. This may be used to include null fields in Patch
1308	// requests.
1309	NullFields []string `json:"-"`
1310}
1311
1312func (s *AccountPermissionsListResponse) MarshalJSON() ([]byte, error) {
1313	type NoMethod AccountPermissionsListResponse
1314	raw := NoMethod(*s)
1315	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1316}
1317
1318// AccountUserProfile: AccountUserProfiles contains properties of a
1319// Campaign Manager user profile. This resource is specifically for
1320// managing user profiles, whereas UserProfiles is for accessing the
1321// API.
1322type AccountUserProfile struct {
1323	// AccountId: Account ID of the user profile. This is a read-only field
1324	// that can be left blank.
1325	AccountId int64 `json:"accountId,omitempty,string"`
1326
1327	// Active: Whether this user profile is active. This defaults to false,
1328	// and must be set true on insert for the user profile to be usable.
1329	Active bool `json:"active,omitempty"`
1330
1331	// AdvertiserFilter: Filter that describes which advertisers are visible
1332	// to the user profile.
1333	AdvertiserFilter *ObjectFilter `json:"advertiserFilter,omitempty"`
1334
1335	// CampaignFilter: Filter that describes which campaigns are visible to
1336	// the user profile.
1337	CampaignFilter *ObjectFilter `json:"campaignFilter,omitempty"`
1338
1339	// Comments: Comments for this user profile.
1340	Comments string `json:"comments,omitempty"`
1341
1342	// Email: Email of the user profile. The email addresss must be linked
1343	// to a Google Account. This field is required on insertion and is
1344	// read-only after insertion.
1345	Email string `json:"email,omitempty"`
1346
1347	// Id: ID of the user profile. This is a read-only, auto-generated
1348	// field.
1349	Id int64 `json:"id,omitempty,string"`
1350
1351	// Kind: Identifies what kind of resource this is. Value: the fixed
1352	// string "dfareporting#accountUserProfile".
1353	Kind string `json:"kind,omitempty"`
1354
1355	// Locale: Locale of the user profile. This is a required
1356	// field.
1357	// Acceptable values are:
1358	// - "cs" (Czech)
1359	// - "de" (German)
1360	// - "en" (English)
1361	// - "en-GB" (English United Kingdom)
1362	// - "es" (Spanish)
1363	// - "fr" (French)
1364	// - "it" (Italian)
1365	// - "ja" (Japanese)
1366	// - "ko" (Korean)
1367	// - "pl" (Polish)
1368	// - "pt-BR" (Portuguese Brazil)
1369	// - "ru" (Russian)
1370	// - "sv" (Swedish)
1371	// - "tr" (Turkish)
1372	// - "zh-CN" (Chinese Simplified)
1373	// - "zh-TW" (Chinese Traditional)
1374	Locale string `json:"locale,omitempty"`
1375
1376	// Name: Name of the user profile. This is a required field. Must be
1377	// less than 64 characters long, must be globally unique, and cannot
1378	// contain whitespace or any of the following characters: "&;"#%,".
1379	Name string `json:"name,omitempty"`
1380
1381	// SiteFilter: Filter that describes which sites are visible to the user
1382	// profile.
1383	SiteFilter *ObjectFilter `json:"siteFilter,omitempty"`
1384
1385	// SubaccountId: Subaccount ID of the user profile. This is a read-only
1386	// field that can be left blank.
1387	SubaccountId int64 `json:"subaccountId,omitempty,string"`
1388
1389	// TraffickerType: Trafficker type of this user profile. This is a
1390	// read-only field.
1391	//
1392	// Possible values:
1393	//   "EXTERNAL_TRAFFICKER"
1394	//   "INTERNAL_NON_TRAFFICKER"
1395	//   "INTERNAL_TRAFFICKER"
1396	TraffickerType string `json:"traffickerType,omitempty"`
1397
1398	// UserAccessType: User type of the user profile. This is a read-only
1399	// field that can be left blank.
1400	//
1401	// Possible values:
1402	//   "INTERNAL_ADMINISTRATOR"
1403	//   "NORMAL_USER"
1404	//   "READ_ONLY_SUPER_USER"
1405	//   "SUPER_USER"
1406	UserAccessType string `json:"userAccessType,omitempty"`
1407
1408	// UserRoleFilter: Filter that describes which user roles are visible to
1409	// the user profile.
1410	UserRoleFilter *ObjectFilter `json:"userRoleFilter,omitempty"`
1411
1412	// UserRoleId: User role ID of the user profile. This is a required
1413	// field.
1414	UserRoleId int64 `json:"userRoleId,omitempty,string"`
1415
1416	// ServerResponse contains the HTTP response code and headers from the
1417	// server.
1418	googleapi.ServerResponse `json:"-"`
1419
1420	// ForceSendFields is a list of field names (e.g. "AccountId") to
1421	// unconditionally include in API requests. By default, fields with
1422	// empty values are omitted from API requests. However, any non-pointer,
1423	// non-interface field appearing in ForceSendFields will be sent to the
1424	// server regardless of whether the field is empty or not. This may be
1425	// used to include empty fields in Patch requests.
1426	ForceSendFields []string `json:"-"`
1427
1428	// NullFields is a list of field names (e.g. "AccountId") to include in
1429	// API requests with the JSON null value. By default, fields with empty
1430	// values are omitted from API requests. However, any field with an
1431	// empty value appearing in NullFields will be sent to the server as
1432	// null. It is an error if a field in this list has a non-empty value.
1433	// This may be used to include null fields in Patch requests.
1434	NullFields []string `json:"-"`
1435}
1436
1437func (s *AccountUserProfile) MarshalJSON() ([]byte, error) {
1438	type NoMethod AccountUserProfile
1439	raw := NoMethod(*s)
1440	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1441}
1442
1443// AccountUserProfilesListResponse: Account User Profile List Response
1444type AccountUserProfilesListResponse struct {
1445	// AccountUserProfiles: Account user profile collection.
1446	AccountUserProfiles []*AccountUserProfile `json:"accountUserProfiles,omitempty"`
1447
1448	// Kind: Identifies what kind of resource this is. Value: the fixed
1449	// string "dfareporting#accountUserProfilesListResponse".
1450	Kind string `json:"kind,omitempty"`
1451
1452	// NextPageToken: Pagination token to be used for the next list
1453	// operation.
1454	NextPageToken string `json:"nextPageToken,omitempty"`
1455
1456	// ServerResponse contains the HTTP response code and headers from the
1457	// server.
1458	googleapi.ServerResponse `json:"-"`
1459
1460	// ForceSendFields is a list of field names (e.g. "AccountUserProfiles")
1461	// to unconditionally include in API requests. By default, fields with
1462	// empty values are omitted from API requests. However, any non-pointer,
1463	// non-interface field appearing in ForceSendFields will be sent to the
1464	// server regardless of whether the field is empty or not. This may be
1465	// used to include empty fields in Patch requests.
1466	ForceSendFields []string `json:"-"`
1467
1468	// NullFields is a list of field names (e.g. "AccountUserProfiles") to
1469	// include in API requests with the JSON null value. By default, fields
1470	// with empty values are omitted from API requests. However, any field
1471	// with an empty value appearing in NullFields will be sent to the
1472	// server as null. It is an error if a field in this list has a
1473	// non-empty value. This may be used to include null fields in Patch
1474	// requests.
1475	NullFields []string `json:"-"`
1476}
1477
1478func (s *AccountUserProfilesListResponse) MarshalJSON() ([]byte, error) {
1479	type NoMethod AccountUserProfilesListResponse
1480	raw := NoMethod(*s)
1481	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1482}
1483
1484// AccountsListResponse: Account List Response
1485type AccountsListResponse struct {
1486	// Accounts: Account collection.
1487	Accounts []*Account `json:"accounts,omitempty"`
1488
1489	// Kind: Identifies what kind of resource this is. Value: the fixed
1490	// string "dfareporting#accountsListResponse".
1491	Kind string `json:"kind,omitempty"`
1492
1493	// NextPageToken: Pagination token to be used for the next list
1494	// operation.
1495	NextPageToken string `json:"nextPageToken,omitempty"`
1496
1497	// ServerResponse contains the HTTP response code and headers from the
1498	// server.
1499	googleapi.ServerResponse `json:"-"`
1500
1501	// ForceSendFields is a list of field names (e.g. "Accounts") to
1502	// unconditionally include in API requests. By default, fields with
1503	// empty values are omitted from API requests. However, any non-pointer,
1504	// non-interface field appearing in ForceSendFields will be sent to the
1505	// server regardless of whether the field is empty or not. This may be
1506	// used to include empty fields in Patch requests.
1507	ForceSendFields []string `json:"-"`
1508
1509	// NullFields is a list of field names (e.g. "Accounts") to include in
1510	// API requests with the JSON null value. By default, fields with empty
1511	// values are omitted from API requests. However, any field with an
1512	// empty value appearing in NullFields will be sent to the server as
1513	// null. It is an error if a field in this list has a non-empty value.
1514	// This may be used to include null fields in Patch requests.
1515	NullFields []string `json:"-"`
1516}
1517
1518func (s *AccountsListResponse) MarshalJSON() ([]byte, error) {
1519	type NoMethod AccountsListResponse
1520	raw := NoMethod(*s)
1521	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1522}
1523
1524// Activities: Represents an activity group.
1525type Activities struct {
1526	// Filters: List of activity filters. The dimension values need to be
1527	// all either of type "dfa:activity" or "dfa:activityGroup".
1528	Filters []*DimensionValue `json:"filters,omitempty"`
1529
1530	// Kind: The kind of resource this is, in this case
1531	// dfareporting#activities.
1532	Kind string `json:"kind,omitempty"`
1533
1534	// MetricNames: List of names of floodlight activity metrics.
1535	MetricNames []string `json:"metricNames,omitempty"`
1536
1537	// ForceSendFields is a list of field names (e.g. "Filters") to
1538	// unconditionally include in API requests. By default, fields with
1539	// empty values are omitted from API requests. However, any non-pointer,
1540	// non-interface field appearing in ForceSendFields will be sent to the
1541	// server regardless of whether the field is empty or not. This may be
1542	// used to include empty fields in Patch requests.
1543	ForceSendFields []string `json:"-"`
1544
1545	// NullFields is a list of field names (e.g. "Filters") to include in
1546	// API requests with the JSON null value. By default, fields with empty
1547	// values are omitted from API requests. However, any field with an
1548	// empty value appearing in NullFields will be sent to the server as
1549	// null. It is an error if a field in this list has a non-empty value.
1550	// This may be used to include null fields in Patch requests.
1551	NullFields []string `json:"-"`
1552}
1553
1554func (s *Activities) MarshalJSON() ([]byte, error) {
1555	type NoMethod Activities
1556	raw := NoMethod(*s)
1557	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1558}
1559
1560// Ad: Contains properties of a Campaign Manager ad.
1561type Ad struct {
1562	// AccountId: Account ID of this ad. This is a read-only field that can
1563	// be left blank.
1564	AccountId int64 `json:"accountId,omitempty,string"`
1565
1566	// Active: Whether this ad is active. When true, archived must be false.
1567	Active bool `json:"active,omitempty"`
1568
1569	// AdvertiserId: Advertiser ID of this ad. This is a required field on
1570	// insertion.
1571	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
1572
1573	// AdvertiserIdDimensionValue: Dimension value for the ID of the
1574	// advertiser. This is a read-only, auto-generated field.
1575	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
1576
1577	// Archived: Whether this ad is archived. When true, active must be
1578	// false.
1579	Archived bool `json:"archived,omitempty"`
1580
1581	// AudienceSegmentId: Audience segment ID that is being targeted for
1582	// this ad. Applicable when type is AD_SERVING_STANDARD_AD.
1583	AudienceSegmentId int64 `json:"audienceSegmentId,omitempty,string"`
1584
1585	// CampaignId: Campaign ID of this ad. This is a required field on
1586	// insertion.
1587	CampaignId int64 `json:"campaignId,omitempty,string"`
1588
1589	// CampaignIdDimensionValue: Dimension value for the ID of the campaign.
1590	// This is a read-only, auto-generated field.
1591	CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
1592
1593	// ClickThroughUrl: Click-through URL for this ad. This is a required
1594	// field on insertion. Applicable when type is AD_SERVING_CLICK_TRACKER.
1595	ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
1596
1597	// ClickThroughUrlSuffixProperties: Click-through URL suffix properties
1598	// for this ad. Applies to the URL in the ad or (if overriding ad
1599	// properties) the URL in the creative.
1600	ClickThroughUrlSuffixProperties *ClickThroughUrlSuffixProperties `json:"clickThroughUrlSuffixProperties,omitempty"`
1601
1602	// Comments: Comments for this ad.
1603	Comments string `json:"comments,omitempty"`
1604
1605	// Compatibility: Compatibility of this ad. Applicable when type is
1606	// AD_SERVING_DEFAULT_AD. DISPLAY and DISPLAY_INTERSTITIAL refer to
1607	// either rendering on desktop or on mobile devices or in mobile apps
1608	// for regular or interstitial ads, respectively. APP and
1609	// APP_INTERSTITIAL are only used for existing default ads. New mobile
1610	// placements must be assigned DISPLAY or DISPLAY_INTERSTITIAL and
1611	// default ads created for those placements will be limited to those
1612	// compatibility types. IN_STREAM_VIDEO refers to rendering in-stream
1613	// video ads developed with the VAST standard.
1614	//
1615	// Possible values:
1616	//   "APP"
1617	//   "APP_INTERSTITIAL"
1618	//   "DISPLAY"
1619	//   "DISPLAY_INTERSTITIAL"
1620	//   "IN_STREAM_AUDIO"
1621	//   "IN_STREAM_VIDEO"
1622	Compatibility string `json:"compatibility,omitempty"`
1623
1624	// CreateInfo: Information about the creation of this ad. This is a
1625	// read-only field.
1626	CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
1627
1628	// CreativeGroupAssignments: Creative group assignments for this ad.
1629	// Applicable when type is AD_SERVING_CLICK_TRACKER. Only one assignment
1630	// per creative group number is allowed for a maximum of two
1631	// assignments.
1632	CreativeGroupAssignments []*CreativeGroupAssignment `json:"creativeGroupAssignments,omitempty"`
1633
1634	// CreativeRotation: Creative rotation for this ad. Applicable when type
1635	// is AD_SERVING_DEFAULT_AD, AD_SERVING_STANDARD_AD, or
1636	// AD_SERVING_TRACKING. When type is AD_SERVING_DEFAULT_AD, this field
1637	// should have exactly one creativeAssignment.
1638	CreativeRotation *CreativeRotation `json:"creativeRotation,omitempty"`
1639
1640	// DayPartTargeting: Time and day targeting information for this ad.
1641	// This field must be left blank if the ad is using a targeting
1642	// template. Applicable when type is AD_SERVING_STANDARD_AD.
1643	DayPartTargeting *DayPartTargeting `json:"dayPartTargeting,omitempty"`
1644
1645	// DefaultClickThroughEventTagProperties: Default click-through event
1646	// tag properties for this ad.
1647	DefaultClickThroughEventTagProperties *DefaultClickThroughEventTagProperties `json:"defaultClickThroughEventTagProperties,omitempty"`
1648
1649	// DeliverySchedule: Delivery schedule information for this ad.
1650	// Applicable when type is AD_SERVING_STANDARD_AD or
1651	// AD_SERVING_TRACKING. This field along with subfields priority and
1652	// impressionRatio are required on insertion when type is
1653	// AD_SERVING_STANDARD_AD.
1654	DeliverySchedule *DeliverySchedule `json:"deliverySchedule,omitempty"`
1655
1656	// DynamicClickTracker: Whether this ad is a dynamic click tracker.
1657	// Applicable when type is AD_SERVING_CLICK_TRACKER. This is a required
1658	// field on insert, and is read-only after insert.
1659	DynamicClickTracker bool `json:"dynamicClickTracker,omitempty"`
1660
1661	// EndTime: Date and time that this ad should stop serving. Must be
1662	// later than the start time. This is a required field on insertion.
1663	EndTime string `json:"endTime,omitempty"`
1664
1665	// EventTagOverrides: Event tag overrides for this ad.
1666	EventTagOverrides []*EventTagOverride `json:"eventTagOverrides,omitempty"`
1667
1668	// GeoTargeting: Geographical targeting information for this ad. This
1669	// field must be left blank if the ad is using a targeting template.
1670	// Applicable when type is AD_SERVING_STANDARD_AD.
1671	GeoTargeting *GeoTargeting `json:"geoTargeting,omitempty"`
1672
1673	// Id: ID of this ad. This is a read-only, auto-generated field.
1674	Id int64 `json:"id,omitempty,string"`
1675
1676	// IdDimensionValue: Dimension value for the ID of this ad. This is a
1677	// read-only, auto-generated field.
1678	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
1679
1680	// KeyValueTargetingExpression: Key-value targeting information for this
1681	// ad. This field must be left blank if the ad is using a targeting
1682	// template. Applicable when type is AD_SERVING_STANDARD_AD.
1683	KeyValueTargetingExpression *KeyValueTargetingExpression `json:"keyValueTargetingExpression,omitempty"`
1684
1685	// Kind: Identifies what kind of resource this is. Value: the fixed
1686	// string "dfareporting#ad".
1687	Kind string `json:"kind,omitempty"`
1688
1689	// LanguageTargeting: Language targeting information for this ad. This
1690	// field must be left blank if the ad is using a targeting template.
1691	// Applicable when type is AD_SERVING_STANDARD_AD.
1692	LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
1693
1694	// LastModifiedInfo: Information about the most recent modification of
1695	// this ad. This is a read-only field.
1696	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
1697
1698	// Name: Name of this ad. This is a required field and must be less than
1699	// 256 characters long.
1700	Name string `json:"name,omitempty"`
1701
1702	// PlacementAssignments: Placement assignments for this ad.
1703	PlacementAssignments []*PlacementAssignment `json:"placementAssignments,omitempty"`
1704
1705	// RemarketingListExpression: Remarketing list targeting expression for
1706	// this ad. This field must be left blank if the ad is using a targeting
1707	// template. Applicable when type is AD_SERVING_STANDARD_AD.
1708	RemarketingListExpression *ListTargetingExpression `json:"remarketingListExpression,omitempty"`
1709
1710	// Size: Size of this ad. Applicable when type is AD_SERVING_DEFAULT_AD.
1711	Size *Size `json:"size,omitempty"`
1712
1713	// SslCompliant: Whether this ad is ssl compliant. This is a read-only
1714	// field that is auto-generated when the ad is inserted or updated.
1715	SslCompliant bool `json:"sslCompliant,omitempty"`
1716
1717	// SslRequired: Whether this ad requires ssl. This is a read-only field
1718	// that is auto-generated when the ad is inserted or updated.
1719	SslRequired bool `json:"sslRequired,omitempty"`
1720
1721	// StartTime: Date and time that this ad should start serving. If
1722	// creating an ad, this field must be a time in the future. This is a
1723	// required field on insertion.
1724	StartTime string `json:"startTime,omitempty"`
1725
1726	// SubaccountId: Subaccount ID of this ad. This is a read-only field
1727	// that can be left blank.
1728	SubaccountId int64 `json:"subaccountId,omitempty,string"`
1729
1730	// TargetingTemplateId: Targeting template ID, used to apply
1731	// preconfigured targeting information to this ad. This cannot be set
1732	// while any of dayPartTargeting, geoTargeting,
1733	// keyValueTargetingExpression, languageTargeting,
1734	// remarketingListExpression, or technologyTargeting are set. Applicable
1735	// when type is AD_SERVING_STANDARD_AD.
1736	TargetingTemplateId int64 `json:"targetingTemplateId,omitempty,string"`
1737
1738	// TechnologyTargeting: Technology platform targeting information for
1739	// this ad. This field must be left blank if the ad is using a targeting
1740	// template. Applicable when type is AD_SERVING_STANDARD_AD.
1741	TechnologyTargeting *TechnologyTargeting `json:"technologyTargeting,omitempty"`
1742
1743	// Type: Type of ad. This is a required field on insertion. Note that
1744	// default ads (AD_SERVING_DEFAULT_AD) cannot be created directly (see
1745	// Creative resource).
1746	//
1747	// Possible values:
1748	//   "AD_SERVING_CLICK_TRACKER"
1749	//   "AD_SERVING_DEFAULT_AD"
1750	//   "AD_SERVING_STANDARD_AD"
1751	//   "AD_SERVING_TRACKING"
1752	Type string `json:"type,omitempty"`
1753
1754	// ServerResponse contains the HTTP response code and headers from the
1755	// server.
1756	googleapi.ServerResponse `json:"-"`
1757
1758	// ForceSendFields is a list of field names (e.g. "AccountId") to
1759	// unconditionally include in API requests. By default, fields with
1760	// empty values are omitted from API requests. However, any non-pointer,
1761	// non-interface field appearing in ForceSendFields will be sent to the
1762	// server regardless of whether the field is empty or not. This may be
1763	// used to include empty fields in Patch requests.
1764	ForceSendFields []string `json:"-"`
1765
1766	// NullFields is a list of field names (e.g. "AccountId") to include in
1767	// API requests with the JSON null value. By default, fields with empty
1768	// values are omitted from API requests. However, any field with an
1769	// empty value appearing in NullFields will be sent to the server as
1770	// null. It is an error if a field in this list has a non-empty value.
1771	// This may be used to include null fields in Patch requests.
1772	NullFields []string `json:"-"`
1773}
1774
1775func (s *Ad) MarshalJSON() ([]byte, error) {
1776	type NoMethod Ad
1777	raw := NoMethod(*s)
1778	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1779}
1780
1781// AdBlockingConfiguration: Campaign ad blocking settings.
1782type AdBlockingConfiguration struct {
1783	// ClickThroughUrl: Click-through URL used by brand-neutral ads. This is
1784	// a required field when overrideClickThroughUrl is set to true.
1785	ClickThroughUrl string `json:"clickThroughUrl,omitempty"`
1786
1787	// CreativeBundleId: ID of a creative bundle to use for this campaign.
1788	// If set, brand-neutral ads will select creatives from this bundle.
1789	// Otherwise, a default transparent pixel will be used.
1790	CreativeBundleId int64 `json:"creativeBundleId,omitempty,string"`
1791
1792	// Enabled: Whether this campaign has enabled ad blocking. When true, ad
1793	// blocking is enabled for placements in the campaign, but this may be
1794	// overridden by site and placement settings. When false, ad blocking is
1795	// disabled for all placements under the campaign, regardless of site
1796	// and placement settings.
1797	Enabled bool `json:"enabled,omitempty"`
1798
1799	// OverrideClickThroughUrl: Whether the brand-neutral ad's click-through
1800	// URL comes from the campaign's creative bundle or the override URL.
1801	// Must be set to true if ad blocking is enabled and no creative bundle
1802	// is configured.
1803	OverrideClickThroughUrl bool `json:"overrideClickThroughUrl,omitempty"`
1804
1805	// ForceSendFields is a list of field names (e.g. "ClickThroughUrl") to
1806	// unconditionally include in API requests. By default, fields with
1807	// empty values are omitted from API requests. However, any non-pointer,
1808	// non-interface field appearing in ForceSendFields will be sent to the
1809	// server regardless of whether the field is empty or not. This may be
1810	// used to include empty fields in Patch requests.
1811	ForceSendFields []string `json:"-"`
1812
1813	// NullFields is a list of field names (e.g. "ClickThroughUrl") to
1814	// include in API requests with the JSON null value. By default, fields
1815	// with empty values are omitted from API requests. However, any field
1816	// with an empty value appearing in NullFields will be sent to the
1817	// server as null. It is an error if a field in this list has a
1818	// non-empty value. This may be used to include null fields in Patch
1819	// requests.
1820	NullFields []string `json:"-"`
1821}
1822
1823func (s *AdBlockingConfiguration) MarshalJSON() ([]byte, error) {
1824	type NoMethod AdBlockingConfiguration
1825	raw := NoMethod(*s)
1826	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1827}
1828
1829// AdSlot: Ad Slot
1830type AdSlot struct {
1831	// Comment: Comment for this ad slot.
1832	Comment string `json:"comment,omitempty"`
1833
1834	// Compatibility: Ad slot compatibility. DISPLAY and
1835	// DISPLAY_INTERSTITIAL refer to rendering either on desktop, mobile
1836	// devices or in mobile apps for regular or interstitial ads
1837	// respectively. APP and APP_INTERSTITIAL are for rendering in mobile
1838	// apps. IN_STREAM_VIDEO refers to rendering in in-stream video ads
1839	// developed with the VAST standard.
1840	//
1841	// Possible values:
1842	//   "APP"
1843	//   "APP_INTERSTITIAL"
1844	//   "DISPLAY"
1845	//   "DISPLAY_INTERSTITIAL"
1846	//   "IN_STREAM_AUDIO"
1847	//   "IN_STREAM_VIDEO"
1848	Compatibility string `json:"compatibility,omitempty"`
1849
1850	// Height: Height of this ad slot.
1851	Height int64 `json:"height,omitempty,string"`
1852
1853	// LinkedPlacementId: ID of the placement from an external platform that
1854	// is linked to this ad slot.
1855	LinkedPlacementId int64 `json:"linkedPlacementId,omitempty,string"`
1856
1857	// Name: Name of this ad slot.
1858	Name string `json:"name,omitempty"`
1859
1860	// PaymentSourceType: Payment source type of this ad slot.
1861	//
1862	// Possible values:
1863	//   "PLANNING_PAYMENT_SOURCE_TYPE_AGENCY_PAID"
1864	//   "PLANNING_PAYMENT_SOURCE_TYPE_PUBLISHER_PAID"
1865	PaymentSourceType string `json:"paymentSourceType,omitempty"`
1866
1867	// Primary: Primary ad slot of a roadblock inventory item.
1868	Primary bool `json:"primary,omitempty"`
1869
1870	// Width: Width of this ad slot.
1871	Width int64 `json:"width,omitempty,string"`
1872
1873	// ForceSendFields is a list of field names (e.g. "Comment") to
1874	// unconditionally include in API requests. By default, fields with
1875	// empty values are omitted from API requests. However, any non-pointer,
1876	// non-interface field appearing in ForceSendFields will be sent to the
1877	// server regardless of whether the field is empty or not. This may be
1878	// used to include empty fields in Patch requests.
1879	ForceSendFields []string `json:"-"`
1880
1881	// NullFields is a list of field names (e.g. "Comment") to include in
1882	// API requests with the JSON null value. By default, fields with empty
1883	// values are omitted from API requests. However, any field with an
1884	// empty value appearing in NullFields will be sent to the server as
1885	// null. It is an error if a field in this list has a non-empty value.
1886	// This may be used to include null fields in Patch requests.
1887	NullFields []string `json:"-"`
1888}
1889
1890func (s *AdSlot) MarshalJSON() ([]byte, error) {
1891	type NoMethod AdSlot
1892	raw := NoMethod(*s)
1893	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1894}
1895
1896// AdsListResponse: Ad List Response
1897type AdsListResponse struct {
1898	// Ads: Ad collection.
1899	Ads []*Ad `json:"ads,omitempty"`
1900
1901	// Kind: Identifies what kind of resource this is. Value: the fixed
1902	// string "dfareporting#adsListResponse".
1903	Kind string `json:"kind,omitempty"`
1904
1905	// NextPageToken: Pagination token to be used for the next list
1906	// operation.
1907	NextPageToken string `json:"nextPageToken,omitempty"`
1908
1909	// ServerResponse contains the HTTP response code and headers from the
1910	// server.
1911	googleapi.ServerResponse `json:"-"`
1912
1913	// ForceSendFields is a list of field names (e.g. "Ads") to
1914	// unconditionally include in API requests. By default, fields with
1915	// empty values are omitted from API requests. However, any non-pointer,
1916	// non-interface field appearing in ForceSendFields will be sent to the
1917	// server regardless of whether the field is empty or not. This may be
1918	// used to include empty fields in Patch requests.
1919	ForceSendFields []string `json:"-"`
1920
1921	// NullFields is a list of field names (e.g. "Ads") to include in API
1922	// requests with the JSON null value. By default, fields with empty
1923	// values are omitted from API requests. However, any field with an
1924	// empty value appearing in NullFields will be sent to the server as
1925	// null. It is an error if a field in this list has a non-empty value.
1926	// This may be used to include null fields in Patch requests.
1927	NullFields []string `json:"-"`
1928}
1929
1930func (s *AdsListResponse) MarshalJSON() ([]byte, error) {
1931	type NoMethod AdsListResponse
1932	raw := NoMethod(*s)
1933	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1934}
1935
1936// Advertiser: Contains properties of a Campaign Manager advertiser.
1937type Advertiser struct {
1938	// AccountId: Account ID of this advertiser.This is a read-only field
1939	// that can be left blank.
1940	AccountId int64 `json:"accountId,omitempty,string"`
1941
1942	// AdvertiserGroupId: ID of the advertiser group this advertiser belongs
1943	// to. You can group advertisers for reporting purposes, allowing you to
1944	// see aggregated information for all advertisers in each group.
1945	AdvertiserGroupId int64 `json:"advertiserGroupId,omitempty,string"`
1946
1947	// ClickThroughUrlSuffix: Suffix added to click-through URL of ad
1948	// creative associations under this advertiser. Must be less than 129
1949	// characters long.
1950	ClickThroughUrlSuffix string `json:"clickThroughUrlSuffix,omitempty"`
1951
1952	// DefaultClickThroughEventTagId: ID of the click-through event tag to
1953	// apply by default to the landing pages of this advertiser's campaigns.
1954	DefaultClickThroughEventTagId int64 `json:"defaultClickThroughEventTagId,omitempty,string"`
1955
1956	// DefaultEmail: Default email address used in sender field for tag
1957	// emails.
1958	DefaultEmail string `json:"defaultEmail,omitempty"`
1959
1960	// FloodlightConfigurationId: Floodlight configuration ID of this
1961	// advertiser. The floodlight configuration ID will be created
1962	// automatically, so on insert this field should be left blank. This
1963	// field can be set to another advertiser's floodlight configuration ID
1964	// in order to share that advertiser's floodlight configuration with
1965	// this advertiser, so long as:
1966	// - This advertiser's original floodlight configuration is not already
1967	// associated with floodlight activities or floodlight activity groups.
1968	//
1969	// - This advertiser's original floodlight configuration is not already
1970	// shared with another advertiser.
1971	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
1972
1973	// FloodlightConfigurationIdDimensionValue: Dimension value for the ID
1974	// of the floodlight configuration. This is a read-only, auto-generated
1975	// field.
1976	FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
1977
1978	// Id: ID of this advertiser. This is a read-only, auto-generated field.
1979	Id int64 `json:"id,omitempty,string"`
1980
1981	// IdDimensionValue: Dimension value for the ID of this advertiser. This
1982	// is a read-only, auto-generated field.
1983	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
1984
1985	// Kind: Identifies what kind of resource this is. Value: the fixed
1986	// string "dfareporting#advertiser".
1987	Kind string `json:"kind,omitempty"`
1988
1989	// Name: Name of this advertiser. This is a required field and must be
1990	// less than 256 characters long and unique among advertisers of the
1991	// same account.
1992	Name string `json:"name,omitempty"`
1993
1994	// OriginalFloodlightConfigurationId: Original floodlight configuration
1995	// before any sharing occurred. Set the floodlightConfigurationId of
1996	// this advertiser to originalFloodlightConfigurationId to unshare the
1997	// advertiser's current floodlight configuration. You cannot unshare an
1998	// advertiser's floodlight configuration if the shared configuration has
1999	// activities associated with any campaign or placement.
2000	OriginalFloodlightConfigurationId int64 `json:"originalFloodlightConfigurationId,omitempty,string"`
2001
2002	// Status: Status of this advertiser.
2003	//
2004	// Possible values:
2005	//   "APPROVED"
2006	//   "ON_HOLD"
2007	Status string `json:"status,omitempty"`
2008
2009	// SubaccountId: Subaccount ID of this advertiser.This is a read-only
2010	// field that can be left blank.
2011	SubaccountId int64 `json:"subaccountId,omitempty,string"`
2012
2013	// Suspended: Suspension status of this advertiser.
2014	Suspended bool `json:"suspended,omitempty"`
2015
2016	// ServerResponse contains the HTTP response code and headers from the
2017	// server.
2018	googleapi.ServerResponse `json:"-"`
2019
2020	// ForceSendFields is a list of field names (e.g. "AccountId") to
2021	// unconditionally include in API requests. By default, fields with
2022	// empty values are omitted from API requests. However, any non-pointer,
2023	// non-interface field appearing in ForceSendFields will be sent to the
2024	// server regardless of whether the field is empty or not. This may be
2025	// used to include empty fields in Patch requests.
2026	ForceSendFields []string `json:"-"`
2027
2028	// NullFields is a list of field names (e.g. "AccountId") to include in
2029	// API requests with the JSON null value. By default, fields with empty
2030	// values are omitted from API requests. However, any field with an
2031	// empty value appearing in NullFields will be sent to the server as
2032	// null. It is an error if a field in this list has a non-empty value.
2033	// This may be used to include null fields in Patch requests.
2034	NullFields []string `json:"-"`
2035}
2036
2037func (s *Advertiser) MarshalJSON() ([]byte, error) {
2038	type NoMethod Advertiser
2039	raw := NoMethod(*s)
2040	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2041}
2042
2043// AdvertiserGroup: Groups advertisers together so that reports can be
2044// generated for the entire group at once.
2045type AdvertiserGroup struct {
2046	// AccountId: Account ID of this advertiser group. This is a read-only
2047	// field that can be left blank.
2048	AccountId int64 `json:"accountId,omitempty,string"`
2049
2050	// Id: ID of this advertiser group. This is a read-only, auto-generated
2051	// field.
2052	Id int64 `json:"id,omitempty,string"`
2053
2054	// Kind: Identifies what kind of resource this is. Value: the fixed
2055	// string "dfareporting#advertiserGroup".
2056	Kind string `json:"kind,omitempty"`
2057
2058	// Name: Name of this advertiser group. This is a required field and
2059	// must be less than 256 characters long and unique among advertiser
2060	// groups of the same account.
2061	Name string `json:"name,omitempty"`
2062
2063	// ServerResponse contains the HTTP response code and headers from the
2064	// server.
2065	googleapi.ServerResponse `json:"-"`
2066
2067	// ForceSendFields is a list of field names (e.g. "AccountId") to
2068	// unconditionally include in API requests. By default, fields with
2069	// empty values are omitted from API requests. However, any non-pointer,
2070	// non-interface field appearing in ForceSendFields will be sent to the
2071	// server regardless of whether the field is empty or not. This may be
2072	// used to include empty fields in Patch requests.
2073	ForceSendFields []string `json:"-"`
2074
2075	// NullFields is a list of field names (e.g. "AccountId") to include in
2076	// API requests with the JSON null value. By default, fields with empty
2077	// values are omitted from API requests. However, any field with an
2078	// empty value appearing in NullFields will be sent to the server as
2079	// null. It is an error if a field in this list has a non-empty value.
2080	// This may be used to include null fields in Patch requests.
2081	NullFields []string `json:"-"`
2082}
2083
2084func (s *AdvertiserGroup) MarshalJSON() ([]byte, error) {
2085	type NoMethod AdvertiserGroup
2086	raw := NoMethod(*s)
2087	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2088}
2089
2090// AdvertiserGroupsListResponse: Advertiser Group List Response
2091type AdvertiserGroupsListResponse struct {
2092	// AdvertiserGroups: Advertiser group collection.
2093	AdvertiserGroups []*AdvertiserGroup `json:"advertiserGroups,omitempty"`
2094
2095	// Kind: Identifies what kind of resource this is. Value: the fixed
2096	// string "dfareporting#advertiserGroupsListResponse".
2097	Kind string `json:"kind,omitempty"`
2098
2099	// NextPageToken: Pagination token to be used for the next list
2100	// operation.
2101	NextPageToken string `json:"nextPageToken,omitempty"`
2102
2103	// ServerResponse contains the HTTP response code and headers from the
2104	// server.
2105	googleapi.ServerResponse `json:"-"`
2106
2107	// ForceSendFields is a list of field names (e.g. "AdvertiserGroups") to
2108	// unconditionally include in API requests. By default, fields with
2109	// empty values are omitted from API requests. However, any non-pointer,
2110	// non-interface field appearing in ForceSendFields will be sent to the
2111	// server regardless of whether the field is empty or not. This may be
2112	// used to include empty fields in Patch requests.
2113	ForceSendFields []string `json:"-"`
2114
2115	// NullFields is a list of field names (e.g. "AdvertiserGroups") to
2116	// include in API requests with the JSON null value. By default, fields
2117	// with empty values are omitted from API requests. However, any field
2118	// with an empty value appearing in NullFields will be sent to the
2119	// server as null. It is an error if a field in this list has a
2120	// non-empty value. This may be used to include null fields in Patch
2121	// requests.
2122	NullFields []string `json:"-"`
2123}
2124
2125func (s *AdvertiserGroupsListResponse) MarshalJSON() ([]byte, error) {
2126	type NoMethod AdvertiserGroupsListResponse
2127	raw := NoMethod(*s)
2128	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2129}
2130
2131// AdvertiserLandingPagesListResponse: Landing Page List Response
2132type AdvertiserLandingPagesListResponse struct {
2133	// Kind: Identifies what kind of resource this is. Value: the fixed
2134	// string "dfareporting#advertiserLandingPagesListResponse".
2135	Kind string `json:"kind,omitempty"`
2136
2137	// LandingPages: Landing page collection
2138	LandingPages []*LandingPage `json:"landingPages,omitempty"`
2139
2140	// NextPageToken: Pagination token to be used for the next list
2141	// operation.
2142	NextPageToken string `json:"nextPageToken,omitempty"`
2143
2144	// ServerResponse contains the HTTP response code and headers from the
2145	// server.
2146	googleapi.ServerResponse `json:"-"`
2147
2148	// ForceSendFields is a list of field names (e.g. "Kind") to
2149	// unconditionally include in API requests. By default, fields with
2150	// empty values are omitted from API requests. However, any non-pointer,
2151	// non-interface field appearing in ForceSendFields will be sent to the
2152	// server regardless of whether the field is empty or not. This may be
2153	// used to include empty fields in Patch requests.
2154	ForceSendFields []string `json:"-"`
2155
2156	// NullFields is a list of field names (e.g. "Kind") to include in API
2157	// requests with the JSON null value. By default, fields with empty
2158	// values are omitted from API requests. However, any field with an
2159	// empty value appearing in NullFields will be sent to the server as
2160	// null. It is an error if a field in this list has a non-empty value.
2161	// This may be used to include null fields in Patch requests.
2162	NullFields []string `json:"-"`
2163}
2164
2165func (s *AdvertiserLandingPagesListResponse) MarshalJSON() ([]byte, error) {
2166	type NoMethod AdvertiserLandingPagesListResponse
2167	raw := NoMethod(*s)
2168	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2169}
2170
2171// AdvertisersListResponse: Advertiser List Response
2172type AdvertisersListResponse struct {
2173	// Advertisers: Advertiser collection.
2174	Advertisers []*Advertiser `json:"advertisers,omitempty"`
2175
2176	// Kind: Identifies what kind of resource this is. Value: the fixed
2177	// string "dfareporting#advertisersListResponse".
2178	Kind string `json:"kind,omitempty"`
2179
2180	// NextPageToken: Pagination token to be used for the next list
2181	// operation.
2182	NextPageToken string `json:"nextPageToken,omitempty"`
2183
2184	// ServerResponse contains the HTTP response code and headers from the
2185	// server.
2186	googleapi.ServerResponse `json:"-"`
2187
2188	// ForceSendFields is a list of field names (e.g. "Advertisers") to
2189	// unconditionally include in API requests. By default, fields with
2190	// empty values are omitted from API requests. However, any non-pointer,
2191	// non-interface field appearing in ForceSendFields will be sent to the
2192	// server regardless of whether the field is empty or not. This may be
2193	// used to include empty fields in Patch requests.
2194	ForceSendFields []string `json:"-"`
2195
2196	// NullFields is a list of field names (e.g. "Advertisers") to include
2197	// in API requests with the JSON null value. By default, fields with
2198	// empty values are omitted from API requests. However, any field with
2199	// an empty value appearing in NullFields will be sent to the server as
2200	// null. It is an error if a field in this list has a non-empty value.
2201	// This may be used to include null fields in Patch requests.
2202	NullFields []string `json:"-"`
2203}
2204
2205func (s *AdvertisersListResponse) MarshalJSON() ([]byte, error) {
2206	type NoMethod AdvertisersListResponse
2207	raw := NoMethod(*s)
2208	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2209}
2210
2211// AudienceSegment: Audience Segment.
2212type AudienceSegment struct {
2213	// Allocation: Weight allocated to this segment. The weight assigned
2214	// will be understood in proportion to the weights assigned to other
2215	// segments in the same segment group. Acceptable values are 1 to 1000,
2216	// inclusive.
2217	Allocation int64 `json:"allocation,omitempty"`
2218
2219	// Id: ID of this audience segment. This is a read-only, auto-generated
2220	// field.
2221	Id int64 `json:"id,omitempty,string"`
2222
2223	// Name: Name of this audience segment. This is a required field and
2224	// must be less than 65 characters long.
2225	Name string `json:"name,omitempty"`
2226
2227	// ForceSendFields is a list of field names (e.g. "Allocation") to
2228	// unconditionally include in API requests. By default, fields with
2229	// empty values are omitted from API requests. However, any non-pointer,
2230	// non-interface field appearing in ForceSendFields will be sent to the
2231	// server regardless of whether the field is empty or not. This may be
2232	// used to include empty fields in Patch requests.
2233	ForceSendFields []string `json:"-"`
2234
2235	// NullFields is a list of field names (e.g. "Allocation") to include in
2236	// API requests with the JSON null value. By default, fields with empty
2237	// values are omitted from API requests. However, any field with an
2238	// empty value appearing in NullFields will be sent to the server as
2239	// null. It is an error if a field in this list has a non-empty value.
2240	// This may be used to include null fields in Patch requests.
2241	NullFields []string `json:"-"`
2242}
2243
2244func (s *AudienceSegment) MarshalJSON() ([]byte, error) {
2245	type NoMethod AudienceSegment
2246	raw := NoMethod(*s)
2247	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2248}
2249
2250// AudienceSegmentGroup: Audience Segment Group.
2251type AudienceSegmentGroup struct {
2252	// AudienceSegments: Audience segments assigned to this group. The
2253	// number of segments must be between 2 and 100.
2254	AudienceSegments []*AudienceSegment `json:"audienceSegments,omitempty"`
2255
2256	// Id: ID of this audience segment group. This is a read-only,
2257	// auto-generated field.
2258	Id int64 `json:"id,omitempty,string"`
2259
2260	// Name: Name of this audience segment group. This is a required field
2261	// and must be less than 65 characters long.
2262	Name string `json:"name,omitempty"`
2263
2264	// ForceSendFields is a list of field names (e.g. "AudienceSegments") to
2265	// unconditionally include in API requests. By default, fields with
2266	// empty values are omitted from API requests. However, any non-pointer,
2267	// non-interface field appearing in ForceSendFields will be sent to the
2268	// server regardless of whether the field is empty or not. This may be
2269	// used to include empty fields in Patch requests.
2270	ForceSendFields []string `json:"-"`
2271
2272	// NullFields is a list of field names (e.g. "AudienceSegments") to
2273	// include in API requests with the JSON null value. By default, fields
2274	// with empty values are omitted from API requests. However, any field
2275	// with an empty value appearing in NullFields will be sent to the
2276	// server as null. It is an error if a field in this list has a
2277	// non-empty value. This may be used to include null fields in Patch
2278	// requests.
2279	NullFields []string `json:"-"`
2280}
2281
2282func (s *AudienceSegmentGroup) MarshalJSON() ([]byte, error) {
2283	type NoMethod AudienceSegmentGroup
2284	raw := NoMethod(*s)
2285	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2286}
2287
2288// Browser: Contains information about a browser that can be targeted by
2289// ads.
2290type Browser struct {
2291	// BrowserVersionId: ID referring to this grouping of browser and
2292	// version numbers. This is the ID used for targeting.
2293	BrowserVersionId int64 `json:"browserVersionId,omitempty,string"`
2294
2295	// DartId: DART ID of this browser. This is the ID used when generating
2296	// reports.
2297	DartId int64 `json:"dartId,omitempty,string"`
2298
2299	// Kind: Identifies what kind of resource this is. Value: the fixed
2300	// string "dfareporting#browser".
2301	Kind string `json:"kind,omitempty"`
2302
2303	// MajorVersion: Major version number (leftmost number) of this browser.
2304	// For example, for Chrome 5.0.376.86 beta, this field should be set to
2305	// 5. An asterisk (*) may be used to target any version number, and a
2306	// question mark (?) may be used to target cases where the version
2307	// number cannot be identified. For example, Chrome *.* targets any
2308	// version of Chrome: 1.2, 2.5, 3.5, and so on. Chrome 3.* targets
2309	// Chrome 3.1, 3.5, but not 4.0. Firefox ?.? targets cases where the ad
2310	// server knows the browser is Firefox but can't tell which version it
2311	// is.
2312	MajorVersion string `json:"majorVersion,omitempty"`
2313
2314	// MinorVersion: Minor version number (number after first dot on left)
2315	// of this browser. For example, for Chrome 5.0.375.86 beta, this field
2316	// should be set to 0. An asterisk (*) may be used to target any version
2317	// number, and a question mark (?) may be used to target cases where the
2318	// version number cannot be identified. For example, Chrome *.* targets
2319	// any version of Chrome: 1.2, 2.5, 3.5, and so on. Chrome 3.* targets
2320	// Chrome 3.1, 3.5, but not 4.0. Firefox ?.? targets cases where the ad
2321	// server knows the browser is Firefox but can't tell which version it
2322	// is.
2323	MinorVersion string `json:"minorVersion,omitempty"`
2324
2325	// Name: Name of this browser.
2326	Name string `json:"name,omitempty"`
2327
2328	// ForceSendFields is a list of field names (e.g. "BrowserVersionId") to
2329	// unconditionally include in API requests. By default, fields with
2330	// empty values are omitted from API requests. However, any non-pointer,
2331	// non-interface field appearing in ForceSendFields will be sent to the
2332	// server regardless of whether the field is empty or not. This may be
2333	// used to include empty fields in Patch requests.
2334	ForceSendFields []string `json:"-"`
2335
2336	// NullFields is a list of field names (e.g. "BrowserVersionId") to
2337	// include in API requests with the JSON null value. By default, fields
2338	// with empty values are omitted from API requests. However, any field
2339	// with an empty value appearing in NullFields will be sent to the
2340	// server as null. It is an error if a field in this list has a
2341	// non-empty value. This may be used to include null fields in Patch
2342	// requests.
2343	NullFields []string `json:"-"`
2344}
2345
2346func (s *Browser) MarshalJSON() ([]byte, error) {
2347	type NoMethod Browser
2348	raw := NoMethod(*s)
2349	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2350}
2351
2352// BrowsersListResponse: Browser List Response
2353type BrowsersListResponse struct {
2354	// Browsers: Browser collection.
2355	Browsers []*Browser `json:"browsers,omitempty"`
2356
2357	// Kind: Identifies what kind of resource this is. Value: the fixed
2358	// string "dfareporting#browsersListResponse".
2359	Kind string `json:"kind,omitempty"`
2360
2361	// ServerResponse contains the HTTP response code and headers from the
2362	// server.
2363	googleapi.ServerResponse `json:"-"`
2364
2365	// ForceSendFields is a list of field names (e.g. "Browsers") to
2366	// unconditionally include in API requests. By default, fields with
2367	// empty values are omitted from API requests. However, any non-pointer,
2368	// non-interface field appearing in ForceSendFields will be sent to the
2369	// server regardless of whether the field is empty or not. This may be
2370	// used to include empty fields in Patch requests.
2371	ForceSendFields []string `json:"-"`
2372
2373	// NullFields is a list of field names (e.g. "Browsers") to include in
2374	// API requests with the JSON null value. By default, fields with empty
2375	// values are omitted from API requests. However, any field with an
2376	// empty value appearing in NullFields will be sent to the server as
2377	// null. It is an error if a field in this list has a non-empty value.
2378	// This may be used to include null fields in Patch requests.
2379	NullFields []string `json:"-"`
2380}
2381
2382func (s *BrowsersListResponse) MarshalJSON() ([]byte, error) {
2383	type NoMethod BrowsersListResponse
2384	raw := NoMethod(*s)
2385	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2386}
2387
2388// Campaign: Contains properties of a Campaign Manager campaign.
2389type Campaign struct {
2390	// AccountId: Account ID of this campaign. This is a read-only field
2391	// that can be left blank.
2392	AccountId int64 `json:"accountId,omitempty,string"`
2393
2394	// AdBlockingConfiguration: Ad blocking settings for this campaign.
2395	AdBlockingConfiguration *AdBlockingConfiguration `json:"adBlockingConfiguration,omitempty"`
2396
2397	// AdditionalCreativeOptimizationConfigurations: Additional creative
2398	// optimization configurations for the campaign.
2399	AdditionalCreativeOptimizationConfigurations []*CreativeOptimizationConfiguration `json:"additionalCreativeOptimizationConfigurations,omitempty"`
2400
2401	// AdvertiserGroupId: Advertiser group ID of the associated advertiser.
2402	AdvertiserGroupId int64 `json:"advertiserGroupId,omitempty,string"`
2403
2404	// AdvertiserId: Advertiser ID of this campaign. This is a required
2405	// field.
2406	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
2407
2408	// AdvertiserIdDimensionValue: Dimension value for the advertiser ID of
2409	// this campaign. This is a read-only, auto-generated field.
2410	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
2411
2412	// Archived: Whether this campaign has been archived.
2413	Archived bool `json:"archived,omitempty"`
2414
2415	// AudienceSegmentGroups: Audience segment groups assigned to this
2416	// campaign. Cannot have more than 300 segment groups.
2417	AudienceSegmentGroups []*AudienceSegmentGroup `json:"audienceSegmentGroups,omitempty"`
2418
2419	// BillingInvoiceCode: Billing invoice code included in the Campaign
2420	// Manager client billing invoices associated with the campaign.
2421	BillingInvoiceCode string `json:"billingInvoiceCode,omitempty"`
2422
2423	// ClickThroughUrlSuffixProperties: Click-through URL suffix override
2424	// properties for this campaign.
2425	ClickThroughUrlSuffixProperties *ClickThroughUrlSuffixProperties `json:"clickThroughUrlSuffixProperties,omitempty"`
2426
2427	// Comment: Arbitrary comments about this campaign. Must be less than
2428	// 256 characters long.
2429	Comment string `json:"comment,omitempty"`
2430
2431	// CreateInfo: Information about the creation of this campaign. This is
2432	// a read-only field.
2433	CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
2434
2435	// CreativeGroupIds: List of creative group IDs that are assigned to the
2436	// campaign.
2437	CreativeGroupIds googleapi.Int64s `json:"creativeGroupIds,omitempty"`
2438
2439	// CreativeOptimizationConfiguration: Creative optimization
2440	// configuration for the campaign.
2441	CreativeOptimizationConfiguration *CreativeOptimizationConfiguration `json:"creativeOptimizationConfiguration,omitempty"`
2442
2443	// DefaultClickThroughEventTagProperties: Click-through event tag ID
2444	// override properties for this campaign.
2445	DefaultClickThroughEventTagProperties *DefaultClickThroughEventTagProperties `json:"defaultClickThroughEventTagProperties,omitempty"`
2446
2447	// DefaultLandingPageId: The default landing page ID for this campaign.
2448	DefaultLandingPageId int64 `json:"defaultLandingPageId,omitempty,string"`
2449
2450	// EndDate: Date on which the campaign will stop running. On insert, the
2451	// end date must be today or a future date. The end date must be later
2452	// than or be the same as the start date. If, for example, you set
2453	// 6/25/2015 as both the start and end dates, the effective campaign run
2454	// date is just that day only, 6/25/2015. The hours, minutes, and
2455	// seconds of the end date should not be set, as doing so will result in
2456	// an error. This is a required field.
2457	EndDate string `json:"endDate,omitempty"`
2458
2459	// EventTagOverrides: Overrides that can be used to activate or
2460	// deactivate advertiser event tags.
2461	EventTagOverrides []*EventTagOverride `json:"eventTagOverrides,omitempty"`
2462
2463	// ExternalId: External ID for this campaign.
2464	ExternalId string `json:"externalId,omitempty"`
2465
2466	// Id: ID of this campaign. This is a read-only auto-generated field.
2467	Id int64 `json:"id,omitempty,string"`
2468
2469	// IdDimensionValue: Dimension value for the ID of this campaign. This
2470	// is a read-only, auto-generated field.
2471	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
2472
2473	// Kind: Identifies what kind of resource this is. Value: the fixed
2474	// string "dfareporting#campaign".
2475	Kind string `json:"kind,omitempty"`
2476
2477	// LastModifiedInfo: Information about the most recent modification of
2478	// this campaign. This is a read-only field.
2479	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
2480
2481	// LookbackConfiguration: Lookback window settings for the campaign.
2482	LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
2483
2484	// Name: Name of this campaign. This is a required field and must be
2485	// less than 256 characters long and unique among campaigns of the same
2486	// advertiser.
2487	Name string `json:"name,omitempty"`
2488
2489	// NielsenOcrEnabled: Whether Nielsen reports are enabled for this
2490	// campaign.
2491	NielsenOcrEnabled bool `json:"nielsenOcrEnabled,omitempty"`
2492
2493	// StartDate: Date on which the campaign starts running. The start date
2494	// can be any date. The hours, minutes, and seconds of the start date
2495	// should not be set, as doing so will result in an error. This is a
2496	// required field.
2497	StartDate string `json:"startDate,omitempty"`
2498
2499	// SubaccountId: Subaccount ID of this campaign. This is a read-only
2500	// field that can be left blank.
2501	SubaccountId int64 `json:"subaccountId,omitempty,string"`
2502
2503	// TraffickerEmails: Campaign trafficker contact emails.
2504	TraffickerEmails []string `json:"traffickerEmails,omitempty"`
2505
2506	// ServerResponse contains the HTTP response code and headers from the
2507	// server.
2508	googleapi.ServerResponse `json:"-"`
2509
2510	// ForceSendFields is a list of field names (e.g. "AccountId") to
2511	// unconditionally include in API requests. By default, fields with
2512	// empty values are omitted from API requests. However, any non-pointer,
2513	// non-interface field appearing in ForceSendFields will be sent to the
2514	// server regardless of whether the field is empty or not. This may be
2515	// used to include empty fields in Patch requests.
2516	ForceSendFields []string `json:"-"`
2517
2518	// NullFields is a list of field names (e.g. "AccountId") to include in
2519	// API requests with the JSON null value. By default, fields with empty
2520	// values are omitted from API requests. However, any field with an
2521	// empty value appearing in NullFields will be sent to the server as
2522	// null. It is an error if a field in this list has a non-empty value.
2523	// This may be used to include null fields in Patch requests.
2524	NullFields []string `json:"-"`
2525}
2526
2527func (s *Campaign) MarshalJSON() ([]byte, error) {
2528	type NoMethod Campaign
2529	raw := NoMethod(*s)
2530	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2531}
2532
2533// CampaignCreativeAssociation: Identifies a creative which has been
2534// associated with a given campaign.
2535type CampaignCreativeAssociation struct {
2536	// CreativeId: ID of the creative associated with the campaign. This is
2537	// a required field.
2538	CreativeId int64 `json:"creativeId,omitempty,string"`
2539
2540	// Kind: Identifies what kind of resource this is. Value: the fixed
2541	// string "dfareporting#campaignCreativeAssociation".
2542	Kind string `json:"kind,omitempty"`
2543
2544	// ServerResponse contains the HTTP response code and headers from the
2545	// server.
2546	googleapi.ServerResponse `json:"-"`
2547
2548	// ForceSendFields is a list of field names (e.g. "CreativeId") to
2549	// unconditionally include in API requests. By default, fields with
2550	// empty values are omitted from API requests. However, any non-pointer,
2551	// non-interface field appearing in ForceSendFields will be sent to the
2552	// server regardless of whether the field is empty or not. This may be
2553	// used to include empty fields in Patch requests.
2554	ForceSendFields []string `json:"-"`
2555
2556	// NullFields is a list of field names (e.g. "CreativeId") to include in
2557	// API requests with the JSON null value. By default, fields with empty
2558	// values are omitted from API requests. However, any field with an
2559	// empty value appearing in NullFields will be sent to the server as
2560	// null. It is an error if a field in this list has a non-empty value.
2561	// This may be used to include null fields in Patch requests.
2562	NullFields []string `json:"-"`
2563}
2564
2565func (s *CampaignCreativeAssociation) MarshalJSON() ([]byte, error) {
2566	type NoMethod CampaignCreativeAssociation
2567	raw := NoMethod(*s)
2568	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2569}
2570
2571// CampaignCreativeAssociationsListResponse: Campaign Creative
2572// Association List Response
2573type CampaignCreativeAssociationsListResponse struct {
2574	// CampaignCreativeAssociations: Campaign creative association
2575	// collection
2576	CampaignCreativeAssociations []*CampaignCreativeAssociation `json:"campaignCreativeAssociations,omitempty"`
2577
2578	// Kind: Identifies what kind of resource this is. Value: the fixed
2579	// string "dfareporting#campaignCreativeAssociationsListResponse".
2580	Kind string `json:"kind,omitempty"`
2581
2582	// NextPageToken: Pagination token to be used for the next list
2583	// operation.
2584	NextPageToken string `json:"nextPageToken,omitempty"`
2585
2586	// ServerResponse contains the HTTP response code and headers from the
2587	// server.
2588	googleapi.ServerResponse `json:"-"`
2589
2590	// ForceSendFields is a list of field names (e.g.
2591	// "CampaignCreativeAssociations") to unconditionally include in API
2592	// requests. By default, fields with empty values are omitted from API
2593	// requests. However, any non-pointer, non-interface field appearing in
2594	// ForceSendFields will be sent to the server regardless of whether the
2595	// field is empty or not. This may be used to include empty fields in
2596	// Patch requests.
2597	ForceSendFields []string `json:"-"`
2598
2599	// NullFields is a list of field names (e.g.
2600	// "CampaignCreativeAssociations") to include in API requests with the
2601	// JSON null value. By default, fields with empty values are omitted
2602	// from API requests. However, any field with an empty value appearing
2603	// in NullFields will be sent to the server as null. It is an error if a
2604	// field in this list has a non-empty value. This may be used to include
2605	// null fields in Patch requests.
2606	NullFields []string `json:"-"`
2607}
2608
2609func (s *CampaignCreativeAssociationsListResponse) MarshalJSON() ([]byte, error) {
2610	type NoMethod CampaignCreativeAssociationsListResponse
2611	raw := NoMethod(*s)
2612	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2613}
2614
2615// CampaignsListResponse: Campaign List Response
2616type CampaignsListResponse struct {
2617	// Campaigns: Campaign collection.
2618	Campaigns []*Campaign `json:"campaigns,omitempty"`
2619
2620	// Kind: Identifies what kind of resource this is. Value: the fixed
2621	// string "dfareporting#campaignsListResponse".
2622	Kind string `json:"kind,omitempty"`
2623
2624	// NextPageToken: Pagination token to be used for the next list
2625	// operation.
2626	NextPageToken string `json:"nextPageToken,omitempty"`
2627
2628	// ServerResponse contains the HTTP response code and headers from the
2629	// server.
2630	googleapi.ServerResponse `json:"-"`
2631
2632	// ForceSendFields is a list of field names (e.g. "Campaigns") to
2633	// unconditionally include in API requests. By default, fields with
2634	// empty values are omitted from API requests. However, any non-pointer,
2635	// non-interface field appearing in ForceSendFields will be sent to the
2636	// server regardless of whether the field is empty or not. This may be
2637	// used to include empty fields in Patch requests.
2638	ForceSendFields []string `json:"-"`
2639
2640	// NullFields is a list of field names (e.g. "Campaigns") to include in
2641	// API requests with the JSON null value. By default, fields with empty
2642	// values are omitted from API requests. However, any field with an
2643	// empty value appearing in NullFields will be sent to the server as
2644	// null. It is an error if a field in this list has a non-empty value.
2645	// This may be used to include null fields in Patch requests.
2646	NullFields []string `json:"-"`
2647}
2648
2649func (s *CampaignsListResponse) MarshalJSON() ([]byte, error) {
2650	type NoMethod CampaignsListResponse
2651	raw := NoMethod(*s)
2652	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2653}
2654
2655// ChangeLog: Describes a change that a user has made to a resource.
2656type ChangeLog struct {
2657	// AccountId: Account ID of the modified object.
2658	AccountId int64 `json:"accountId,omitempty,string"`
2659
2660	// Action: Action which caused the change.
2661	Action string `json:"action,omitempty"`
2662
2663	// ChangeTime: Time when the object was modified.
2664	ChangeTime string `json:"changeTime,omitempty"`
2665
2666	// FieldName: Field name of the object which changed.
2667	FieldName string `json:"fieldName,omitempty"`
2668
2669	// Id: ID of this change log.
2670	Id int64 `json:"id,omitempty,string"`
2671
2672	// Kind: Identifies what kind of resource this is. Value: the fixed
2673	// string "dfareporting#changeLog".
2674	Kind string `json:"kind,omitempty"`
2675
2676	// NewValue: New value of the object field.
2677	NewValue string `json:"newValue,omitempty"`
2678
2679	// ObjectId: ID of the object of this change log. The object could be a
2680	// campaign, placement, ad, or other type.
2681	ObjectId int64 `json:"objectId,omitempty,string"`
2682
2683	// ObjectType: Object type of the change log.
2684	ObjectType string `json:"objectType,omitempty"`
2685
2686	// OldValue: Old value of the object field.
2687	OldValue string `json:"oldValue,omitempty"`
2688
2689	// SubaccountId: Subaccount ID of the modified object.
2690	SubaccountId int64 `json:"subaccountId,omitempty,string"`
2691
2692	// TransactionId: Transaction ID of this change log. When a single API
2693	// call results in many changes, each change will have a separate ID in
2694	// the change log but will share the same transactionId.
2695	TransactionId int64 `json:"transactionId,omitempty,string"`
2696
2697	// UserProfileId: ID of the user who modified the object.
2698	UserProfileId int64 `json:"userProfileId,omitempty,string"`
2699
2700	// UserProfileName: User profile name of the user who modified the
2701	// object.
2702	UserProfileName string `json:"userProfileName,omitempty"`
2703
2704	// ServerResponse contains the HTTP response code and headers from the
2705	// server.
2706	googleapi.ServerResponse `json:"-"`
2707
2708	// ForceSendFields is a list of field names (e.g. "AccountId") to
2709	// unconditionally include in API requests. By default, fields with
2710	// empty values are omitted from API requests. However, any non-pointer,
2711	// non-interface field appearing in ForceSendFields will be sent to the
2712	// server regardless of whether the field is empty or not. This may be
2713	// used to include empty fields in Patch requests.
2714	ForceSendFields []string `json:"-"`
2715
2716	// NullFields is a list of field names (e.g. "AccountId") to include in
2717	// API requests with the JSON null value. By default, fields with empty
2718	// values are omitted from API requests. However, any field with an
2719	// empty value appearing in NullFields will be sent to the server as
2720	// null. It is an error if a field in this list has a non-empty value.
2721	// This may be used to include null fields in Patch requests.
2722	NullFields []string `json:"-"`
2723}
2724
2725func (s *ChangeLog) MarshalJSON() ([]byte, error) {
2726	type NoMethod ChangeLog
2727	raw := NoMethod(*s)
2728	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2729}
2730
2731// ChangeLogsListResponse: Change Log List Response
2732type ChangeLogsListResponse struct {
2733	// ChangeLogs: Change log collection.
2734	ChangeLogs []*ChangeLog `json:"changeLogs,omitempty"`
2735
2736	// Kind: Identifies what kind of resource this is. Value: the fixed
2737	// string "dfareporting#changeLogsListResponse".
2738	Kind string `json:"kind,omitempty"`
2739
2740	// NextPageToken: Pagination token to be used for the next list
2741	// operation.
2742	NextPageToken string `json:"nextPageToken,omitempty"`
2743
2744	// ServerResponse contains the HTTP response code and headers from the
2745	// server.
2746	googleapi.ServerResponse `json:"-"`
2747
2748	// ForceSendFields is a list of field names (e.g. "ChangeLogs") to
2749	// unconditionally include in API requests. By default, fields with
2750	// empty values are omitted from API requests. However, any non-pointer,
2751	// non-interface field appearing in ForceSendFields will be sent to the
2752	// server regardless of whether the field is empty or not. This may be
2753	// used to include empty fields in Patch requests.
2754	ForceSendFields []string `json:"-"`
2755
2756	// NullFields is a list of field names (e.g. "ChangeLogs") to include in
2757	// API requests with the JSON null value. By default, fields with empty
2758	// values are omitted from API requests. However, any field with an
2759	// 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 *ChangeLogsListResponse) MarshalJSON() ([]byte, error) {
2766	type NoMethod ChangeLogsListResponse
2767	raw := NoMethod(*s)
2768	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2769}
2770
2771// CitiesListResponse: City List Response
2772type CitiesListResponse struct {
2773	// Cities: City collection.
2774	Cities []*City `json:"cities,omitempty"`
2775
2776	// Kind: Identifies what kind of resource this is. Value: the fixed
2777	// string "dfareporting#citiesListResponse".
2778	Kind string `json:"kind,omitempty"`
2779
2780	// ServerResponse contains the HTTP response code and headers from the
2781	// server.
2782	googleapi.ServerResponse `json:"-"`
2783
2784	// ForceSendFields is a list of field names (e.g. "Cities") to
2785	// unconditionally include in API requests. By default, fields with
2786	// empty values are omitted from API requests. However, any non-pointer,
2787	// non-interface field appearing in ForceSendFields will be sent to the
2788	// server regardless of whether the field is empty or not. This may be
2789	// used to include empty fields in Patch requests.
2790	ForceSendFields []string `json:"-"`
2791
2792	// NullFields is a list of field names (e.g. "Cities") to include in API
2793	// requests with the JSON null value. By default, fields with empty
2794	// values are omitted from API requests. However, any field with an
2795	// empty value appearing in NullFields will be sent to the server as
2796	// null. It is an error if a field in this list has a non-empty value.
2797	// This may be used to include null fields in Patch requests.
2798	NullFields []string `json:"-"`
2799}
2800
2801func (s *CitiesListResponse) MarshalJSON() ([]byte, error) {
2802	type NoMethod CitiesListResponse
2803	raw := NoMethod(*s)
2804	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2805}
2806
2807// City: Contains information about a city that can be targeted by ads.
2808type City struct {
2809	// CountryCode: Country code of the country to which this city belongs.
2810	CountryCode string `json:"countryCode,omitempty"`
2811
2812	// CountryDartId: DART ID of the country to which this city belongs.
2813	CountryDartId int64 `json:"countryDartId,omitempty,string"`
2814
2815	// DartId: DART ID of this city. This is the ID used for targeting and
2816	// generating reports.
2817	DartId int64 `json:"dartId,omitempty,string"`
2818
2819	// Kind: Identifies what kind of resource this is. Value: the fixed
2820	// string "dfareporting#city".
2821	Kind string `json:"kind,omitempty"`
2822
2823	// MetroCode: Metro region code of the metro region (DMA) to which this
2824	// city belongs.
2825	MetroCode string `json:"metroCode,omitempty"`
2826
2827	// MetroDmaId: ID of the metro region (DMA) to which this city belongs.
2828	MetroDmaId int64 `json:"metroDmaId,omitempty,string"`
2829
2830	// Name: Name of this city.
2831	Name string `json:"name,omitempty"`
2832
2833	// RegionCode: Region code of the region to which this city belongs.
2834	RegionCode string `json:"regionCode,omitempty"`
2835
2836	// RegionDartId: DART ID of the region to which this city belongs.
2837	RegionDartId int64 `json:"regionDartId,omitempty,string"`
2838
2839	// ForceSendFields is a list of field names (e.g. "CountryCode") to
2840	// unconditionally include in API requests. By default, fields with
2841	// empty values are omitted from API requests. However, any non-pointer,
2842	// non-interface field appearing in ForceSendFields will be sent to the
2843	// server regardless of whether the field is empty or not. This may be
2844	// used to include empty fields in Patch requests.
2845	ForceSendFields []string `json:"-"`
2846
2847	// NullFields is a list of field names (e.g. "CountryCode") to include
2848	// in API requests with the JSON null value. By default, fields with
2849	// empty values are omitted from API requests. However, any field with
2850	// an empty value appearing in NullFields will be sent to the server as
2851	// null. It is an error if a field in this list has a non-empty value.
2852	// This may be used to include null fields in Patch requests.
2853	NullFields []string `json:"-"`
2854}
2855
2856func (s *City) MarshalJSON() ([]byte, error) {
2857	type NoMethod City
2858	raw := NoMethod(*s)
2859	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2860}
2861
2862// ClickTag: Creative Click Tag.
2863type ClickTag struct {
2864	// ClickThroughUrl: Parameter value for the specified click tag. This
2865	// field contains a click-through url.
2866	ClickThroughUrl *CreativeClickThroughUrl `json:"clickThroughUrl,omitempty"`
2867
2868	// EventName: Advertiser event name associated with the click tag. This
2869	// field is used by DISPLAY_IMAGE_GALLERY and HTML5_BANNER creatives.
2870	// Applicable to DISPLAY when the primary asset type is not HTML_IMAGE.
2871	EventName string `json:"eventName,omitempty"`
2872
2873	// Name: Parameter name for the specified click tag. For
2874	// DISPLAY_IMAGE_GALLERY creative assets, this field must match the
2875	// value of the creative asset's creativeAssetId.name field.
2876	Name string `json:"name,omitempty"`
2877
2878	// ForceSendFields is a list of field names (e.g. "ClickThroughUrl") to
2879	// unconditionally include in API requests. By default, fields with
2880	// empty values are omitted from API requests. However, any non-pointer,
2881	// non-interface field appearing in ForceSendFields will be sent to the
2882	// server regardless of whether the field is empty or not. This may be
2883	// used to include empty fields in Patch requests.
2884	ForceSendFields []string `json:"-"`
2885
2886	// NullFields is a list of field names (e.g. "ClickThroughUrl") to
2887	// include in API requests with the JSON null value. By default, fields
2888	// with empty values are omitted from API requests. However, any field
2889	// with an empty value appearing in NullFields will be sent to the
2890	// server as null. It is an error if a field in this list has a
2891	// non-empty value. This may be used to include null fields in Patch
2892	// requests.
2893	NullFields []string `json:"-"`
2894}
2895
2896func (s *ClickTag) MarshalJSON() ([]byte, error) {
2897	type NoMethod ClickTag
2898	raw := NoMethod(*s)
2899	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2900}
2901
2902// ClickThroughUrl: Click-through URL
2903type ClickThroughUrl struct {
2904	// ComputedClickThroughUrl: Read-only convenience field representing the
2905	// actual URL that will be used for this click-through. The URL is
2906	// computed as follows:
2907	// - If defaultLandingPage is enabled then the campaign's default
2908	// landing page URL is assigned to this field.
2909	// - If defaultLandingPage is not enabled and a landingPageId is
2910	// specified then that landing page's URL is assigned to this field.
2911	// - If neither of the above cases apply, then the customClickThroughUrl
2912	// is assigned to this field.
2913	ComputedClickThroughUrl string `json:"computedClickThroughUrl,omitempty"`
2914
2915	// CustomClickThroughUrl: Custom click-through URL. Applicable if the
2916	// defaultLandingPage field is set to false and the landingPageId field
2917	// is left unset.
2918	CustomClickThroughUrl string `json:"customClickThroughUrl,omitempty"`
2919
2920	// DefaultLandingPage: Whether the campaign default landing page is
2921	// used.
2922	DefaultLandingPage bool `json:"defaultLandingPage,omitempty"`
2923
2924	// LandingPageId: ID of the landing page for the click-through URL.
2925	// Applicable if the defaultLandingPage field is set to false.
2926	LandingPageId int64 `json:"landingPageId,omitempty,string"`
2927
2928	// ForceSendFields is a list of field names (e.g.
2929	// "ComputedClickThroughUrl") to unconditionally include in API
2930	// requests. By default, fields with empty values are omitted from API
2931	// requests. However, any non-pointer, non-interface field appearing in
2932	// ForceSendFields will be sent to the server regardless of whether the
2933	// field is empty or not. This may be used to include empty fields in
2934	// Patch requests.
2935	ForceSendFields []string `json:"-"`
2936
2937	// NullFields is a list of field names (e.g. "ComputedClickThroughUrl")
2938	// to include in API requests with the JSON null value. By default,
2939	// fields with empty values are omitted from API requests. However, any
2940	// field with an empty value appearing in NullFields will be sent to the
2941	// server as null. It is an error if a field in this list has a
2942	// non-empty value. This may be used to include null fields in Patch
2943	// requests.
2944	NullFields []string `json:"-"`
2945}
2946
2947func (s *ClickThroughUrl) MarshalJSON() ([]byte, error) {
2948	type NoMethod ClickThroughUrl
2949	raw := NoMethod(*s)
2950	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2951}
2952
2953// ClickThroughUrlSuffixProperties: Click Through URL Suffix settings.
2954type ClickThroughUrlSuffixProperties struct {
2955	// ClickThroughUrlSuffix: Click-through URL suffix to apply to all ads
2956	// in this entity's scope. Must be less than 128 characters long.
2957	ClickThroughUrlSuffix string `json:"clickThroughUrlSuffix,omitempty"`
2958
2959	// OverrideInheritedSuffix: Whether this entity should override the
2960	// inherited click-through URL suffix with its own defined value.
2961	OverrideInheritedSuffix bool `json:"overrideInheritedSuffix,omitempty"`
2962
2963	// ForceSendFields is a list of field names (e.g.
2964	// "ClickThroughUrlSuffix") to unconditionally include in API requests.
2965	// By default, fields with empty values are omitted from API requests.
2966	// However, any non-pointer, non-interface field appearing in
2967	// ForceSendFields will be sent to the server regardless of whether the
2968	// field is empty or not. This may be used to include empty fields in
2969	// Patch requests.
2970	ForceSendFields []string `json:"-"`
2971
2972	// NullFields is a list of field names (e.g. "ClickThroughUrlSuffix") to
2973	// include in API requests with the JSON null value. By default, fields
2974	// with empty values are omitted from API requests. However, any field
2975	// with an empty value appearing in NullFields will be sent to the
2976	// server as null. It is an error if a field in this list has a
2977	// non-empty value. This may be used to include null fields in Patch
2978	// requests.
2979	NullFields []string `json:"-"`
2980}
2981
2982func (s *ClickThroughUrlSuffixProperties) MarshalJSON() ([]byte, error) {
2983	type NoMethod ClickThroughUrlSuffixProperties
2984	raw := NoMethod(*s)
2985	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2986}
2987
2988// CompanionClickThroughOverride: Companion Click-through override.
2989type CompanionClickThroughOverride struct {
2990	// ClickThroughUrl: Click-through URL of this companion click-through
2991	// override.
2992	ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
2993
2994	// CreativeId: ID of the creative for this companion click-through
2995	// override.
2996	CreativeId int64 `json:"creativeId,omitempty,string"`
2997
2998	// ForceSendFields is a list of field names (e.g. "ClickThroughUrl") to
2999	// unconditionally include in API requests. By default, fields with
3000	// empty values are omitted from API requests. However, any non-pointer,
3001	// non-interface field appearing in ForceSendFields will be sent to the
3002	// server regardless of whether the field is empty or not. This may be
3003	// used to include empty fields in Patch requests.
3004	ForceSendFields []string `json:"-"`
3005
3006	// NullFields is a list of field names (e.g. "ClickThroughUrl") to
3007	// include in API requests with the JSON null value. By default, fields
3008	// with empty values are omitted from API requests. However, any field
3009	// with an empty value appearing in NullFields will be sent to the
3010	// server as null. It is an error if a field in this list has a
3011	// non-empty value. This may be used to include null fields in Patch
3012	// requests.
3013	NullFields []string `json:"-"`
3014}
3015
3016func (s *CompanionClickThroughOverride) MarshalJSON() ([]byte, error) {
3017	type NoMethod CompanionClickThroughOverride
3018	raw := NoMethod(*s)
3019	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3020}
3021
3022// CompanionSetting: Companion Settings
3023type CompanionSetting struct {
3024	// CompanionsDisabled: Whether companions are disabled for this
3025	// placement.
3026	CompanionsDisabled bool `json:"companionsDisabled,omitempty"`
3027
3028	// EnabledSizes: Whitelist of companion sizes to be served to this
3029	// placement. Set this list to null or empty to serve all companion
3030	// sizes.
3031	EnabledSizes []*Size `json:"enabledSizes,omitempty"`
3032
3033	// ImageOnly: Whether to serve only static images as companions.
3034	ImageOnly bool `json:"imageOnly,omitempty"`
3035
3036	// Kind: Identifies what kind of resource this is. Value: the fixed
3037	// string "dfareporting#companionSetting".
3038	Kind string `json:"kind,omitempty"`
3039
3040	// ForceSendFields is a list of field names (e.g. "CompanionsDisabled")
3041	// to unconditionally include in API requests. By default, fields with
3042	// empty values are omitted from API requests. However, any non-pointer,
3043	// non-interface field appearing in ForceSendFields will be sent to the
3044	// server regardless of whether the field is empty or not. This may be
3045	// used to include empty fields in Patch requests.
3046	ForceSendFields []string `json:"-"`
3047
3048	// NullFields is a list of field names (e.g. "CompanionsDisabled") to
3049	// include in API requests with the JSON null value. By default, fields
3050	// with empty values are omitted from API requests. However, any field
3051	// with an empty value appearing in NullFields will be sent to the
3052	// server as null. It is an error if a field in this list has a
3053	// non-empty value. This may be used to include null fields in Patch
3054	// requests.
3055	NullFields []string `json:"-"`
3056}
3057
3058func (s *CompanionSetting) MarshalJSON() ([]byte, error) {
3059	type NoMethod CompanionSetting
3060	raw := NoMethod(*s)
3061	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3062}
3063
3064// CompatibleFields: Represents a response to the queryCompatibleFields
3065// method.
3066type CompatibleFields struct {
3067	// CrossDimensionReachReportCompatibleFields: Contains items that are
3068	// compatible to be selected for a report of type
3069	// "CROSS_DIMENSION_REACH".
3070	CrossDimensionReachReportCompatibleFields *CrossDimensionReachReportCompatibleFields `json:"crossDimensionReachReportCompatibleFields,omitempty"`
3071
3072	// FloodlightReportCompatibleFields: Contains items that are compatible
3073	// to be selected for a report of type "FLOODLIGHT".
3074	FloodlightReportCompatibleFields *FloodlightReportCompatibleFields `json:"floodlightReportCompatibleFields,omitempty"`
3075
3076	// Kind: The kind of resource this is, in this case
3077	// dfareporting#compatibleFields.
3078	Kind string `json:"kind,omitempty"`
3079
3080	// PathToConversionReportCompatibleFields: Contains items that are
3081	// compatible to be selected for a report of type "PATH_TO_CONVERSION".
3082	PathToConversionReportCompatibleFields *PathToConversionReportCompatibleFields `json:"pathToConversionReportCompatibleFields,omitempty"`
3083
3084	// ReachReportCompatibleFields: Contains items that are compatible to be
3085	// selected for a report of type "REACH".
3086	ReachReportCompatibleFields *ReachReportCompatibleFields `json:"reachReportCompatibleFields,omitempty"`
3087
3088	// ReportCompatibleFields: Contains items that are compatible to be
3089	// selected for a report of type "STANDARD".
3090	ReportCompatibleFields *ReportCompatibleFields `json:"reportCompatibleFields,omitempty"`
3091
3092	// ServerResponse contains the HTTP response code and headers from the
3093	// server.
3094	googleapi.ServerResponse `json:"-"`
3095
3096	// ForceSendFields is a list of field names (e.g.
3097	// "CrossDimensionReachReportCompatibleFields") to unconditionally
3098	// include in API requests. By default, fields with empty values are
3099	// omitted from API requests. However, any non-pointer, non-interface
3100	// field appearing in ForceSendFields will be sent to the server
3101	// regardless of whether the field is empty or not. This may be used to
3102	// include empty fields in Patch requests.
3103	ForceSendFields []string `json:"-"`
3104
3105	// NullFields is a list of field names (e.g.
3106	// "CrossDimensionReachReportCompatibleFields") to include in API
3107	// requests with the JSON null value. By default, fields with empty
3108	// values are omitted from API requests. However, any field with an
3109	// empty value appearing in NullFields will be sent to the server as
3110	// null. It is an error if a field in this list has a non-empty value.
3111	// This may be used to include null fields in Patch requests.
3112	NullFields []string `json:"-"`
3113}
3114
3115func (s *CompatibleFields) MarshalJSON() ([]byte, error) {
3116	type NoMethod CompatibleFields
3117	raw := NoMethod(*s)
3118	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3119}
3120
3121// ConnectionType: Contains information about an internet connection
3122// type that can be targeted by ads. Clients can use the connection type
3123// to target mobile vs. broadband users.
3124type ConnectionType struct {
3125	// Id: ID of this connection type.
3126	Id int64 `json:"id,omitempty,string"`
3127
3128	// Kind: Identifies what kind of resource this is. Value: the fixed
3129	// string "dfareporting#connectionType".
3130	Kind string `json:"kind,omitempty"`
3131
3132	// Name: Name of this connection type.
3133	Name string `json:"name,omitempty"`
3134
3135	// ServerResponse contains the HTTP response code and headers from the
3136	// server.
3137	googleapi.ServerResponse `json:"-"`
3138
3139	// ForceSendFields is a list of field names (e.g. "Id") to
3140	// unconditionally include in API requests. By default, fields with
3141	// empty values are omitted from API requests. However, any non-pointer,
3142	// non-interface field appearing in ForceSendFields will be sent to the
3143	// server regardless of whether the field is empty or not. This may be
3144	// used to include empty fields in Patch requests.
3145	ForceSendFields []string `json:"-"`
3146
3147	// NullFields is a list of field names (e.g. "Id") to include in API
3148	// requests with the JSON null value. By default, fields with empty
3149	// values are omitted from API requests. However, any field with an
3150	// empty value appearing in NullFields will be sent to the server as
3151	// null. It is an error if a field in this list has a non-empty value.
3152	// This may be used to include null fields in Patch requests.
3153	NullFields []string `json:"-"`
3154}
3155
3156func (s *ConnectionType) MarshalJSON() ([]byte, error) {
3157	type NoMethod ConnectionType
3158	raw := NoMethod(*s)
3159	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3160}
3161
3162// ConnectionTypesListResponse: Connection Type List Response
3163type ConnectionTypesListResponse struct {
3164	// ConnectionTypes: Collection of connection types such as broadband and
3165	// mobile.
3166	ConnectionTypes []*ConnectionType `json:"connectionTypes,omitempty"`
3167
3168	// Kind: Identifies what kind of resource this is. Value: the fixed
3169	// string "dfareporting#connectionTypesListResponse".
3170	Kind string `json:"kind,omitempty"`
3171
3172	// ServerResponse contains the HTTP response code and headers from the
3173	// server.
3174	googleapi.ServerResponse `json:"-"`
3175
3176	// ForceSendFields is a list of field names (e.g. "ConnectionTypes") to
3177	// unconditionally include in API requests. By default, fields with
3178	// empty values are omitted from API requests. However, any non-pointer,
3179	// non-interface field appearing in ForceSendFields will be sent to the
3180	// server regardless of whether the field is empty or not. This may be
3181	// used to include empty fields in Patch requests.
3182	ForceSendFields []string `json:"-"`
3183
3184	// NullFields is a list of field names (e.g. "ConnectionTypes") to
3185	// include in API requests with the JSON null value. By default, fields
3186	// with empty values are omitted from API requests. However, any field
3187	// with an empty value appearing in NullFields will be sent to the
3188	// server as null. It is an error if a field in this list has a
3189	// non-empty value. This may be used to include null fields in Patch
3190	// requests.
3191	NullFields []string `json:"-"`
3192}
3193
3194func (s *ConnectionTypesListResponse) MarshalJSON() ([]byte, error) {
3195	type NoMethod ConnectionTypesListResponse
3196	raw := NoMethod(*s)
3197	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3198}
3199
3200// ContentCategoriesListResponse: Content Category List Response
3201type ContentCategoriesListResponse struct {
3202	// ContentCategories: Content category collection.
3203	ContentCategories []*ContentCategory `json:"contentCategories,omitempty"`
3204
3205	// Kind: Identifies what kind of resource this is. Value: the fixed
3206	// string "dfareporting#contentCategoriesListResponse".
3207	Kind string `json:"kind,omitempty"`
3208
3209	// NextPageToken: Pagination token to be used for the next list
3210	// operation.
3211	NextPageToken string `json:"nextPageToken,omitempty"`
3212
3213	// ServerResponse contains the HTTP response code and headers from the
3214	// server.
3215	googleapi.ServerResponse `json:"-"`
3216
3217	// ForceSendFields is a list of field names (e.g. "ContentCategories")
3218	// to unconditionally include in API requests. By default, fields with
3219	// empty values are omitted from API requests. However, any non-pointer,
3220	// non-interface field appearing in ForceSendFields will be sent to the
3221	// server regardless of whether the field is empty or not. This may be
3222	// used to include empty fields in Patch requests.
3223	ForceSendFields []string `json:"-"`
3224
3225	// NullFields is a list of field names (e.g. "ContentCategories") to
3226	// include in API requests with the JSON null value. By default, fields
3227	// with empty values are omitted from API requests. However, any field
3228	// with an empty value appearing in NullFields will be sent to the
3229	// server as null. It is an error if a field in this list has a
3230	// non-empty value. This may be used to include null fields in Patch
3231	// requests.
3232	NullFields []string `json:"-"`
3233}
3234
3235func (s *ContentCategoriesListResponse) MarshalJSON() ([]byte, error) {
3236	type NoMethod ContentCategoriesListResponse
3237	raw := NoMethod(*s)
3238	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3239}
3240
3241// ContentCategory: Organizes placements according to the contents of
3242// their associated webpages.
3243type ContentCategory struct {
3244	// AccountId: Account ID of this content category. This is a read-only
3245	// field that can be left blank.
3246	AccountId int64 `json:"accountId,omitempty,string"`
3247
3248	// Id: ID of this content category. This is a read-only, auto-generated
3249	// field.
3250	Id int64 `json:"id,omitempty,string"`
3251
3252	// Kind: Identifies what kind of resource this is. Value: the fixed
3253	// string "dfareporting#contentCategory".
3254	Kind string `json:"kind,omitempty"`
3255
3256	// Name: Name of this content category. This is a required field and
3257	// must be less than 256 characters long and unique among content
3258	// categories of the same account.
3259	Name string `json:"name,omitempty"`
3260
3261	// ServerResponse contains the HTTP response code and headers from the
3262	// server.
3263	googleapi.ServerResponse `json:"-"`
3264
3265	// ForceSendFields is a list of field names (e.g. "AccountId") to
3266	// unconditionally include in API requests. By default, fields with
3267	// empty values are omitted from API requests. However, any non-pointer,
3268	// non-interface field appearing in ForceSendFields will be sent to the
3269	// server regardless of whether the field is empty or not. This may be
3270	// used to include empty fields in Patch requests.
3271	ForceSendFields []string `json:"-"`
3272
3273	// NullFields is a list of field names (e.g. "AccountId") to include in
3274	// API requests with the JSON null value. By default, fields with empty
3275	// values are omitted from API requests. However, any field with an
3276	// empty value appearing in NullFields will be sent to the server as
3277	// null. It is an error if a field in this list has a non-empty value.
3278	// This may be used to include null fields in Patch requests.
3279	NullFields []string `json:"-"`
3280}
3281
3282func (s *ContentCategory) MarshalJSON() ([]byte, error) {
3283	type NoMethod ContentCategory
3284	raw := NoMethod(*s)
3285	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3286}
3287
3288// Conversion: A Conversion represents when a user successfully performs
3289// a desired action after seeing an ad.
3290type Conversion struct {
3291	// ChildDirectedTreatment: Whether the conversion was directed toward
3292	// children.
3293	ChildDirectedTreatment bool `json:"childDirectedTreatment,omitempty"`
3294
3295	// CustomVariables: Custom floodlight variables.
3296	CustomVariables []*CustomFloodlightVariable `json:"customVariables,omitempty"`
3297
3298	// EncryptedUserId: The alphanumeric encrypted user ID. When set,
3299	// encryptionInfo should also be specified. This field is mutually
3300	// exclusive with encryptedUserIdCandidates[], mobileDeviceId and gclid.
3301	// This or encryptedUserIdCandidates[] or mobileDeviceId or gclid is a
3302	// required field.
3303	EncryptedUserId string `json:"encryptedUserId,omitempty"`
3304
3305	// EncryptedUserIdCandidates: A list of the alphanumeric encrypted user
3306	// IDs. Any user ID with exposure prior to the conversion timestamp will
3307	// be used in the inserted conversion. If no such user ID is found then
3308	// the conversion will be rejected with NO_COOKIE_MATCH_FOUND error.
3309	// When set, encryptionInfo should also be specified. This field may
3310	// only be used when calling batchinsert; it is not supported by
3311	// batchupdate. This field is mutually exclusive with encryptedUserId,
3312	// mobileDeviceId and gclid. This or encryptedUserId or mobileDeviceId
3313	// or gclid is a required field.
3314	EncryptedUserIdCandidates []string `json:"encryptedUserIdCandidates,omitempty"`
3315
3316	// FloodlightActivityId: Floodlight Activity ID of this conversion. This
3317	// is a required field.
3318	FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
3319
3320	// FloodlightConfigurationId: Floodlight Configuration ID of this
3321	// conversion. This is a required field.
3322	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
3323
3324	// Gclid: The Google click ID. This field is mutually exclusive with
3325	// encryptedUserId, encryptedUserIdCandidates[] and mobileDeviceId. This
3326	// or encryptedUserId or encryptedUserIdCandidates[] or mobileDeviceId
3327	// is a required field.
3328	Gclid string `json:"gclid,omitempty"`
3329
3330	// Kind: Identifies what kind of resource this is. Value: the fixed
3331	// string "dfareporting#conversion".
3332	Kind string `json:"kind,omitempty"`
3333
3334	// LimitAdTracking: Whether Limit Ad Tracking is enabled. When set to
3335	// true, the conversion will be used for reporting but not targeting.
3336	// This will prevent remarketing.
3337	LimitAdTracking bool `json:"limitAdTracking,omitempty"`
3338
3339	// MobileDeviceId: The mobile device ID. This field is mutually
3340	// exclusive with encryptedUserId, encryptedUserIdCandidates[] and
3341	// gclid. This or encryptedUserId or encryptedUserIdCandidates[] or
3342	// gclid is a required field.
3343	MobileDeviceId string `json:"mobileDeviceId,omitempty"`
3344
3345	// Ordinal: The ordinal of the conversion. Use this field to control how
3346	// conversions of the same user and day are de-duplicated. This is a
3347	// required field.
3348	Ordinal string `json:"ordinal,omitempty"`
3349
3350	// Quantity: The quantity of the conversion.
3351	Quantity int64 `json:"quantity,omitempty,string"`
3352
3353	// TimestampMicros: The timestamp of conversion, in Unix epoch micros.
3354	// This is a required field.
3355	TimestampMicros int64 `json:"timestampMicros,omitempty,string"`
3356
3357	// Value: The value of the conversion.
3358	Value float64 `json:"value,omitempty"`
3359
3360	// ForceSendFields is a list of field names (e.g.
3361	// "ChildDirectedTreatment") to unconditionally include in API requests.
3362	// By default, fields with empty values are omitted from API requests.
3363	// However, any non-pointer, non-interface field appearing in
3364	// ForceSendFields will be sent to the server regardless of whether the
3365	// field is empty or not. This may be used to include empty fields in
3366	// Patch requests.
3367	ForceSendFields []string `json:"-"`
3368
3369	// NullFields is a list of field names (e.g. "ChildDirectedTreatment")
3370	// to include in API requests with the JSON null value. By default,
3371	// fields with empty values are omitted from API requests. However, any
3372	// field with an empty value appearing in NullFields will be sent to the
3373	// server as null. It is an error if a field in this list has a
3374	// non-empty value. This may be used to include null fields in Patch
3375	// requests.
3376	NullFields []string `json:"-"`
3377}
3378
3379func (s *Conversion) MarshalJSON() ([]byte, error) {
3380	type NoMethod Conversion
3381	raw := NoMethod(*s)
3382	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3383}
3384
3385func (s *Conversion) UnmarshalJSON(data []byte) error {
3386	type NoMethod Conversion
3387	var s1 struct {
3388		Value gensupport.JSONFloat64 `json:"value"`
3389		*NoMethod
3390	}
3391	s1.NoMethod = (*NoMethod)(s)
3392	if err := json.Unmarshal(data, &s1); err != nil {
3393		return err
3394	}
3395	s.Value = float64(s1.Value)
3396	return nil
3397}
3398
3399// ConversionError: The error code and description for a conversion that
3400// failed to insert or update.
3401type ConversionError struct {
3402	// Code: The error code.
3403	//
3404	// Possible values:
3405	//   "INTERNAL"
3406	//   "INVALID_ARGUMENT"
3407	//   "NOT_FOUND"
3408	//   "PERMISSION_DENIED"
3409	Code string `json:"code,omitempty"`
3410
3411	// Kind: Identifies what kind of resource this is. Value: the fixed
3412	// string "dfareporting#conversionError".
3413	Kind string `json:"kind,omitempty"`
3414
3415	// Message: A description of the error.
3416	Message string `json:"message,omitempty"`
3417
3418	// ForceSendFields is a list of field names (e.g. "Code") to
3419	// unconditionally include in API requests. By default, fields with
3420	// empty values are omitted from API requests. However, any non-pointer,
3421	// non-interface field appearing in ForceSendFields will be sent to the
3422	// server regardless of whether the field is empty or not. This may be
3423	// used to include empty fields in Patch requests.
3424	ForceSendFields []string `json:"-"`
3425
3426	// NullFields is a list of field names (e.g. "Code") to include in API
3427	// requests with the JSON null value. By default, fields with empty
3428	// values are omitted from API requests. However, any field with an
3429	// empty value appearing in NullFields will be sent to the server as
3430	// null. It is an error if a field in this list has a non-empty value.
3431	// This may be used to include null fields in Patch requests.
3432	NullFields []string `json:"-"`
3433}
3434
3435func (s *ConversionError) MarshalJSON() ([]byte, error) {
3436	type NoMethod ConversionError
3437	raw := NoMethod(*s)
3438	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3439}
3440
3441// ConversionStatus: The original conversion that was inserted or
3442// updated and whether there were any errors.
3443type ConversionStatus struct {
3444	// Conversion: The original conversion that was inserted or updated.
3445	Conversion *Conversion `json:"conversion,omitempty"`
3446
3447	// Errors: A list of errors related to this conversion.
3448	Errors []*ConversionError `json:"errors,omitempty"`
3449
3450	// Kind: Identifies what kind of resource this is. Value: the fixed
3451	// string "dfareporting#conversionStatus".
3452	Kind string `json:"kind,omitempty"`
3453
3454	// ForceSendFields is a list of field names (e.g. "Conversion") to
3455	// unconditionally include in API requests. By default, fields with
3456	// empty values are omitted from API requests. However, any non-pointer,
3457	// non-interface field appearing in ForceSendFields will be sent to the
3458	// server regardless of whether the field is empty or not. This may be
3459	// used to include empty fields in Patch requests.
3460	ForceSendFields []string `json:"-"`
3461
3462	// NullFields is a list of field names (e.g. "Conversion") to include in
3463	// API requests with the JSON null value. By default, fields with empty
3464	// values are omitted from API requests. However, any field with an
3465	// empty value appearing in NullFields will be sent to the server as
3466	// null. It is an error if a field in this list has a non-empty value.
3467	// This may be used to include null fields in Patch requests.
3468	NullFields []string `json:"-"`
3469}
3470
3471func (s *ConversionStatus) MarshalJSON() ([]byte, error) {
3472	type NoMethod ConversionStatus
3473	raw := NoMethod(*s)
3474	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3475}
3476
3477// ConversionsBatchInsertRequest: Insert Conversions Request.
3478type ConversionsBatchInsertRequest struct {
3479	// Conversions: The set of conversions to insert.
3480	Conversions []*Conversion `json:"conversions,omitempty"`
3481
3482	// EncryptionInfo: Describes how encryptedUserId or
3483	// encryptedUserIdCandidates[] is encrypted. This is a required field if
3484	// encryptedUserId or encryptedUserIdCandidates[] is used.
3485	EncryptionInfo *EncryptionInfo `json:"encryptionInfo,omitempty"`
3486
3487	// Kind: Identifies what kind of resource this is. Value: the fixed
3488	// string "dfareporting#conversionsBatchInsertRequest".
3489	Kind string `json:"kind,omitempty"`
3490
3491	// ForceSendFields is a list of field names (e.g. "Conversions") to
3492	// unconditionally include in API requests. By default, fields with
3493	// empty values are omitted from API requests. However, any non-pointer,
3494	// non-interface field appearing in ForceSendFields will be sent to the
3495	// server regardless of whether the field is empty or not. This may be
3496	// used to include empty fields in Patch requests.
3497	ForceSendFields []string `json:"-"`
3498
3499	// NullFields is a list of field names (e.g. "Conversions") to include
3500	// in API requests with the JSON null value. By default, fields with
3501	// empty values are omitted from API requests. However, any field with
3502	// an empty value appearing in NullFields will be sent to the server as
3503	// null. It is an error if a field in this list has a non-empty value.
3504	// This may be used to include null fields in Patch requests.
3505	NullFields []string `json:"-"`
3506}
3507
3508func (s *ConversionsBatchInsertRequest) MarshalJSON() ([]byte, error) {
3509	type NoMethod ConversionsBatchInsertRequest
3510	raw := NoMethod(*s)
3511	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3512}
3513
3514// ConversionsBatchInsertResponse: Insert Conversions Response.
3515type ConversionsBatchInsertResponse struct {
3516	// HasFailures: Indicates that some or all conversions failed to insert.
3517	HasFailures bool `json:"hasFailures,omitempty"`
3518
3519	// Kind: Identifies what kind of resource this is. Value: the fixed
3520	// string "dfareporting#conversionsBatchInsertResponse".
3521	Kind string `json:"kind,omitempty"`
3522
3523	// Status: The insert status of each conversion. Statuses are returned
3524	// in the same order that conversions are inserted.
3525	Status []*ConversionStatus `json:"status,omitempty"`
3526
3527	// ServerResponse contains the HTTP response code and headers from the
3528	// server.
3529	googleapi.ServerResponse `json:"-"`
3530
3531	// ForceSendFields is a list of field names (e.g. "HasFailures") to
3532	// unconditionally include in API requests. By default, fields with
3533	// empty values are omitted from API requests. However, any non-pointer,
3534	// non-interface field appearing in ForceSendFields will be sent to the
3535	// server regardless of whether the field is empty or not. This may be
3536	// used to include empty fields in Patch requests.
3537	ForceSendFields []string `json:"-"`
3538
3539	// NullFields is a list of field names (e.g. "HasFailures") to include
3540	// in API requests with the JSON null value. By default, fields with
3541	// empty values are omitted from API requests. However, any field with
3542	// an empty value appearing in NullFields will be sent to the server as
3543	// null. It is an error if a field in this list has a non-empty value.
3544	// This may be used to include null fields in Patch requests.
3545	NullFields []string `json:"-"`
3546}
3547
3548func (s *ConversionsBatchInsertResponse) MarshalJSON() ([]byte, error) {
3549	type NoMethod ConversionsBatchInsertResponse
3550	raw := NoMethod(*s)
3551	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3552}
3553
3554// ConversionsBatchUpdateRequest: Update Conversions Request.
3555type ConversionsBatchUpdateRequest struct {
3556	// Conversions: The set of conversions to update.
3557	Conversions []*Conversion `json:"conversions,omitempty"`
3558
3559	// EncryptionInfo: Describes how encryptedUserId is encrypted. This is a
3560	// required field if encryptedUserId is used.
3561	EncryptionInfo *EncryptionInfo `json:"encryptionInfo,omitempty"`
3562
3563	// Kind: Identifies what kind of resource this is. Value: the fixed
3564	// string "dfareporting#conversionsBatchUpdateRequest".
3565	Kind string `json:"kind,omitempty"`
3566
3567	// ForceSendFields is a list of field names (e.g. "Conversions") to
3568	// unconditionally include in API requests. By default, fields with
3569	// empty values are omitted from API requests. However, any non-pointer,
3570	// non-interface field appearing in ForceSendFields will be sent to the
3571	// server regardless of whether the field is empty or not. This may be
3572	// used to include empty fields in Patch requests.
3573	ForceSendFields []string `json:"-"`
3574
3575	// NullFields is a list of field names (e.g. "Conversions") to include
3576	// in API requests with the JSON null value. By default, fields with
3577	// empty values are omitted from API requests. However, any field with
3578	// an empty value appearing in NullFields will be sent to the server as
3579	// null. It is an error if a field in this list has a non-empty value.
3580	// This may be used to include null fields in Patch requests.
3581	NullFields []string `json:"-"`
3582}
3583
3584func (s *ConversionsBatchUpdateRequest) MarshalJSON() ([]byte, error) {
3585	type NoMethod ConversionsBatchUpdateRequest
3586	raw := NoMethod(*s)
3587	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3588}
3589
3590// ConversionsBatchUpdateResponse: Update Conversions Response.
3591type ConversionsBatchUpdateResponse struct {
3592	// HasFailures: Indicates that some or all conversions failed to update.
3593	HasFailures bool `json:"hasFailures,omitempty"`
3594
3595	// Kind: Identifies what kind of resource this is. Value: the fixed
3596	// string "dfareporting#conversionsBatchUpdateResponse".
3597	Kind string `json:"kind,omitempty"`
3598
3599	// Status: The update status of each conversion. Statuses are returned
3600	// in the same order that conversions are updated.
3601	Status []*ConversionStatus `json:"status,omitempty"`
3602
3603	// ServerResponse contains the HTTP response code and headers from the
3604	// server.
3605	googleapi.ServerResponse `json:"-"`
3606
3607	// ForceSendFields is a list of field names (e.g. "HasFailures") to
3608	// unconditionally include in API requests. By default, fields with
3609	// empty values are omitted from API requests. However, any non-pointer,
3610	// non-interface field appearing in ForceSendFields will be sent to the
3611	// server regardless of whether the field is empty or not. This may be
3612	// used to include empty fields in Patch requests.
3613	ForceSendFields []string `json:"-"`
3614
3615	// NullFields is a list of field names (e.g. "HasFailures") to include
3616	// in API requests with the JSON null value. By default, fields with
3617	// empty values are omitted from API requests. However, any field with
3618	// an empty value appearing in NullFields will be sent to the server as
3619	// null. It is an error if a field in this list has a non-empty value.
3620	// This may be used to include null fields in Patch requests.
3621	NullFields []string `json:"-"`
3622}
3623
3624func (s *ConversionsBatchUpdateResponse) MarshalJSON() ([]byte, error) {
3625	type NoMethod ConversionsBatchUpdateResponse
3626	raw := NoMethod(*s)
3627	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3628}
3629
3630// CountriesListResponse: Country List Response
3631type CountriesListResponse struct {
3632	// Countries: Country collection.
3633	Countries []*Country `json:"countries,omitempty"`
3634
3635	// Kind: Identifies what kind of resource this is. Value: the fixed
3636	// string "dfareporting#countriesListResponse".
3637	Kind string `json:"kind,omitempty"`
3638
3639	// ServerResponse contains the HTTP response code and headers from the
3640	// server.
3641	googleapi.ServerResponse `json:"-"`
3642
3643	// ForceSendFields is a list of field names (e.g. "Countries") to
3644	// unconditionally include in API requests. By default, fields with
3645	// empty values are omitted from API requests. However, any non-pointer,
3646	// non-interface field appearing in ForceSendFields will be sent to the
3647	// server regardless of whether the field is empty or not. This may be
3648	// used to include empty fields in Patch requests.
3649	ForceSendFields []string `json:"-"`
3650
3651	// NullFields is a list of field names (e.g. "Countries") to include in
3652	// API requests with the JSON null value. By default, fields with empty
3653	// values are omitted from API requests. However, any field with an
3654	// empty value appearing in NullFields will be sent to the server as
3655	// null. It is an error if a field in this list has a non-empty value.
3656	// This may be used to include null fields in Patch requests.
3657	NullFields []string `json:"-"`
3658}
3659
3660func (s *CountriesListResponse) MarshalJSON() ([]byte, error) {
3661	type NoMethod CountriesListResponse
3662	raw := NoMethod(*s)
3663	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3664}
3665
3666// Country: Contains information about a country that can be targeted by
3667// ads.
3668type Country struct {
3669	// CountryCode: Country code.
3670	CountryCode string `json:"countryCode,omitempty"`
3671
3672	// DartId: DART ID of this country. This is the ID used for targeting
3673	// and generating reports.
3674	DartId int64 `json:"dartId,omitempty,string"`
3675
3676	// Kind: Identifies what kind of resource this is. Value: the fixed
3677	// string "dfareporting#country".
3678	Kind string `json:"kind,omitempty"`
3679
3680	// Name: Name of this country.
3681	Name string `json:"name,omitempty"`
3682
3683	// SslEnabled: Whether ad serving supports secure servers in this
3684	// country.
3685	SslEnabled bool `json:"sslEnabled,omitempty"`
3686
3687	// ServerResponse contains the HTTP response code and headers from the
3688	// server.
3689	googleapi.ServerResponse `json:"-"`
3690
3691	// ForceSendFields is a list of field names (e.g. "CountryCode") to
3692	// unconditionally include in API requests. By default, fields with
3693	// empty values are omitted from API requests. However, any non-pointer,
3694	// non-interface field appearing in ForceSendFields will be sent to the
3695	// server regardless of whether the field is empty or not. This may be
3696	// used to include empty fields in Patch requests.
3697	ForceSendFields []string `json:"-"`
3698
3699	// NullFields is a list of field names (e.g. "CountryCode") to include
3700	// in API requests with the JSON null value. By default, fields with
3701	// empty values are omitted from API requests. However, any field with
3702	// an empty value appearing in NullFields will be sent to the server as
3703	// null. It is an error if a field in this list has a non-empty value.
3704	// This may be used to include null fields in Patch requests.
3705	NullFields []string `json:"-"`
3706}
3707
3708func (s *Country) MarshalJSON() ([]byte, error) {
3709	type NoMethod Country
3710	raw := NoMethod(*s)
3711	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3712}
3713
3714// Creative: Contains properties of a Creative.
3715type Creative struct {
3716	// AccountId: Account ID of this creative. This field, if left unset,
3717	// will be auto-generated for both insert and update operations.
3718	// Applicable to all creative types.
3719	AccountId int64 `json:"accountId,omitempty,string"`
3720
3721	// Active: Whether the creative is active. Applicable to all creative
3722	// types.
3723	Active bool `json:"active,omitempty"`
3724
3725	// AdParameters: Ad parameters user for VPAID creative. This is a
3726	// read-only field. Applicable to the following creative types: all
3727	// VPAID.
3728	AdParameters string `json:"adParameters,omitempty"`
3729
3730	// AdTagKeys: Keywords for a Rich Media creative. Keywords let you
3731	// customize the creative settings of a Rich Media ad running on your
3732	// site without having to contact the advertiser. You can use keywords
3733	// to dynamically change the look or functionality of a creative.
3734	// Applicable to the following creative types: all RICH_MEDIA, and all
3735	// VPAID.
3736	AdTagKeys []string `json:"adTagKeys,omitempty"`
3737
3738	// AdvertiserId: Advertiser ID of this creative. This is a required
3739	// field. Applicable to all creative types.
3740	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
3741
3742	// AllowScriptAccess: Whether script access is allowed for this
3743	// creative. This is a read-only and deprecated field which will
3744	// automatically be set to true on update. Applicable to the following
3745	// creative types: FLASH_INPAGE.
3746	AllowScriptAccess bool `json:"allowScriptAccess,omitempty"`
3747
3748	// Archived: Whether the creative is archived. Applicable to all
3749	// creative types.
3750	Archived bool `json:"archived,omitempty"`
3751
3752	// ArtworkType: Type of artwork used for the creative. This is a
3753	// read-only field. Applicable to the following creative types: all
3754	// RICH_MEDIA, and all VPAID.
3755	//
3756	// Possible values:
3757	//   "ARTWORK_TYPE_FLASH"
3758	//   "ARTWORK_TYPE_HTML5"
3759	//   "ARTWORK_TYPE_IMAGE"
3760	//   "ARTWORK_TYPE_MIXED"
3761	ArtworkType string `json:"artworkType,omitempty"`
3762
3763	// AuthoringSource: Source application where creative was authored.
3764	// Presently, only DBM authored creatives will have this field set.
3765	// Applicable to all creative types.
3766	//
3767	// Possible values:
3768	//   "CREATIVE_AUTHORING_SOURCE_DBM"
3769	//   "CREATIVE_AUTHORING_SOURCE_DCM"
3770	//   "CREATIVE_AUTHORING_SOURCE_STUDIO"
3771	AuthoringSource string `json:"authoringSource,omitempty"`
3772
3773	// AuthoringTool: Authoring tool for HTML5 banner creatives. This is a
3774	// read-only field. Applicable to the following creative types:
3775	// HTML5_BANNER.
3776	//
3777	// Possible values:
3778	//   "NINJA"
3779	//   "SWIFFY"
3780	AuthoringTool string `json:"authoringTool,omitempty"`
3781
3782	// AutoAdvanceImages: Whether images are automatically advanced for
3783	// image gallery creatives. Applicable to the following creative types:
3784	// DISPLAY_IMAGE_GALLERY.
3785	AutoAdvanceImages bool `json:"autoAdvanceImages,omitempty"`
3786
3787	// BackgroundColor: The 6-character HTML color code, beginning with #,
3788	// for the background of the window area where the Flash file is
3789	// displayed. Default is white. Applicable to the following creative
3790	// types: FLASH_INPAGE.
3791	BackgroundColor string `json:"backgroundColor,omitempty"`
3792
3793	// BackupImageClickThroughUrl: Click-through URL for backup image.
3794	// Applicable to ENHANCED_BANNER when the primary asset type is not
3795	// HTML_IMAGE.
3796	BackupImageClickThroughUrl *CreativeClickThroughUrl `json:"backupImageClickThroughUrl,omitempty"`
3797
3798	// BackupImageFeatures: List of feature dependencies that will cause a
3799	// backup image to be served if the browser that serves the ad does not
3800	// support them. Feature dependencies are features that a browser must
3801	// be able to support in order to render your HTML5 creative asset
3802	// correctly. This field is initially auto-generated to contain all
3803	// features detected by Campaign Manager for all the assets of this
3804	// creative and can then be modified by the client. To reset this field,
3805	// copy over all the creativeAssets' detected features. Applicable to
3806	// the following creative types: HTML5_BANNER. Applicable to DISPLAY
3807	// when the primary asset type is not HTML_IMAGE.
3808	//
3809	// Possible values:
3810	//   "APPLICATION_CACHE"
3811	//   "AUDIO"
3812	//   "CANVAS"
3813	//   "CANVAS_TEXT"
3814	//   "CSS_ANIMATIONS"
3815	//   "CSS_BACKGROUND_SIZE"
3816	//   "CSS_BORDER_IMAGE"
3817	//   "CSS_BORDER_RADIUS"
3818	//   "CSS_BOX_SHADOW"
3819	//   "CSS_COLUMNS"
3820	//   "CSS_FLEX_BOX"
3821	//   "CSS_FONT_FACE"
3822	//   "CSS_GENERATED_CONTENT"
3823	//   "CSS_GRADIENTS"
3824	//   "CSS_HSLA"
3825	//   "CSS_MULTIPLE_BGS"
3826	//   "CSS_OPACITY"
3827	//   "CSS_REFLECTIONS"
3828	//   "CSS_RGBA"
3829	//   "CSS_TEXT_SHADOW"
3830	//   "CSS_TRANSFORMS"
3831	//   "CSS_TRANSFORMS3D"
3832	//   "CSS_TRANSITIONS"
3833	//   "DRAG_AND_DROP"
3834	//   "GEO_LOCATION"
3835	//   "HASH_CHANGE"
3836	//   "HISTORY"
3837	//   "INDEXED_DB"
3838	//   "INLINE_SVG"
3839	//   "INPUT_ATTR_AUTOCOMPLETE"
3840	//   "INPUT_ATTR_AUTOFOCUS"
3841	//   "INPUT_ATTR_LIST"
3842	//   "INPUT_ATTR_MAX"
3843	//   "INPUT_ATTR_MIN"
3844	//   "INPUT_ATTR_MULTIPLE"
3845	//   "INPUT_ATTR_PATTERN"
3846	//   "INPUT_ATTR_PLACEHOLDER"
3847	//   "INPUT_ATTR_REQUIRED"
3848	//   "INPUT_ATTR_STEP"
3849	//   "INPUT_TYPE_COLOR"
3850	//   "INPUT_TYPE_DATE"
3851	//   "INPUT_TYPE_DATETIME"
3852	//   "INPUT_TYPE_DATETIME_LOCAL"
3853	//   "INPUT_TYPE_EMAIL"
3854	//   "INPUT_TYPE_MONTH"
3855	//   "INPUT_TYPE_NUMBER"
3856	//   "INPUT_TYPE_RANGE"
3857	//   "INPUT_TYPE_SEARCH"
3858	//   "INPUT_TYPE_TEL"
3859	//   "INPUT_TYPE_TIME"
3860	//   "INPUT_TYPE_URL"
3861	//   "INPUT_TYPE_WEEK"
3862	//   "LOCAL_STORAGE"
3863	//   "POST_MESSAGE"
3864	//   "SESSION_STORAGE"
3865	//   "SMIL"
3866	//   "SVG_CLIP_PATHS"
3867	//   "SVG_FE_IMAGE"
3868	//   "SVG_FILTERS"
3869	//   "SVG_HREF"
3870	//   "TOUCH"
3871	//   "VIDEO"
3872	//   "WEBGL"
3873	//   "WEB_SOCKETS"
3874	//   "WEB_SQL_DATABASE"
3875	//   "WEB_WORKERS"
3876	BackupImageFeatures []string `json:"backupImageFeatures,omitempty"`
3877
3878	// BackupImageReportingLabel: Reporting label used for HTML5 banner
3879	// backup image. Applicable to the following creative types: DISPLAY
3880	// when the primary asset type is not HTML_IMAGE.
3881	BackupImageReportingLabel string `json:"backupImageReportingLabel,omitempty"`
3882
3883	// BackupImageTargetWindow: Target window for backup image. Applicable
3884	// to the following creative types: FLASH_INPAGE and HTML5_BANNER.
3885	// Applicable to DISPLAY when the primary asset type is not HTML_IMAGE.
3886	BackupImageTargetWindow *TargetWindow `json:"backupImageTargetWindow,omitempty"`
3887
3888	// ClickTags: Click tags of the creative. For DISPLAY, FLASH_INPAGE, and
3889	// HTML5_BANNER creatives, this is a subset of detected click tags for
3890	// the assets associated with this creative. After creating a flash
3891	// asset, detected click tags will be returned in the
3892	// creativeAssetMetadata. When inserting the creative, populate the
3893	// creative clickTags field using the creativeAssetMetadata.clickTags
3894	// field. For DISPLAY_IMAGE_GALLERY creatives, there should be exactly
3895	// one entry in this list for each image creative asset. A click tag is
3896	// matched with a corresponding creative asset by matching the
3897	// clickTag.name field with the creativeAsset.assetIdentifier.name
3898	// field. Applicable to the following creative types:
3899	// DISPLAY_IMAGE_GALLERY, FLASH_INPAGE, HTML5_BANNER. Applicable to
3900	// DISPLAY when the primary asset type is not HTML_IMAGE.
3901	ClickTags []*ClickTag `json:"clickTags,omitempty"`
3902
3903	// CommercialId: Industry standard ID assigned to creative for reach and
3904	// frequency. Applicable to INSTREAM_VIDEO_REDIRECT creatives.
3905	CommercialId string `json:"commercialId,omitempty"`
3906
3907	// CompanionCreatives: List of companion creatives assigned to an
3908	// in-Stream video creative. Acceptable values include IDs of existing
3909	// flash and image creatives. Applicable to the following creative
3910	// types: all VPAID, all INSTREAM_AUDIO and all INSTREAM_VIDEO with
3911	// dynamicAssetSelection set to false.
3912	CompanionCreatives googleapi.Int64s `json:"companionCreatives,omitempty"`
3913
3914	// Compatibility: Compatibilities associated with this creative. This is
3915	// a read-only field. DISPLAY and DISPLAY_INTERSTITIAL refer to
3916	// rendering either on desktop or on mobile devices or in mobile apps
3917	// for regular or interstitial ads, respectively. APP and
3918	// APP_INTERSTITIAL are for rendering in mobile apps. Only pre-existing
3919	// creatives may have these compatibilities since new creatives will
3920	// either be assigned DISPLAY or DISPLAY_INTERSTITIAL instead.
3921	// IN_STREAM_VIDEO refers to rendering in in-stream video ads developed
3922	// with the VAST standard. IN_STREAM_AUDIO refers to rendering in
3923	// in-stream audio ads developed with the VAST standard. Applicable to
3924	// all creative types.
3925	//
3926	// Acceptable values are:
3927	// - "APP"
3928	// - "APP_INTERSTITIAL"
3929	// - "IN_STREAM_VIDEO"
3930	// - "IN_STREAM_AUDIO"
3931	// - "DISPLAY"
3932	// - "DISPLAY_INTERSTITIAL"
3933	//
3934	// Possible values:
3935	//   "APP"
3936	//   "APP_INTERSTITIAL"
3937	//   "DISPLAY"
3938	//   "DISPLAY_INTERSTITIAL"
3939	//   "IN_STREAM_AUDIO"
3940	//   "IN_STREAM_VIDEO"
3941	Compatibility []string `json:"compatibility,omitempty"`
3942
3943	// ConvertFlashToHtml5: Whether Flash assets associated with the
3944	// creative need to be automatically converted to HTML5. This flag is
3945	// enabled by default and users can choose to disable it if they don't
3946	// want the system to generate and use HTML5 asset for this creative.
3947	// Applicable to the following creative type: FLASH_INPAGE. Applicable
3948	// to DISPLAY when the primary asset type is not HTML_IMAGE.
3949	ConvertFlashToHtml5 bool `json:"convertFlashToHtml5,omitempty"`
3950
3951	// CounterCustomEvents: List of counter events configured for the
3952	// creative. For DISPLAY_IMAGE_GALLERY creatives, these are read-only
3953	// and auto-generated from clickTags. Applicable to the following
3954	// creative types: DISPLAY_IMAGE_GALLERY, all RICH_MEDIA, and all VPAID.
3955	CounterCustomEvents []*CreativeCustomEvent `json:"counterCustomEvents,omitempty"`
3956
3957	// CreativeAssetSelection: Required if dynamicAssetSelection is true.
3958	CreativeAssetSelection *CreativeAssetSelection `json:"creativeAssetSelection,omitempty"`
3959
3960	// CreativeAssets: Assets associated with a creative. Applicable to all
3961	// but the following creative types: INTERNAL_REDIRECT,
3962	// INTERSTITIAL_INTERNAL_REDIRECT, and REDIRECT
3963	CreativeAssets []*CreativeAsset `json:"creativeAssets,omitempty"`
3964
3965	// CreativeFieldAssignments: Creative field assignments for this
3966	// creative. Applicable to all creative types.
3967	CreativeFieldAssignments []*CreativeFieldAssignment `json:"creativeFieldAssignments,omitempty"`
3968
3969	// CustomKeyValues: Custom key-values for a Rich Media creative.
3970	// Key-values let you customize the creative settings of a Rich Media ad
3971	// running on your site without having to contact the advertiser. You
3972	// can use key-values to dynamically change the look or functionality of
3973	// a creative. Applicable to the following creative types: all
3974	// RICH_MEDIA, and all VPAID.
3975	CustomKeyValues []string `json:"customKeyValues,omitempty"`
3976
3977	// DynamicAssetSelection: Set this to true to enable the use of rules to
3978	// target individual assets in this creative. When set to true
3979	// creativeAssetSelection must be set. This also controls asset-level
3980	// companions. When this is true, companion creatives should be assigned
3981	// to creative assets. Learn more. Applicable to INSTREAM_VIDEO
3982	// creatives.
3983	DynamicAssetSelection bool `json:"dynamicAssetSelection,omitempty"`
3984
3985	// ExitCustomEvents: List of exit events configured for the creative.
3986	// For DISPLAY and DISPLAY_IMAGE_GALLERY creatives, these are read-only
3987	// and auto-generated from clickTags, For DISPLAY, an event is also
3988	// created from the backupImageReportingLabel. Applicable to the
3989	// following creative types: DISPLAY_IMAGE_GALLERY, all RICH_MEDIA, and
3990	// all VPAID. Applicable to DISPLAY when the primary asset type is not
3991	// HTML_IMAGE.
3992	ExitCustomEvents []*CreativeCustomEvent `json:"exitCustomEvents,omitempty"`
3993
3994	// FsCommand: OpenWindow FSCommand of this creative. This lets the SWF
3995	// file communicate with either Flash Player or the program hosting
3996	// Flash Player, such as a web browser. This is only triggered if
3997	// allowScriptAccess field is true. Applicable to the following creative
3998	// types: FLASH_INPAGE.
3999	FsCommand *FsCommand `json:"fsCommand,omitempty"`
4000
4001	// HtmlCode: HTML code for the creative. This is a required field when
4002	// applicable. This field is ignored if htmlCodeLocked is true.
4003	// Applicable to the following creative types: all CUSTOM, FLASH_INPAGE,
4004	// and HTML5_BANNER, and all RICH_MEDIA.
4005	HtmlCode string `json:"htmlCode,omitempty"`
4006
4007	// HtmlCodeLocked: Whether HTML code is generated by Campaign Manager or
4008	// manually entered. Set to true to ignore changes to htmlCode.
4009	// Applicable to the following creative types: FLASH_INPAGE and
4010	// HTML5_BANNER.
4011	HtmlCodeLocked bool `json:"htmlCodeLocked,omitempty"`
4012
4013	// Id: ID of this creative. This is a read-only, auto-generated field.
4014	// Applicable to all creative types.
4015	Id int64 `json:"id,omitempty,string"`
4016
4017	// IdDimensionValue: Dimension value for the ID of this creative. This
4018	// is a read-only field. Applicable to all creative types.
4019	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4020
4021	// Kind: Identifies what kind of resource this is. Value: the fixed
4022	// string "dfareporting#creative".
4023	Kind string `json:"kind,omitempty"`
4024
4025	// LastModifiedInfo: Creative last modification information. This is a
4026	// read-only field. Applicable to all creative types.
4027	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
4028
4029	// LatestTraffickedCreativeId: Latest Studio trafficked creative ID
4030	// associated with rich media and VPAID creatives. This is a read-only
4031	// field. Applicable to the following creative types: all RICH_MEDIA,
4032	// and all VPAID.
4033	LatestTraffickedCreativeId int64 `json:"latestTraffickedCreativeId,omitempty,string"`
4034
4035	// MediaDescription: Description of the audio or video ad. Applicable to
4036	// the following creative types: all INSTREAM_VIDEO, INSTREAM_AUDIO, and
4037	// all VPAID.
4038	MediaDescription string `json:"mediaDescription,omitempty"`
4039
4040	// MediaDuration: Creative audio or video duration in seconds. This is a
4041	// read-only field. Applicable to the following creative types:
4042	// INSTREAM_VIDEO, INSTREAM_AUDIO, all RICH_MEDIA, and all VPAID.
4043	MediaDuration float64 `json:"mediaDuration,omitempty"`
4044
4045	// Name: Name of the creative. This is a required field and must be less
4046	// than 256 characters long. Applicable to all creative types.
4047	Name string `json:"name,omitempty"`
4048
4049	// OverrideCss: Override CSS value for rich media creatives. Applicable
4050	// to the following creative types: all RICH_MEDIA.
4051	OverrideCss string `json:"overrideCss,omitempty"`
4052
4053	// PoliteLoadAssetId: The asset ID of the polite load image asset.
4054	// Applicable to the creative type: DISPLAY.
4055	PoliteLoadAssetId int64 `json:"politeLoadAssetId,omitempty,string"`
4056
4057	// ProgressOffset: Amount of time to play the video before counting a
4058	// view. Applicable to the following creative types: all INSTREAM_VIDEO.
4059	ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
4060
4061	// RedirectUrl: URL of hosted image or hosted video or another ad tag.
4062	// For INSTREAM_VIDEO_REDIRECT creatives this is the in-stream video
4063	// redirect URL. The standard for a VAST (Video Ad Serving Template) ad
4064	// response allows for a redirect link to another VAST 2.0 or 3.0 call.
4065	// This is a required field when applicable. Applicable to the following
4066	// creative types: DISPLAY_REDIRECT, INTERNAL_REDIRECT,
4067	// INTERSTITIAL_INTERNAL_REDIRECT, and INSTREAM_VIDEO_REDIRECT
4068	RedirectUrl string `json:"redirectUrl,omitempty"`
4069
4070	// RenderingId: ID of current rendering version. This is a read-only
4071	// field. Applicable to all creative types.
4072	RenderingId int64 `json:"renderingId,omitempty,string"`
4073
4074	// RenderingIdDimensionValue: Dimension value for the rendering ID of
4075	// this creative. This is a read-only field. Applicable to all creative
4076	// types.
4077	RenderingIdDimensionValue *DimensionValue `json:"renderingIdDimensionValue,omitempty"`
4078
4079	// RequiredFlashPluginVersion: The minimum required Flash plugin version
4080	// for this creative. For example, 11.2.202.235. This is a read-only
4081	// field. Applicable to the following creative types: all RICH_MEDIA,
4082	// and all VPAID.
4083	RequiredFlashPluginVersion string `json:"requiredFlashPluginVersion,omitempty"`
4084
4085	// RequiredFlashVersion: The internal Flash version for this creative as
4086	// calculated by Studio. This is a read-only field. Applicable to the
4087	// following creative types: FLASH_INPAGE all RICH_MEDIA, and all VPAID.
4088	// Applicable to DISPLAY when the primary asset type is not HTML_IMAGE.
4089	RequiredFlashVersion int64 `json:"requiredFlashVersion,omitempty"`
4090
4091	// Size: Size associated with this creative. When inserting or updating
4092	// a creative either the size ID field or size width and height fields
4093	// can be used. This is a required field when applicable; however for
4094	// IMAGE, FLASH_INPAGE creatives, and for DISPLAY creatives with a
4095	// primary asset of type HTML_IMAGE, if left blank, this field will be
4096	// automatically set using the actual size of the associated image
4097	// assets. Applicable to the following creative types: DISPLAY,
4098	// DISPLAY_IMAGE_GALLERY, FLASH_INPAGE, HTML5_BANNER, IMAGE, and all
4099	// RICH_MEDIA.
4100	Size *Size `json:"size,omitempty"`
4101
4102	// SkipOffset: Amount of time to play the video before the skip button
4103	// appears. Applicable to the following creative types: all
4104	// INSTREAM_VIDEO.
4105	SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
4106
4107	// Skippable: Whether the user can choose to skip the creative.
4108	// Applicable to the following creative types: all INSTREAM_VIDEO and
4109	// all VPAID.
4110	Skippable bool `json:"skippable,omitempty"`
4111
4112	// SslCompliant: Whether the creative is SSL-compliant. This is a
4113	// read-only field. Applicable to all creative types.
4114	SslCompliant bool `json:"sslCompliant,omitempty"`
4115
4116	// SslOverride: Whether creative should be treated as SSL compliant even
4117	// if the system scan shows it's not. Applicable to all creative types.
4118	SslOverride bool `json:"sslOverride,omitempty"`
4119
4120	// StudioAdvertiserId: Studio advertiser ID associated with rich media
4121	// and VPAID creatives. This is a read-only field. Applicable to the
4122	// following creative types: all RICH_MEDIA, and all VPAID.
4123	StudioAdvertiserId int64 `json:"studioAdvertiserId,omitempty,string"`
4124
4125	// StudioCreativeId: Studio creative ID associated with rich media and
4126	// VPAID creatives. This is a read-only field. Applicable to the
4127	// following creative types: all RICH_MEDIA, and all VPAID.
4128	StudioCreativeId int64 `json:"studioCreativeId,omitempty,string"`
4129
4130	// StudioTraffickedCreativeId: Studio trafficked creative ID associated
4131	// with rich media and VPAID creatives. This is a read-only field.
4132	// Applicable to the following creative types: all RICH_MEDIA, and all
4133	// VPAID.
4134	StudioTraffickedCreativeId int64 `json:"studioTraffickedCreativeId,omitempty,string"`
4135
4136	// SubaccountId: Subaccount ID of this creative. This field, if left
4137	// unset, will be auto-generated for both insert and update operations.
4138	// Applicable to all creative types.
4139	SubaccountId int64 `json:"subaccountId,omitempty,string"`
4140
4141	// ThirdPartyBackupImageImpressionsUrl: Third-party URL used to record
4142	// backup image impressions. Applicable to the following creative types:
4143	// all RICH_MEDIA.
4144	ThirdPartyBackupImageImpressionsUrl string `json:"thirdPartyBackupImageImpressionsUrl,omitempty"`
4145
4146	// ThirdPartyRichMediaImpressionsUrl: Third-party URL used to record
4147	// rich media impressions. Applicable to the following creative types:
4148	// all RICH_MEDIA.
4149	ThirdPartyRichMediaImpressionsUrl string `json:"thirdPartyRichMediaImpressionsUrl,omitempty"`
4150
4151	// ThirdPartyUrls: Third-party URLs for tracking in-stream creative
4152	// events. Applicable to the following creative types: all
4153	// INSTREAM_VIDEO, all INSTREAM_AUDIO, and all VPAID.
4154	ThirdPartyUrls []*ThirdPartyTrackingUrl `json:"thirdPartyUrls,omitempty"`
4155
4156	// TimerCustomEvents: List of timer events configured for the creative.
4157	// For DISPLAY_IMAGE_GALLERY creatives, these are read-only and
4158	// auto-generated from clickTags. Applicable to the following creative
4159	// types: DISPLAY_IMAGE_GALLERY, all RICH_MEDIA, and all VPAID.
4160	// Applicable to DISPLAY when the primary asset is not HTML_IMAGE.
4161	TimerCustomEvents []*CreativeCustomEvent `json:"timerCustomEvents,omitempty"`
4162
4163	// TotalFileSize: Combined size of all creative assets. This is a
4164	// read-only field. Applicable to the following creative types: all
4165	// RICH_MEDIA, and all VPAID.
4166	TotalFileSize int64 `json:"totalFileSize,omitempty,string"`
4167
4168	// Type: Type of this creative. This is a required field. Applicable to
4169	// all creative types.
4170	//
4171	// Note: FLASH_INPAGE, HTML5_BANNER, and IMAGE are only used for
4172	// existing creatives. New creatives should use DISPLAY as a replacement
4173	// for these types.
4174	//
4175	// Possible values:
4176	//   "BRAND_SAFE_DEFAULT_INSTREAM_VIDEO"
4177	//   "CUSTOM_DISPLAY"
4178	//   "CUSTOM_DISPLAY_INTERSTITIAL"
4179	//   "DISPLAY"
4180	//   "DISPLAY_IMAGE_GALLERY"
4181	//   "DISPLAY_REDIRECT"
4182	//   "FLASH_INPAGE"
4183	//   "HTML5_BANNER"
4184	//   "IMAGE"
4185	//   "INSTREAM_AUDIO"
4186	//   "INSTREAM_VIDEO"
4187	//   "INSTREAM_VIDEO_REDIRECT"
4188	//   "INTERNAL_REDIRECT"
4189	//   "INTERSTITIAL_INTERNAL_REDIRECT"
4190	//   "RICH_MEDIA_DISPLAY_BANNER"
4191	//   "RICH_MEDIA_DISPLAY_EXPANDING"
4192	//   "RICH_MEDIA_DISPLAY_INTERSTITIAL"
4193	//   "RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL"
4194	//   "RICH_MEDIA_IM_EXPAND"
4195	//   "RICH_MEDIA_INPAGE_FLOATING"
4196	//   "RICH_MEDIA_MOBILE_IN_APP"
4197	//   "RICH_MEDIA_PEEL_DOWN"
4198	//   "TRACKING_TEXT"
4199	//   "VPAID_LINEAR_VIDEO"
4200	//   "VPAID_NON_LINEAR_VIDEO"
4201	Type string `json:"type,omitempty"`
4202
4203	// UniversalAdId: A Universal Ad ID as per the VAST 4.0 spec. Applicable
4204	// to the following creative types: INSTREAM_AUDIO and INSTREAM_VIDEO
4205	// and VPAID.
4206	UniversalAdId *UniversalAdId `json:"universalAdId,omitempty"`
4207
4208	// Version: The version number helps you keep track of multiple versions
4209	// of your creative in your reports. The version number will always be
4210	// auto-generated during insert operations to start at 1. For tracking
4211	// creatives the version cannot be incremented and will always remain at
4212	// 1. For all other creative types the version can be incremented only
4213	// by 1 during update operations. In addition, the version will be
4214	// automatically incremented by 1 when undergoing Rich Media creative
4215	// merging. Applicable to all creative types.
4216	Version int64 `json:"version,omitempty"`
4217
4218	// ServerResponse contains the HTTP response code and headers from the
4219	// server.
4220	googleapi.ServerResponse `json:"-"`
4221
4222	// ForceSendFields is a list of field names (e.g. "AccountId") to
4223	// unconditionally include in API requests. By default, fields with
4224	// empty values are omitted from API requests. However, any non-pointer,
4225	// non-interface field appearing in ForceSendFields will be sent to the
4226	// server regardless of whether the field is empty or not. This may be
4227	// used to include empty fields in Patch requests.
4228	ForceSendFields []string `json:"-"`
4229
4230	// NullFields is a list of field names (e.g. "AccountId") to include in
4231	// API requests with the JSON null value. By default, fields with empty
4232	// values are omitted from API requests. However, any field with an
4233	// empty value appearing in NullFields will be sent to the server as
4234	// null. It is an error if a field in this list has a non-empty value.
4235	// This may be used to include null fields in Patch requests.
4236	NullFields []string `json:"-"`
4237}
4238
4239func (s *Creative) MarshalJSON() ([]byte, error) {
4240	type NoMethod Creative
4241	raw := NoMethod(*s)
4242	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4243}
4244
4245func (s *Creative) UnmarshalJSON(data []byte) error {
4246	type NoMethod Creative
4247	var s1 struct {
4248		MediaDuration gensupport.JSONFloat64 `json:"mediaDuration"`
4249		*NoMethod
4250	}
4251	s1.NoMethod = (*NoMethod)(s)
4252	if err := json.Unmarshal(data, &s1); err != nil {
4253		return err
4254	}
4255	s.MediaDuration = float64(s1.MediaDuration)
4256	return nil
4257}
4258
4259// CreativeAsset: Creative Asset.
4260type CreativeAsset struct {
4261	// ActionScript3: Whether ActionScript3 is enabled for the flash asset.
4262	// This is a read-only field. Applicable to the following creative type:
4263	// FLASH_INPAGE. Applicable to DISPLAY when the primary asset type is
4264	// not HTML_IMAGE.
4265	ActionScript3 bool `json:"actionScript3,omitempty"`
4266
4267	// Active: Whether the video or audio asset is active. This is a
4268	// read-only field for VPAID_NON_LINEAR_VIDEO assets. Applicable to the
4269	// following creative types: INSTREAM_AUDIO, INSTREAM_VIDEO and all
4270	// VPAID.
4271	Active bool `json:"active,omitempty"`
4272
4273	// Alignment: Possible alignments for an asset. This is a read-only
4274	// field. Applicable to the following creative types:
4275	// RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL.
4276	//
4277	// Possible values:
4278	//   "ALIGNMENT_BOTTOM"
4279	//   "ALIGNMENT_LEFT"
4280	//   "ALIGNMENT_RIGHT"
4281	//   "ALIGNMENT_TOP"
4282	Alignment string `json:"alignment,omitempty"`
4283
4284	// ArtworkType: Artwork type of rich media creative. This is a read-only
4285	// field. Applicable to the following creative types: all RICH_MEDIA.
4286	//
4287	// Possible values:
4288	//   "ARTWORK_TYPE_FLASH"
4289	//   "ARTWORK_TYPE_HTML5"
4290	//   "ARTWORK_TYPE_IMAGE"
4291	//   "ARTWORK_TYPE_MIXED"
4292	ArtworkType string `json:"artworkType,omitempty"`
4293
4294	// AssetIdentifier: Identifier of this asset. This is the same
4295	// identifier returned during creative asset insert operation. This is a
4296	// required field. Applicable to all but the following creative types:
4297	// all REDIRECT and TRACKING_TEXT.
4298	AssetIdentifier *CreativeAssetId `json:"assetIdentifier,omitempty"`
4299
4300	// BackupImageExit: Exit event configured for the backup image.
4301	// Applicable to the following creative types: all RICH_MEDIA.
4302	BackupImageExit *CreativeCustomEvent `json:"backupImageExit,omitempty"`
4303
4304	// BitRate: Detected bit-rate for audio or video asset. This is a
4305	// read-only field. Applicable to the following creative types:
4306	// INSTREAM_AUDIO, INSTREAM_VIDEO and all VPAID.
4307	BitRate int64 `json:"bitRate,omitempty"`
4308
4309	// ChildAssetType: Rich media child asset type. This is a read-only
4310	// field. Applicable to the following creative types: all VPAID.
4311	//
4312	// Possible values:
4313	//   "CHILD_ASSET_TYPE_DATA"
4314	//   "CHILD_ASSET_TYPE_FLASH"
4315	//   "CHILD_ASSET_TYPE_IMAGE"
4316	//   "CHILD_ASSET_TYPE_VIDEO"
4317	ChildAssetType string `json:"childAssetType,omitempty"`
4318
4319	// CollapsedSize: Size of an asset when collapsed. This is a read-only
4320	// field. Applicable to the following creative types: all RICH_MEDIA and
4321	// all VPAID. Additionally, applicable to assets whose displayType is
4322	// ASSET_DISPLAY_TYPE_EXPANDING or ASSET_DISPLAY_TYPE_PEEL_DOWN.
4323	CollapsedSize *Size `json:"collapsedSize,omitempty"`
4324
4325	// CompanionCreativeIds: List of companion creatives assigned to an
4326	// in-stream video creative asset. Acceptable values include IDs of
4327	// existing flash and image creatives. Applicable to INSTREAM_VIDEO
4328	// creative type with dynamicAssetSelection set to true.
4329	CompanionCreativeIds googleapi.Int64s `json:"companionCreativeIds,omitempty"`
4330
4331	// CustomStartTimeValue: Custom start time in seconds for making the
4332	// asset visible. Applicable to the following creative types: all
4333	// RICH_MEDIA. Value must be greater than or equal to 0.
4334	CustomStartTimeValue int64 `json:"customStartTimeValue,omitempty"`
4335
4336	// DetectedFeatures: List of feature dependencies for the creative asset
4337	// that are detected by Campaign Manager. Feature dependencies are
4338	// features that a browser must be able to support in order to render
4339	// your HTML5 creative correctly. This is a read-only, auto-generated
4340	// field. Applicable to the following creative types: HTML5_BANNER.
4341	// Applicable to DISPLAY when the primary asset type is not HTML_IMAGE.
4342	//
4343	// Possible values:
4344	//   "APPLICATION_CACHE"
4345	//   "AUDIO"
4346	//   "CANVAS"
4347	//   "CANVAS_TEXT"
4348	//   "CSS_ANIMATIONS"
4349	//   "CSS_BACKGROUND_SIZE"
4350	//   "CSS_BORDER_IMAGE"
4351	//   "CSS_BORDER_RADIUS"
4352	//   "CSS_BOX_SHADOW"
4353	//   "CSS_COLUMNS"
4354	//   "CSS_FLEX_BOX"
4355	//   "CSS_FONT_FACE"
4356	//   "CSS_GENERATED_CONTENT"
4357	//   "CSS_GRADIENTS"
4358	//   "CSS_HSLA"
4359	//   "CSS_MULTIPLE_BGS"
4360	//   "CSS_OPACITY"
4361	//   "CSS_REFLECTIONS"
4362	//   "CSS_RGBA"
4363	//   "CSS_TEXT_SHADOW"
4364	//   "CSS_TRANSFORMS"
4365	//   "CSS_TRANSFORMS3D"
4366	//   "CSS_TRANSITIONS"
4367	//   "DRAG_AND_DROP"
4368	//   "GEO_LOCATION"
4369	//   "HASH_CHANGE"
4370	//   "HISTORY"
4371	//   "INDEXED_DB"
4372	//   "INLINE_SVG"
4373	//   "INPUT_ATTR_AUTOCOMPLETE"
4374	//   "INPUT_ATTR_AUTOFOCUS"
4375	//   "INPUT_ATTR_LIST"
4376	//   "INPUT_ATTR_MAX"
4377	//   "INPUT_ATTR_MIN"
4378	//   "INPUT_ATTR_MULTIPLE"
4379	//   "INPUT_ATTR_PATTERN"
4380	//   "INPUT_ATTR_PLACEHOLDER"
4381	//   "INPUT_ATTR_REQUIRED"
4382	//   "INPUT_ATTR_STEP"
4383	//   "INPUT_TYPE_COLOR"
4384	//   "INPUT_TYPE_DATE"
4385	//   "INPUT_TYPE_DATETIME"
4386	//   "INPUT_TYPE_DATETIME_LOCAL"
4387	//   "INPUT_TYPE_EMAIL"
4388	//   "INPUT_TYPE_MONTH"
4389	//   "INPUT_TYPE_NUMBER"
4390	//   "INPUT_TYPE_RANGE"
4391	//   "INPUT_TYPE_SEARCH"
4392	//   "INPUT_TYPE_TEL"
4393	//   "INPUT_TYPE_TIME"
4394	//   "INPUT_TYPE_URL"
4395	//   "INPUT_TYPE_WEEK"
4396	//   "LOCAL_STORAGE"
4397	//   "POST_MESSAGE"
4398	//   "SESSION_STORAGE"
4399	//   "SMIL"
4400	//   "SVG_CLIP_PATHS"
4401	//   "SVG_FE_IMAGE"
4402	//   "SVG_FILTERS"
4403	//   "SVG_HREF"
4404	//   "TOUCH"
4405	//   "VIDEO"
4406	//   "WEBGL"
4407	//   "WEB_SOCKETS"
4408	//   "WEB_SQL_DATABASE"
4409	//   "WEB_WORKERS"
4410	DetectedFeatures []string `json:"detectedFeatures,omitempty"`
4411
4412	// DisplayType: Type of rich media asset. This is a read-only field.
4413	// Applicable to the following creative types: all RICH_MEDIA.
4414	//
4415	// Possible values:
4416	//   "ASSET_DISPLAY_TYPE_BACKDROP"
4417	//   "ASSET_DISPLAY_TYPE_EXPANDING"
4418	//   "ASSET_DISPLAY_TYPE_FLASH_IN_FLASH"
4419	//   "ASSET_DISPLAY_TYPE_FLASH_IN_FLASH_EXPANDING"
4420	//   "ASSET_DISPLAY_TYPE_FLOATING"
4421	//   "ASSET_DISPLAY_TYPE_INPAGE"
4422	//   "ASSET_DISPLAY_TYPE_OVERLAY"
4423	//   "ASSET_DISPLAY_TYPE_PEEL_DOWN"
4424	//   "ASSET_DISPLAY_TYPE_VPAID_LINEAR"
4425	//   "ASSET_DISPLAY_TYPE_VPAID_NON_LINEAR"
4426	DisplayType string `json:"displayType,omitempty"`
4427
4428	// Duration: Duration in seconds for which an asset will be displayed.
4429	// Applicable to the following creative types: INSTREAM_AUDIO,
4430	// INSTREAM_VIDEO and VPAID_LINEAR_VIDEO. Value must be greater than or
4431	// equal to 1.
4432	Duration int64 `json:"duration,omitempty"`
4433
4434	// DurationType: Duration type for which an asset will be displayed.
4435	// Applicable to the following creative types: all RICH_MEDIA.
4436	//
4437	// Possible values:
4438	//   "ASSET_DURATION_TYPE_AUTO"
4439	//   "ASSET_DURATION_TYPE_CUSTOM"
4440	//   "ASSET_DURATION_TYPE_NONE"
4441	DurationType string `json:"durationType,omitempty"`
4442
4443	// ExpandedDimension: Detected expanded dimension for video asset. This
4444	// is a read-only field. Applicable to the following creative types:
4445	// INSTREAM_VIDEO and all VPAID.
4446	ExpandedDimension *Size `json:"expandedDimension,omitempty"`
4447
4448	// FileSize: File size associated with this creative asset. This is a
4449	// read-only field. Applicable to all but the following creative types:
4450	// all REDIRECT and TRACKING_TEXT.
4451	FileSize int64 `json:"fileSize,omitempty,string"`
4452
4453	// FlashVersion: Flash version of the asset. This is a read-only field.
4454	// Applicable to the following creative types: FLASH_INPAGE, all
4455	// RICH_MEDIA, and all VPAID. Applicable to DISPLAY when the primary
4456	// asset type is not HTML_IMAGE.
4457	FlashVersion int64 `json:"flashVersion,omitempty"`
4458
4459	// HideFlashObjects: Whether to hide Flash objects flag for an asset.
4460	// Applicable to the following creative types: all RICH_MEDIA.
4461	HideFlashObjects bool `json:"hideFlashObjects,omitempty"`
4462
4463	// HideSelectionBoxes: Whether to hide selection boxes flag for an
4464	// asset. Applicable to the following creative types: all RICH_MEDIA.
4465	HideSelectionBoxes bool `json:"hideSelectionBoxes,omitempty"`
4466
4467	// HorizontallyLocked: Whether the asset is horizontally locked. This is
4468	// a read-only field. Applicable to the following creative types: all
4469	// RICH_MEDIA.
4470	HorizontallyLocked bool `json:"horizontallyLocked,omitempty"`
4471
4472	// Id: Numeric ID of this creative asset. This is a required field and
4473	// should not be modified. Applicable to all but the following creative
4474	// types: all REDIRECT and TRACKING_TEXT.
4475	Id int64 `json:"id,omitempty,string"`
4476
4477	// IdDimensionValue: Dimension value for the ID of the asset. This is a
4478	// read-only, auto-generated field.
4479	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4480
4481	// MediaDuration: Detected duration for audio or video asset. This is a
4482	// read-only field. Applicable to the following creative types:
4483	// INSTREAM_AUDIO, INSTREAM_VIDEO and all VPAID.
4484	MediaDuration float64 `json:"mediaDuration,omitempty"`
4485
4486	// MimeType: Detected MIME type for audio or video asset. This is a
4487	// read-only field. Applicable to the following creative types:
4488	// INSTREAM_AUDIO, INSTREAM_VIDEO and all VPAID.
4489	MimeType string `json:"mimeType,omitempty"`
4490
4491	// Offset: Offset position for an asset in collapsed mode. This is a
4492	// read-only field. Applicable to the following creative types: all
4493	// RICH_MEDIA and all VPAID. Additionally, only applicable to assets
4494	// whose displayType is ASSET_DISPLAY_TYPE_EXPANDING or
4495	// ASSET_DISPLAY_TYPE_PEEL_DOWN.
4496	Offset *OffsetPosition `json:"offset,omitempty"`
4497
4498	// Orientation: Orientation of video asset. This is a read-only,
4499	// auto-generated field.
4500	//
4501	// Possible values:
4502	//   "LANDSCAPE"
4503	//   "PORTRAIT"
4504	//   "SQUARE"
4505	Orientation string `json:"orientation,omitempty"`
4506
4507	// OriginalBackup: Whether the backup asset is original or changed by
4508	// the user in Campaign Manager. Applicable to the following creative
4509	// types: all RICH_MEDIA.
4510	OriginalBackup bool `json:"originalBackup,omitempty"`
4511
4512	// Position: Offset position for an asset. Applicable to the following
4513	// creative types: all RICH_MEDIA.
4514	Position *OffsetPosition `json:"position,omitempty"`
4515
4516	// PositionLeftUnit: Offset left unit for an asset. This is a read-only
4517	// field. Applicable to the following creative types: all RICH_MEDIA.
4518	//
4519	// Possible values:
4520	//   "OFFSET_UNIT_PERCENT"
4521	//   "OFFSET_UNIT_PIXEL"
4522	//   "OFFSET_UNIT_PIXEL_FROM_CENTER"
4523	PositionLeftUnit string `json:"positionLeftUnit,omitempty"`
4524
4525	// PositionTopUnit: Offset top unit for an asset. This is a read-only
4526	// field if the asset displayType is ASSET_DISPLAY_TYPE_OVERLAY.
4527	// Applicable to the following creative types: all RICH_MEDIA.
4528	//
4529	// Possible values:
4530	//   "OFFSET_UNIT_PERCENT"
4531	//   "OFFSET_UNIT_PIXEL"
4532	//   "OFFSET_UNIT_PIXEL_FROM_CENTER"
4533	PositionTopUnit string `json:"positionTopUnit,omitempty"`
4534
4535	// ProgressiveServingUrl: Progressive URL for video asset. This is a
4536	// read-only field. Applicable to the following creative types:
4537	// INSTREAM_VIDEO and all VPAID.
4538	ProgressiveServingUrl string `json:"progressiveServingUrl,omitempty"`
4539
4540	// Pushdown: Whether the asset pushes down other content. Applicable to
4541	// the following creative types: all RICH_MEDIA. Additionally, only
4542	// applicable when the asset offsets are 0, the collapsedSize.width
4543	// matches size.width, and the collapsedSize.height is less than
4544	// size.height.
4545	Pushdown bool `json:"pushdown,omitempty"`
4546
4547	// PushdownDuration: Pushdown duration in seconds for an asset.
4548	// Applicable to the following creative types: all
4549	// RICH_MEDIA.Additionally, only applicable when the asset pushdown
4550	// field is true, the offsets are 0, the collapsedSize.width matches
4551	// size.width, and the collapsedSize.height is less than size.height.
4552	// Acceptable values are 0 to 9.99, inclusive.
4553	PushdownDuration float64 `json:"pushdownDuration,omitempty"`
4554
4555	// Role: Role of the asset in relation to creative. Applicable to all
4556	// but the following creative types: all REDIRECT and TRACKING_TEXT.
4557	// This is a required field.
4558	// PRIMARY applies to DISPLAY, FLASH_INPAGE, HTML5_BANNER, IMAGE,
4559	// DISPLAY_IMAGE_GALLERY, all RICH_MEDIA (which may contain multiple
4560	// primary assets), and all VPAID creatives.
4561	// BACKUP_IMAGE applies to FLASH_INPAGE, HTML5_BANNER, all RICH_MEDIA,
4562	// and all VPAID creatives. Applicable to DISPLAY when the primary asset
4563	// type is not HTML_IMAGE.
4564	// ADDITIONAL_IMAGE and ADDITIONAL_FLASH apply to FLASH_INPAGE
4565	// creatives.
4566	// OTHER refers to assets from sources other than Campaign Manager, such
4567	// as Studio uploaded assets, applicable to all RICH_MEDIA and all VPAID
4568	// creatives.
4569	// PARENT_VIDEO refers to videos uploaded by the user in Campaign
4570	// Manager and is applicable to INSTREAM_VIDEO and VPAID_LINEAR_VIDEO
4571	// creatives.
4572	// TRANSCODED_VIDEO refers to videos transcoded by Campaign Manager from
4573	// PARENT_VIDEO assets and is applicable to INSTREAM_VIDEO and
4574	// VPAID_LINEAR_VIDEO creatives.
4575	// ALTERNATE_VIDEO refers to the Campaign Manager representation of
4576	// child asset videos from Studio, and is applicable to
4577	// VPAID_LINEAR_VIDEO creatives. These cannot be added or removed within
4578	// Campaign Manager.
4579	// For VPAID_LINEAR_VIDEO creatives, PARENT_VIDEO, TRANSCODED_VIDEO and
4580	// ALTERNATE_VIDEO assets that are marked active serve as backup in case
4581	// the VPAID creative cannot be served. Only PARENT_VIDEO assets can be
4582	// added or removed for an INSTREAM_VIDEO or VPAID_LINEAR_VIDEO
4583	// creative.
4584	// PARENT_AUDIO refers to audios uploaded by the user in Campaign
4585	// Manager and is applicable to INSTREAM_AUDIO
4586	// creatives.
4587	// TRANSCODED_AUDIO refers to audios transcoded by Campaign Manager from
4588	// PARENT_AUDIO assets and is applicable to INSTREAM_AUDIO creatives.
4589	//
4590	// Possible values:
4591	//   "ADDITIONAL_FLASH"
4592	//   "ADDITIONAL_IMAGE"
4593	//   "ALTERNATE_VIDEO"
4594	//   "BACKUP_IMAGE"
4595	//   "OTHER"
4596	//   "PARENT_AUDIO"
4597	//   "PARENT_VIDEO"
4598	//   "PRIMARY"
4599	//   "TRANSCODED_AUDIO"
4600	//   "TRANSCODED_VIDEO"
4601	Role string `json:"role,omitempty"`
4602
4603	// Size: Size associated with this creative asset. This is a required
4604	// field when applicable; however for IMAGE and FLASH_INPAGE, creatives
4605	// if left blank, this field will be automatically set using the actual
4606	// size of the associated image asset. Applicable to the following
4607	// creative types: DISPLAY_IMAGE_GALLERY, FLASH_INPAGE, HTML5_BANNER,
4608	// IMAGE, and all RICH_MEDIA. Applicable to DISPLAY when the primary
4609	// asset type is not HTML_IMAGE.
4610	Size *Size `json:"size,omitempty"`
4611
4612	// SslCompliant: Whether the asset is SSL-compliant. This is a read-only
4613	// field. Applicable to all but the following creative types: all
4614	// REDIRECT and TRACKING_TEXT.
4615	SslCompliant bool `json:"sslCompliant,omitempty"`
4616
4617	// StartTimeType: Initial wait time type before making the asset
4618	// visible. Applicable to the following creative types: all RICH_MEDIA.
4619	//
4620	// Possible values:
4621	//   "ASSET_START_TIME_TYPE_CUSTOM"
4622	//   "ASSET_START_TIME_TYPE_NONE"
4623	StartTimeType string `json:"startTimeType,omitempty"`
4624
4625	// StreamingServingUrl: Streaming URL for video asset. This is a
4626	// read-only field. Applicable to the following creative types:
4627	// INSTREAM_VIDEO and all VPAID.
4628	StreamingServingUrl string `json:"streamingServingUrl,omitempty"`
4629
4630	// Transparency: Whether the asset is transparent. Applicable to the
4631	// following creative types: all RICH_MEDIA. Additionally, only
4632	// applicable to HTML5 assets.
4633	Transparency bool `json:"transparency,omitempty"`
4634
4635	// VerticallyLocked: Whether the asset is vertically locked. This is a
4636	// read-only field. Applicable to the following creative types: all
4637	// RICH_MEDIA.
4638	VerticallyLocked bool `json:"verticallyLocked,omitempty"`
4639
4640	// WindowMode: Window mode options for flash assets. Applicable to the
4641	// following creative types: FLASH_INPAGE, RICH_MEDIA_DISPLAY_EXPANDING,
4642	// RICH_MEDIA_IM_EXPAND, RICH_MEDIA_DISPLAY_BANNER, and
4643	// RICH_MEDIA_INPAGE_FLOATING.
4644	//
4645	// Possible values:
4646	//   "OPAQUE"
4647	//   "TRANSPARENT"
4648	//   "WINDOW"
4649	WindowMode string `json:"windowMode,omitempty"`
4650
4651	// ZIndex: zIndex value of an asset. Applicable to the following
4652	// creative types: all RICH_MEDIA.Additionally, only applicable to
4653	// assets whose displayType is NOT one of the following types:
4654	// ASSET_DISPLAY_TYPE_INPAGE or ASSET_DISPLAY_TYPE_OVERLAY. Acceptable
4655	// values are -999999999 to 999999999, inclusive.
4656	ZIndex int64 `json:"zIndex,omitempty"`
4657
4658	// ZipFilename: File name of zip file. This is a read-only field.
4659	// Applicable to the following creative types: HTML5_BANNER.
4660	ZipFilename string `json:"zipFilename,omitempty"`
4661
4662	// ZipFilesize: Size of zip file. This is a read-only field. Applicable
4663	// to the following creative types: HTML5_BANNER.
4664	ZipFilesize string `json:"zipFilesize,omitempty"`
4665
4666	// ForceSendFields is a list of field names (e.g. "ActionScript3") to
4667	// unconditionally include in API requests. By default, fields with
4668	// empty values are omitted from API requests. However, any non-pointer,
4669	// non-interface field appearing in ForceSendFields will be sent to the
4670	// server regardless of whether the field is empty or not. This may be
4671	// used to include empty fields in Patch requests.
4672	ForceSendFields []string `json:"-"`
4673
4674	// NullFields is a list of field names (e.g. "ActionScript3") to include
4675	// in API requests with the JSON null value. By default, fields with
4676	// empty values are omitted from API requests. However, any field with
4677	// an empty value appearing in NullFields will be sent to the server as
4678	// null. It is an error if a field in this list has a non-empty value.
4679	// This may be used to include null fields in Patch requests.
4680	NullFields []string `json:"-"`
4681}
4682
4683func (s *CreativeAsset) MarshalJSON() ([]byte, error) {
4684	type NoMethod CreativeAsset
4685	raw := NoMethod(*s)
4686	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4687}
4688
4689func (s *CreativeAsset) UnmarshalJSON(data []byte) error {
4690	type NoMethod CreativeAsset
4691	var s1 struct {
4692		MediaDuration    gensupport.JSONFloat64 `json:"mediaDuration"`
4693		PushdownDuration gensupport.JSONFloat64 `json:"pushdownDuration"`
4694		*NoMethod
4695	}
4696	s1.NoMethod = (*NoMethod)(s)
4697	if err := json.Unmarshal(data, &s1); err != nil {
4698		return err
4699	}
4700	s.MediaDuration = float64(s1.MediaDuration)
4701	s.PushdownDuration = float64(s1.PushdownDuration)
4702	return nil
4703}
4704
4705// CreativeAssetId: Creative Asset ID.
4706type CreativeAssetId struct {
4707	// Name: Name of the creative asset. This is a required field while
4708	// inserting an asset. After insertion, this assetIdentifier is used to
4709	// identify the uploaded asset. Characters in the name must be
4710	// alphanumeric or one of the following: ".-_ ". Spaces are allowed.
4711	Name string `json:"name,omitempty"`
4712
4713	// Type: Type of asset to upload. This is a required field. FLASH and
4714	// IMAGE are no longer supported for new uploads. All image assets
4715	// should use HTML_IMAGE.
4716	//
4717	// Possible values:
4718	//   "AUDIO"
4719	//   "FLASH"
4720	//   "HTML"
4721	//   "HTML_IMAGE"
4722	//   "IMAGE"
4723	//   "VIDEO"
4724	Type string `json:"type,omitempty"`
4725
4726	// ForceSendFields is a list of field names (e.g. "Name") to
4727	// unconditionally include in API requests. By default, fields with
4728	// empty values are omitted from API requests. However, any non-pointer,
4729	// non-interface field appearing in ForceSendFields will be sent to the
4730	// server regardless of whether the field is empty or not. This may be
4731	// used to include empty fields in Patch requests.
4732	ForceSendFields []string `json:"-"`
4733
4734	// NullFields is a list of field names (e.g. "Name") to include in API
4735	// requests with the JSON null value. By default, fields with empty
4736	// values are omitted from API requests. However, any field with an
4737	// empty value appearing in NullFields will be sent to the server as
4738	// null. It is an error if a field in this list has a non-empty value.
4739	// This may be used to include null fields in Patch requests.
4740	NullFields []string `json:"-"`
4741}
4742
4743func (s *CreativeAssetId) MarshalJSON() ([]byte, error) {
4744	type NoMethod CreativeAssetId
4745	raw := NoMethod(*s)
4746	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4747}
4748
4749// CreativeAssetMetadata: CreativeAssets contains properties of a
4750// creative asset file which will be uploaded or has already been
4751// uploaded. Refer to the creative sample code for how to upload assets
4752// and insert a creative.
4753type CreativeAssetMetadata struct {
4754	// AssetIdentifier: ID of the creative asset. This is a required field.
4755	AssetIdentifier *CreativeAssetId `json:"assetIdentifier,omitempty"`
4756
4757	// ClickTags: List of detected click tags for assets. This is a
4758	// read-only auto-generated field.
4759	ClickTags []*ClickTag `json:"clickTags,omitempty"`
4760
4761	// DetectedFeatures: List of feature dependencies for the creative asset
4762	// that are detected by Campaign Manager. Feature dependencies are
4763	// features that a browser must be able to support in order to render
4764	// your HTML5 creative correctly. This is a read-only, auto-generated
4765	// field.
4766	//
4767	// Possible values:
4768	//   "APPLICATION_CACHE"
4769	//   "AUDIO"
4770	//   "CANVAS"
4771	//   "CANVAS_TEXT"
4772	//   "CSS_ANIMATIONS"
4773	//   "CSS_BACKGROUND_SIZE"
4774	//   "CSS_BORDER_IMAGE"
4775	//   "CSS_BORDER_RADIUS"
4776	//   "CSS_BOX_SHADOW"
4777	//   "CSS_COLUMNS"
4778	//   "CSS_FLEX_BOX"
4779	//   "CSS_FONT_FACE"
4780	//   "CSS_GENERATED_CONTENT"
4781	//   "CSS_GRADIENTS"
4782	//   "CSS_HSLA"
4783	//   "CSS_MULTIPLE_BGS"
4784	//   "CSS_OPACITY"
4785	//   "CSS_REFLECTIONS"
4786	//   "CSS_RGBA"
4787	//   "CSS_TEXT_SHADOW"
4788	//   "CSS_TRANSFORMS"
4789	//   "CSS_TRANSFORMS3D"
4790	//   "CSS_TRANSITIONS"
4791	//   "DRAG_AND_DROP"
4792	//   "GEO_LOCATION"
4793	//   "HASH_CHANGE"
4794	//   "HISTORY"
4795	//   "INDEXED_DB"
4796	//   "INLINE_SVG"
4797	//   "INPUT_ATTR_AUTOCOMPLETE"
4798	//   "INPUT_ATTR_AUTOFOCUS"
4799	//   "INPUT_ATTR_LIST"
4800	//   "INPUT_ATTR_MAX"
4801	//   "INPUT_ATTR_MIN"
4802	//   "INPUT_ATTR_MULTIPLE"
4803	//   "INPUT_ATTR_PATTERN"
4804	//   "INPUT_ATTR_PLACEHOLDER"
4805	//   "INPUT_ATTR_REQUIRED"
4806	//   "INPUT_ATTR_STEP"
4807	//   "INPUT_TYPE_COLOR"
4808	//   "INPUT_TYPE_DATE"
4809	//   "INPUT_TYPE_DATETIME"
4810	//   "INPUT_TYPE_DATETIME_LOCAL"
4811	//   "INPUT_TYPE_EMAIL"
4812	//   "INPUT_TYPE_MONTH"
4813	//   "INPUT_TYPE_NUMBER"
4814	//   "INPUT_TYPE_RANGE"
4815	//   "INPUT_TYPE_SEARCH"
4816	//   "INPUT_TYPE_TEL"
4817	//   "INPUT_TYPE_TIME"
4818	//   "INPUT_TYPE_URL"
4819	//   "INPUT_TYPE_WEEK"
4820	//   "LOCAL_STORAGE"
4821	//   "POST_MESSAGE"
4822	//   "SESSION_STORAGE"
4823	//   "SMIL"
4824	//   "SVG_CLIP_PATHS"
4825	//   "SVG_FE_IMAGE"
4826	//   "SVG_FILTERS"
4827	//   "SVG_HREF"
4828	//   "TOUCH"
4829	//   "VIDEO"
4830	//   "WEBGL"
4831	//   "WEB_SOCKETS"
4832	//   "WEB_SQL_DATABASE"
4833	//   "WEB_WORKERS"
4834	DetectedFeatures []string `json:"detectedFeatures,omitempty"`
4835
4836	// Id: Numeric ID of the asset. This is a read-only, auto-generated
4837	// field.
4838	Id int64 `json:"id,omitempty,string"`
4839
4840	// IdDimensionValue: Dimension value for the numeric ID of the asset.
4841	// This is a read-only, auto-generated field.
4842	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4843
4844	// Kind: Identifies what kind of resource this is. Value: the fixed
4845	// string "dfareporting#creativeAssetMetadata".
4846	Kind string `json:"kind,omitempty"`
4847
4848	// WarnedValidationRules: Rules validated during code generation that
4849	// generated a warning. This is a read-only, auto-generated
4850	// field.
4851	//
4852	// Possible values are:
4853	// - "ADMOB_REFERENCED"
4854	// - "ASSET_FORMAT_UNSUPPORTED_DCM"
4855	// - "ASSET_INVALID"
4856	// - "CLICK_TAG_HARD_CODED"
4857	// - "CLICK_TAG_INVALID"
4858	// - "CLICK_TAG_IN_GWD"
4859	// - "CLICK_TAG_MISSING"
4860	// - "CLICK_TAG_MORE_THAN_ONE"
4861	// - "CLICK_TAG_NON_TOP_LEVEL"
4862	// - "COMPONENT_UNSUPPORTED_DCM"
4863	// - "ENABLER_UNSUPPORTED_METHOD_DCM"
4864	// - "EXTERNAL_FILE_REFERENCED"
4865	// - "FILE_DETAIL_EMPTY"
4866	// - "FILE_TYPE_INVALID"
4867	// - "GWD_PROPERTIES_INVALID"
4868	// - "HTML5_FEATURE_UNSUPPORTED"
4869	// - "LINKED_FILE_NOT_FOUND"
4870	// - "MAX_FLASH_VERSION_11"
4871	// - "MRAID_REFERENCED"
4872	// - "NOT_SSL_COMPLIANT"
4873	// - "ORPHANED_ASSET"
4874	// - "PRIMARY_HTML_MISSING"
4875	// - "SVG_INVALID"
4876	// - "ZIP_INVALID"
4877	//
4878	// Possible values:
4879	//   "ADMOB_REFERENCED"
4880	//   "ASSET_FORMAT_UNSUPPORTED_DCM"
4881	//   "ASSET_INVALID"
4882	//   "CLICK_TAG_HARD_CODED"
4883	//   "CLICK_TAG_INVALID"
4884	//   "CLICK_TAG_IN_GWD"
4885	//   "CLICK_TAG_MISSING"
4886	//   "CLICK_TAG_MORE_THAN_ONE"
4887	//   "CLICK_TAG_NON_TOP_LEVEL"
4888	//   "COMPONENT_UNSUPPORTED_DCM"
4889	//   "ENABLER_UNSUPPORTED_METHOD_DCM"
4890	//   "EXTERNAL_FILE_REFERENCED"
4891	//   "FILE_DETAIL_EMPTY"
4892	//   "FILE_TYPE_INVALID"
4893	//   "GWD_PROPERTIES_INVALID"
4894	//   "HTML5_FEATURE_UNSUPPORTED"
4895	//   "LINKED_FILE_NOT_FOUND"
4896	//   "MAX_FLASH_VERSION_11"
4897	//   "MRAID_REFERENCED"
4898	//   "NOT_SSL_COMPLIANT"
4899	//   "ORPHANED_ASSET"
4900	//   "PRIMARY_HTML_MISSING"
4901	//   "SVG_INVALID"
4902	//   "ZIP_INVALID"
4903	WarnedValidationRules []string `json:"warnedValidationRules,omitempty"`
4904
4905	// ServerResponse contains the HTTP response code and headers from the
4906	// server.
4907	googleapi.ServerResponse `json:"-"`
4908
4909	// ForceSendFields is a list of field names (e.g. "AssetIdentifier") to
4910	// unconditionally include in API requests. By default, fields with
4911	// empty values are omitted from API requests. However, any non-pointer,
4912	// non-interface field appearing in ForceSendFields will be sent to the
4913	// server regardless of whether the field is empty or not. This may be
4914	// used to include empty fields in Patch requests.
4915	ForceSendFields []string `json:"-"`
4916
4917	// NullFields is a list of field names (e.g. "AssetIdentifier") to
4918	// include in API requests with the JSON null value. By default, fields
4919	// with empty values are omitted from API requests. However, any field
4920	// with an empty value appearing in NullFields will be sent to the
4921	// server as null. It is an error if a field in this list has a
4922	// non-empty value. This may be used to include null fields in Patch
4923	// requests.
4924	NullFields []string `json:"-"`
4925}
4926
4927func (s *CreativeAssetMetadata) MarshalJSON() ([]byte, error) {
4928	type NoMethod CreativeAssetMetadata
4929	raw := NoMethod(*s)
4930	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4931}
4932
4933// CreativeAssetSelection: Encapsulates the list of rules for asset
4934// selection and a default asset in case none of the rules match.
4935// Applicable to INSTREAM_VIDEO creatives.
4936type CreativeAssetSelection struct {
4937	// DefaultAssetId: A creativeAssets[].id. This should refer to one of
4938	// the parent assets in this creative, and will be served if none of the
4939	// rules match. This is a required field.
4940	DefaultAssetId int64 `json:"defaultAssetId,omitempty,string"`
4941
4942	// Rules: Rules determine which asset will be served to a viewer. Rules
4943	// will be evaluated in the order in which they are stored in this list.
4944	// This list must contain at least one rule. Applicable to
4945	// INSTREAM_VIDEO creatives.
4946	Rules []*Rule `json:"rules,omitempty"`
4947
4948	// ForceSendFields is a list of field names (e.g. "DefaultAssetId") to
4949	// unconditionally include in API requests. By default, fields with
4950	// empty values are omitted from API requests. However, any non-pointer,
4951	// non-interface field appearing in ForceSendFields will be sent to the
4952	// server regardless of whether the field is empty or not. This may be
4953	// used to include empty fields in Patch requests.
4954	ForceSendFields []string `json:"-"`
4955
4956	// NullFields is a list of field names (e.g. "DefaultAssetId") to
4957	// include in API requests with the JSON null value. By default, fields
4958	// with empty values are omitted from API requests. However, any field
4959	// with an empty value appearing in NullFields will be sent to the
4960	// server as null. It is an error if a field in this list has a
4961	// non-empty value. This may be used to include null fields in Patch
4962	// requests.
4963	NullFields []string `json:"-"`
4964}
4965
4966func (s *CreativeAssetSelection) MarshalJSON() ([]byte, error) {
4967	type NoMethod CreativeAssetSelection
4968	raw := NoMethod(*s)
4969	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4970}
4971
4972// CreativeAssignment: Creative Assignment.
4973type CreativeAssignment struct {
4974	// Active: Whether this creative assignment is active. When true, the
4975	// creative will be included in the ad's rotation.
4976	Active bool `json:"active,omitempty"`
4977
4978	// ApplyEventTags: Whether applicable event tags should fire when this
4979	// creative assignment is rendered. If this value is unset when the ad
4980	// is inserted or updated, it will default to true for all creative
4981	// types EXCEPT for INTERNAL_REDIRECT, INTERSTITIAL_INTERNAL_REDIRECT,
4982	// and INSTREAM_VIDEO.
4983	ApplyEventTags bool `json:"applyEventTags,omitempty"`
4984
4985	// ClickThroughUrl: Click-through URL of the creative assignment.
4986	ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
4987
4988	// CompanionCreativeOverrides: Companion creative overrides for this
4989	// creative assignment. Applicable to video ads.
4990	CompanionCreativeOverrides []*CompanionClickThroughOverride `json:"companionCreativeOverrides,omitempty"`
4991
4992	// CreativeGroupAssignments: Creative group assignments for this
4993	// creative assignment. Only one assignment per creative group number is
4994	// allowed for a maximum of two assignments.
4995	CreativeGroupAssignments []*CreativeGroupAssignment `json:"creativeGroupAssignments,omitempty"`
4996
4997	// CreativeId: ID of the creative to be assigned. This is a required
4998	// field.
4999	CreativeId int64 `json:"creativeId,omitempty,string"`
5000
5001	// CreativeIdDimensionValue: Dimension value for the ID of the creative.
5002	// This is a read-only, auto-generated field.
5003	CreativeIdDimensionValue *DimensionValue `json:"creativeIdDimensionValue,omitempty"`
5004
5005	// EndTime: Date and time that the assigned creative should stop
5006	// serving. Must be later than the start time.
5007	EndTime string `json:"endTime,omitempty"`
5008
5009	// RichMediaExitOverrides: Rich media exit overrides for this creative
5010	// assignment.
5011	// Applicable when the creative type is any of the following:
5012	// - DISPLAY
5013	// - RICH_MEDIA_INPAGE
5014	// - RICH_MEDIA_INPAGE_FLOATING
5015	// - RICH_MEDIA_IM_EXPAND
5016	// - RICH_MEDIA_EXPANDING
5017	// - RICH_MEDIA_INTERSTITIAL_FLOAT
5018	// - RICH_MEDIA_MOBILE_IN_APP
5019	// - RICH_MEDIA_MULTI_FLOATING
5020	// - RICH_MEDIA_PEEL_DOWN
5021	// - VPAID_LINEAR
5022	// - VPAID_NON_LINEAR
5023	RichMediaExitOverrides []*RichMediaExitOverride `json:"richMediaExitOverrides,omitempty"`
5024
5025	// Sequence: Sequence number of the creative assignment, applicable when
5026	// the rotation type is CREATIVE_ROTATION_TYPE_SEQUENTIAL. Acceptable
5027	// values are 1 to 65535, inclusive.
5028	Sequence int64 `json:"sequence,omitempty"`
5029
5030	// SslCompliant: Whether the creative to be assigned is SSL-compliant.
5031	// This is a read-only field that is auto-generated when the ad is
5032	// inserted or updated.
5033	SslCompliant bool `json:"sslCompliant,omitempty"`
5034
5035	// StartTime: Date and time that the assigned creative should start
5036	// serving.
5037	StartTime string `json:"startTime,omitempty"`
5038
5039	// Weight: Weight of the creative assignment, applicable when the
5040	// rotation type is CREATIVE_ROTATION_TYPE_RANDOM. Value must be greater
5041	// than or equal to 1.
5042	Weight int64 `json:"weight,omitempty"`
5043
5044	// ForceSendFields is a list of field names (e.g. "Active") to
5045	// unconditionally include in API requests. By default, fields with
5046	// empty values are omitted from API requests. However, any non-pointer,
5047	// non-interface field appearing in ForceSendFields will be sent to the
5048	// server regardless of whether the field is empty or not. This may be
5049	// used to include empty fields in Patch requests.
5050	ForceSendFields []string `json:"-"`
5051
5052	// NullFields is a list of field names (e.g. "Active") to include in API
5053	// requests with the JSON null value. By default, fields with empty
5054	// values are omitted from API requests. However, any field with an
5055	// empty value appearing in NullFields will be sent to the server as
5056	// null. It is an error if a field in this list has a non-empty value.
5057	// This may be used to include null fields in Patch requests.
5058	NullFields []string `json:"-"`
5059}
5060
5061func (s *CreativeAssignment) MarshalJSON() ([]byte, error) {
5062	type NoMethod CreativeAssignment
5063	raw := NoMethod(*s)
5064	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5065}
5066
5067// CreativeClickThroughUrl: Click-through URL
5068type CreativeClickThroughUrl struct {
5069	// ComputedClickThroughUrl: Read-only convenience field representing the
5070	// actual URL that will be used for this click-through. The URL is
5071	// computed as follows:
5072	// - If landingPageId is specified then that landing page's URL is
5073	// assigned to this field.
5074	// - Otherwise, the customClickThroughUrl is assigned to this field.
5075	ComputedClickThroughUrl string `json:"computedClickThroughUrl,omitempty"`
5076
5077	// CustomClickThroughUrl: Custom click-through URL. Applicable if the
5078	// landingPageId field is left unset.
5079	CustomClickThroughUrl string `json:"customClickThroughUrl,omitempty"`
5080
5081	// LandingPageId: ID of the landing page for the click-through URL.
5082	LandingPageId int64 `json:"landingPageId,omitempty,string"`
5083
5084	// ForceSendFields is a list of field names (e.g.
5085	// "ComputedClickThroughUrl") to unconditionally include in API
5086	// requests. By default, fields with empty values are omitted from API
5087	// requests. However, any non-pointer, non-interface field appearing in
5088	// ForceSendFields will be sent to the server regardless of whether the
5089	// field is empty or not. This may be used to include empty fields in
5090	// Patch requests.
5091	ForceSendFields []string `json:"-"`
5092
5093	// NullFields is a list of field names (e.g. "ComputedClickThroughUrl")
5094	// to include in API requests with the JSON null value. By default,
5095	// fields with empty values are omitted from API requests. However, any
5096	// field with an empty value appearing in NullFields will be sent to the
5097	// server as null. It is an error if a field in this list has a
5098	// non-empty value. This may be used to include null fields in Patch
5099	// requests.
5100	NullFields []string `json:"-"`
5101}
5102
5103func (s *CreativeClickThroughUrl) MarshalJSON() ([]byte, error) {
5104	type NoMethod CreativeClickThroughUrl
5105	raw := NoMethod(*s)
5106	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5107}
5108
5109// CreativeCustomEvent: Creative Custom Event.
5110type CreativeCustomEvent struct {
5111	// AdvertiserCustomEventId: Unique ID of this event used by Reporting
5112	// and Data Transfer. This is a read-only field.
5113	AdvertiserCustomEventId int64 `json:"advertiserCustomEventId,omitempty,string"`
5114
5115	// AdvertiserCustomEventName: User-entered name for the event.
5116	AdvertiserCustomEventName string `json:"advertiserCustomEventName,omitempty"`
5117
5118	// AdvertiserCustomEventType: Type of the event. This is a read-only
5119	// field.
5120	//
5121	// Possible values:
5122	//   "ADVERTISER_EVENT_COUNTER"
5123	//   "ADVERTISER_EVENT_EXIT"
5124	//   "ADVERTISER_EVENT_TIMER"
5125	AdvertiserCustomEventType string `json:"advertiserCustomEventType,omitempty"`
5126
5127	// ArtworkLabel: Artwork label column, used to link events in Campaign
5128	// Manager back to events in Studio. This is a required field and should
5129	// not be modified after insertion.
5130	ArtworkLabel string `json:"artworkLabel,omitempty"`
5131
5132	// ArtworkType: Artwork type used by the creative.This is a read-only
5133	// field.
5134	//
5135	// Possible values:
5136	//   "ARTWORK_TYPE_FLASH"
5137	//   "ARTWORK_TYPE_HTML5"
5138	//   "ARTWORK_TYPE_IMAGE"
5139	//   "ARTWORK_TYPE_MIXED"
5140	ArtworkType string `json:"artworkType,omitempty"`
5141
5142	// ExitClickThroughUrl: Exit click-through URL for the event. This field
5143	// is used only for exit events.
5144	ExitClickThroughUrl *CreativeClickThroughUrl `json:"exitClickThroughUrl,omitempty"`
5145
5146	// Id: ID of this event. This is a required field and should not be
5147	// modified after insertion.
5148	Id int64 `json:"id,omitempty,string"`
5149
5150	// PopupWindowProperties: Properties for rich media popup windows. This
5151	// field is used only for exit events.
5152	PopupWindowProperties *PopupWindowProperties `json:"popupWindowProperties,omitempty"`
5153
5154	// TargetType: Target type used by the event.
5155	//
5156	// Possible values:
5157	//   "TARGET_BLANK"
5158	//   "TARGET_PARENT"
5159	//   "TARGET_POPUP"
5160	//   "TARGET_SELF"
5161	//   "TARGET_TOP"
5162	TargetType string `json:"targetType,omitempty"`
5163
5164	// VideoReportingId: Video reporting ID, used to differentiate multiple
5165	// videos in a single creative. This is a read-only field.
5166	VideoReportingId string `json:"videoReportingId,omitempty"`
5167
5168	// ForceSendFields is a list of field names (e.g.
5169	// "AdvertiserCustomEventId") to unconditionally include in API
5170	// requests. By default, fields with empty values are omitted from API
5171	// requests. However, any non-pointer, non-interface field appearing in
5172	// ForceSendFields will be sent to the server regardless of whether the
5173	// field is empty or not. This may be used to include empty fields in
5174	// Patch requests.
5175	ForceSendFields []string `json:"-"`
5176
5177	// NullFields is a list of field names (e.g. "AdvertiserCustomEventId")
5178	// to include in API requests with the JSON null value. By default,
5179	// fields with empty values are omitted from API requests. However, any
5180	// field with an empty value appearing in NullFields will be sent to the
5181	// server as null. It is an error if a field in this list has a
5182	// non-empty value. This may be used to include null fields in Patch
5183	// requests.
5184	NullFields []string `json:"-"`
5185}
5186
5187func (s *CreativeCustomEvent) MarshalJSON() ([]byte, error) {
5188	type NoMethod CreativeCustomEvent
5189	raw := NoMethod(*s)
5190	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5191}
5192
5193// CreativeField: Contains properties of a creative field.
5194type CreativeField struct {
5195	// AccountId: Account ID of this creative field. This is a read-only
5196	// field that can be left blank.
5197	AccountId int64 `json:"accountId,omitempty,string"`
5198
5199	// AdvertiserId: Advertiser ID of this creative field. This is a
5200	// required field on insertion.
5201	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
5202
5203	// AdvertiserIdDimensionValue: Dimension value for the ID of the
5204	// advertiser. This is a read-only, auto-generated field.
5205	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
5206
5207	// Id: ID of this creative field. This is a read-only, auto-generated
5208	// field.
5209	Id int64 `json:"id,omitempty,string"`
5210
5211	// Kind: Identifies what kind of resource this is. Value: the fixed
5212	// string "dfareporting#creativeField".
5213	Kind string `json:"kind,omitempty"`
5214
5215	// Name: Name of this creative field. This is a required field and must
5216	// be less than 256 characters long and unique among creative fields of
5217	// the same advertiser.
5218	Name string `json:"name,omitempty"`
5219
5220	// SubaccountId: Subaccount ID of this creative field. This is a
5221	// read-only field that can be left blank.
5222	SubaccountId int64 `json:"subaccountId,omitempty,string"`
5223
5224	// ServerResponse contains the HTTP response code and headers from the
5225	// server.
5226	googleapi.ServerResponse `json:"-"`
5227
5228	// ForceSendFields is a list of field names (e.g. "AccountId") to
5229	// unconditionally include in API requests. By default, fields with
5230	// empty values are omitted from API requests. However, any non-pointer,
5231	// non-interface field appearing in ForceSendFields will be sent to the
5232	// server regardless of whether the field is empty or not. This may be
5233	// used to include empty fields in Patch requests.
5234	ForceSendFields []string `json:"-"`
5235
5236	// NullFields is a list of field names (e.g. "AccountId") to include in
5237	// API requests with the JSON null value. By default, fields with empty
5238	// values are omitted from API requests. However, any field with an
5239	// empty value appearing in NullFields will be sent to the server as
5240	// null. It is an error if a field in this list has a non-empty value.
5241	// This may be used to include null fields in Patch requests.
5242	NullFields []string `json:"-"`
5243}
5244
5245func (s *CreativeField) MarshalJSON() ([]byte, error) {
5246	type NoMethod CreativeField
5247	raw := NoMethod(*s)
5248	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5249}
5250
5251// CreativeFieldAssignment: Creative Field Assignment.
5252type CreativeFieldAssignment struct {
5253	// CreativeFieldId: ID of the creative field.
5254	CreativeFieldId int64 `json:"creativeFieldId,omitempty,string"`
5255
5256	// CreativeFieldValueId: ID of the creative field value.
5257	CreativeFieldValueId int64 `json:"creativeFieldValueId,omitempty,string"`
5258
5259	// ForceSendFields is a list of field names (e.g. "CreativeFieldId") to
5260	// unconditionally include in API requests. By default, fields with
5261	// empty values are omitted from API requests. However, any non-pointer,
5262	// non-interface field appearing in ForceSendFields will be sent to the
5263	// server regardless of whether the field is empty or not. This may be
5264	// used to include empty fields in Patch requests.
5265	ForceSendFields []string `json:"-"`
5266
5267	// NullFields is a list of field names (e.g. "CreativeFieldId") to
5268	// include in API requests with the JSON null value. By default, fields
5269	// with empty values are omitted from API requests. However, any field
5270	// with an empty value appearing in NullFields will be sent to the
5271	// server as null. It is an error if a field in this list has a
5272	// non-empty value. This may be used to include null fields in Patch
5273	// requests.
5274	NullFields []string `json:"-"`
5275}
5276
5277func (s *CreativeFieldAssignment) MarshalJSON() ([]byte, error) {
5278	type NoMethod CreativeFieldAssignment
5279	raw := NoMethod(*s)
5280	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5281}
5282
5283// CreativeFieldValue: Contains properties of a creative field value.
5284type CreativeFieldValue struct {
5285	// Id: ID of this creative field value. This is a read-only,
5286	// auto-generated field.
5287	Id int64 `json:"id,omitempty,string"`
5288
5289	// Kind: Identifies what kind of resource this is. Value: the fixed
5290	// string "dfareporting#creativeFieldValue".
5291	Kind string `json:"kind,omitempty"`
5292
5293	// Value: Value of this creative field value. It needs to be less than
5294	// 256 characters in length and unique per creative field.
5295	Value string `json:"value,omitempty"`
5296
5297	// ServerResponse contains the HTTP response code and headers from the
5298	// server.
5299	googleapi.ServerResponse `json:"-"`
5300
5301	// ForceSendFields is a list of field names (e.g. "Id") to
5302	// unconditionally include in API requests. By default, fields with
5303	// empty values are omitted from API requests. However, any non-pointer,
5304	// non-interface field appearing in ForceSendFields will be sent to the
5305	// server regardless of whether the field is empty or not. This may be
5306	// used to include empty fields in Patch requests.
5307	ForceSendFields []string `json:"-"`
5308
5309	// NullFields is a list of field names (e.g. "Id") to include in API
5310	// requests with the JSON null value. By default, fields with empty
5311	// values are omitted from API requests. However, any field with an
5312	// empty value appearing in NullFields will be sent to the server as
5313	// null. It is an error if a field in this list has a non-empty value.
5314	// This may be used to include null fields in Patch requests.
5315	NullFields []string `json:"-"`
5316}
5317
5318func (s *CreativeFieldValue) MarshalJSON() ([]byte, error) {
5319	type NoMethod CreativeFieldValue
5320	raw := NoMethod(*s)
5321	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5322}
5323
5324// CreativeFieldValuesListResponse: Creative Field Value List Response
5325type CreativeFieldValuesListResponse struct {
5326	// CreativeFieldValues: Creative field value collection.
5327	CreativeFieldValues []*CreativeFieldValue `json:"creativeFieldValues,omitempty"`
5328
5329	// Kind: Identifies what kind of resource this is. Value: the fixed
5330	// string "dfareporting#creativeFieldValuesListResponse".
5331	Kind string `json:"kind,omitempty"`
5332
5333	// NextPageToken: Pagination token to be used for the next list
5334	// operation.
5335	NextPageToken string `json:"nextPageToken,omitempty"`
5336
5337	// ServerResponse contains the HTTP response code and headers from the
5338	// server.
5339	googleapi.ServerResponse `json:"-"`
5340
5341	// ForceSendFields is a list of field names (e.g. "CreativeFieldValues")
5342	// to unconditionally include in API requests. By default, fields with
5343	// empty values are omitted from API requests. However, any non-pointer,
5344	// non-interface field appearing in ForceSendFields will be sent to the
5345	// server regardless of whether the field is empty or not. This may be
5346	// used to include empty fields in Patch requests.
5347	ForceSendFields []string `json:"-"`
5348
5349	// NullFields is a list of field names (e.g. "CreativeFieldValues") to
5350	// include in API requests with the JSON null value. By default, fields
5351	// with empty values are omitted from API requests. However, any field
5352	// with an empty value appearing in NullFields will be sent to the
5353	// server as null. It is an error if a field in this list has a
5354	// non-empty value. This may be used to include null fields in Patch
5355	// requests.
5356	NullFields []string `json:"-"`
5357}
5358
5359func (s *CreativeFieldValuesListResponse) MarshalJSON() ([]byte, error) {
5360	type NoMethod CreativeFieldValuesListResponse
5361	raw := NoMethod(*s)
5362	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5363}
5364
5365// CreativeFieldsListResponse: Creative Field List Response
5366type CreativeFieldsListResponse struct {
5367	// CreativeFields: Creative field collection.
5368	CreativeFields []*CreativeField `json:"creativeFields,omitempty"`
5369
5370	// Kind: Identifies what kind of resource this is. Value: the fixed
5371	// string "dfareporting#creativeFieldsListResponse".
5372	Kind string `json:"kind,omitempty"`
5373
5374	// NextPageToken: Pagination token to be used for the next list
5375	// operation.
5376	NextPageToken string `json:"nextPageToken,omitempty"`
5377
5378	// ServerResponse contains the HTTP response code and headers from the
5379	// server.
5380	googleapi.ServerResponse `json:"-"`
5381
5382	// ForceSendFields is a list of field names (e.g. "CreativeFields") to
5383	// unconditionally include in API requests. By default, fields with
5384	// empty values are omitted from API requests. However, any non-pointer,
5385	// non-interface field appearing in ForceSendFields will be sent to the
5386	// server regardless of whether the field is empty or not. This may be
5387	// used to include empty fields in Patch requests.
5388	ForceSendFields []string `json:"-"`
5389
5390	// NullFields is a list of field names (e.g. "CreativeFields") to
5391	// include in API requests with the JSON null value. By default, fields
5392	// with empty values are omitted from API requests. However, any field
5393	// with an empty value appearing in NullFields will be sent to the
5394	// server as null. It is an error if a field in this list has a
5395	// non-empty value. This may be used to include null fields in Patch
5396	// requests.
5397	NullFields []string `json:"-"`
5398}
5399
5400func (s *CreativeFieldsListResponse) MarshalJSON() ([]byte, error) {
5401	type NoMethod CreativeFieldsListResponse
5402	raw := NoMethod(*s)
5403	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5404}
5405
5406// CreativeGroup: Contains properties of a creative group.
5407type CreativeGroup struct {
5408	// AccountId: Account ID of this creative group. This is a read-only
5409	// field that can be left blank.
5410	AccountId int64 `json:"accountId,omitempty,string"`
5411
5412	// AdvertiserId: Advertiser ID of this creative group. This is a
5413	// required field on insertion.
5414	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
5415
5416	// AdvertiserIdDimensionValue: Dimension value for the ID of the
5417	// advertiser. This is a read-only, auto-generated field.
5418	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
5419
5420	// GroupNumber: Subgroup of the creative group. Assign your creative
5421	// groups to a subgroup in order to filter or manage them more easily.
5422	// This field is required on insertion and is read-only after insertion.
5423	// Acceptable values are 1 to 2, inclusive.
5424	GroupNumber int64 `json:"groupNumber,omitempty"`
5425
5426	// Id: ID of this creative group. This is a read-only, auto-generated
5427	// field.
5428	Id int64 `json:"id,omitempty,string"`
5429
5430	// Kind: Identifies what kind of resource this is. Value: the fixed
5431	// string "dfareporting#creativeGroup".
5432	Kind string `json:"kind,omitempty"`
5433
5434	// Name: Name of this creative group. This is a required field and must
5435	// be less than 256 characters long and unique among creative groups of
5436	// the same advertiser.
5437	Name string `json:"name,omitempty"`
5438
5439	// SubaccountId: Subaccount ID of this creative group. This is a
5440	// read-only field that can be left blank.
5441	SubaccountId int64 `json:"subaccountId,omitempty,string"`
5442
5443	// ServerResponse contains the HTTP response code and headers from the
5444	// server.
5445	googleapi.ServerResponse `json:"-"`
5446
5447	// ForceSendFields is a list of field names (e.g. "AccountId") to
5448	// unconditionally include in API requests. By default, fields with
5449	// empty values are omitted from API requests. However, any non-pointer,
5450	// non-interface field appearing in ForceSendFields will be sent to the
5451	// server regardless of whether the field is empty or not. This may be
5452	// used to include empty fields in Patch requests.
5453	ForceSendFields []string `json:"-"`
5454
5455	// NullFields is a list of field names (e.g. "AccountId") to include in
5456	// API requests with the JSON null value. By default, fields with empty
5457	// values are omitted from API requests. However, any field with an
5458	// empty value appearing in NullFields will be sent to the server as
5459	// null. It is an error if a field in this list has a non-empty value.
5460	// This may be used to include null fields in Patch requests.
5461	NullFields []string `json:"-"`
5462}
5463
5464func (s *CreativeGroup) MarshalJSON() ([]byte, error) {
5465	type NoMethod CreativeGroup
5466	raw := NoMethod(*s)
5467	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5468}
5469
5470// CreativeGroupAssignment: Creative Group Assignment.
5471type CreativeGroupAssignment struct {
5472	// CreativeGroupId: ID of the creative group to be assigned.
5473	CreativeGroupId int64 `json:"creativeGroupId,omitempty,string"`
5474
5475	// CreativeGroupNumber: Creative group number of the creative group
5476	// assignment.
5477	//
5478	// Possible values:
5479	//   "CREATIVE_GROUP_ONE"
5480	//   "CREATIVE_GROUP_TWO"
5481	CreativeGroupNumber string `json:"creativeGroupNumber,omitempty"`
5482
5483	// ForceSendFields is a list of field names (e.g. "CreativeGroupId") to
5484	// unconditionally include in API requests. By default, fields with
5485	// empty values are omitted from API requests. However, any non-pointer,
5486	// non-interface field appearing in ForceSendFields will be sent to the
5487	// server regardless of whether the field is empty or not. This may be
5488	// used to include empty fields in Patch requests.
5489	ForceSendFields []string `json:"-"`
5490
5491	// NullFields is a list of field names (e.g. "CreativeGroupId") to
5492	// include in API requests with the JSON null value. By default, fields
5493	// with empty values are omitted from API requests. However, any field
5494	// with an empty value appearing in NullFields will be sent to the
5495	// server as null. It is an error if a field in this list has a
5496	// non-empty value. This may be used to include null fields in Patch
5497	// requests.
5498	NullFields []string `json:"-"`
5499}
5500
5501func (s *CreativeGroupAssignment) MarshalJSON() ([]byte, error) {
5502	type NoMethod CreativeGroupAssignment
5503	raw := NoMethod(*s)
5504	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5505}
5506
5507// CreativeGroupsListResponse: Creative Group List Response
5508type CreativeGroupsListResponse struct {
5509	// CreativeGroups: Creative group collection.
5510	CreativeGroups []*CreativeGroup `json:"creativeGroups,omitempty"`
5511
5512	// Kind: Identifies what kind of resource this is. Value: the fixed
5513	// string "dfareporting#creativeGroupsListResponse".
5514	Kind string `json:"kind,omitempty"`
5515
5516	// NextPageToken: Pagination token to be used for the next list
5517	// operation.
5518	NextPageToken string `json:"nextPageToken,omitempty"`
5519
5520	// ServerResponse contains the HTTP response code and headers from the
5521	// server.
5522	googleapi.ServerResponse `json:"-"`
5523
5524	// ForceSendFields is a list of field names (e.g. "CreativeGroups") to
5525	// unconditionally include in API requests. By default, fields with
5526	// empty values are omitted from API requests. However, any non-pointer,
5527	// non-interface field appearing in ForceSendFields will be sent to the
5528	// server regardless of whether the field is empty or not. This may be
5529	// used to include empty fields in Patch requests.
5530	ForceSendFields []string `json:"-"`
5531
5532	// NullFields is a list of field names (e.g. "CreativeGroups") to
5533	// include in API requests with the JSON null value. By default, fields
5534	// with empty values are omitted from API requests. However, any field
5535	// with an empty value appearing in NullFields will be sent to the
5536	// server as null. It is an error if a field in this list has a
5537	// non-empty value. This may be used to include null fields in Patch
5538	// requests.
5539	NullFields []string `json:"-"`
5540}
5541
5542func (s *CreativeGroupsListResponse) MarshalJSON() ([]byte, error) {
5543	type NoMethod CreativeGroupsListResponse
5544	raw := NoMethod(*s)
5545	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5546}
5547
5548// CreativeOptimizationConfiguration: Creative optimization settings.
5549type CreativeOptimizationConfiguration struct {
5550	// Id: ID of this creative optimization config. This field is
5551	// auto-generated when the campaign is inserted or updated. It can be
5552	// null for existing campaigns.
5553	Id int64 `json:"id,omitempty,string"`
5554
5555	// Name: Name of this creative optimization config. This is a required
5556	// field and must be less than 129 characters long.
5557	Name string `json:"name,omitempty"`
5558
5559	// OptimizationActivitys: List of optimization activities associated
5560	// with this configuration.
5561	OptimizationActivitys []*OptimizationActivity `json:"optimizationActivitys,omitempty"`
5562
5563	// OptimizationModel: Optimization model for this configuration.
5564	//
5565	// Possible values:
5566	//   "CLICK"
5567	//   "POST_CLICK"
5568	//   "POST_CLICK_AND_IMPRESSION"
5569	//   "POST_IMPRESSION"
5570	//   "VIDEO_COMPLETION"
5571	OptimizationModel string `json:"optimizationModel,omitempty"`
5572
5573	// ForceSendFields is a list of field names (e.g. "Id") to
5574	// unconditionally include in API requests. By default, fields with
5575	// empty values are omitted from API requests. However, any non-pointer,
5576	// non-interface field appearing in ForceSendFields will be sent to the
5577	// server regardless of whether the field is empty or not. This may be
5578	// used to include empty fields in Patch requests.
5579	ForceSendFields []string `json:"-"`
5580
5581	// NullFields is a list of field names (e.g. "Id") to include in API
5582	// requests with the JSON null value. By default, fields with empty
5583	// values are omitted from API requests. However, any field with an
5584	// empty value appearing in NullFields will be sent to the server as
5585	// null. It is an error if a field in this list has a non-empty value.
5586	// This may be used to include null fields in Patch requests.
5587	NullFields []string `json:"-"`
5588}
5589
5590func (s *CreativeOptimizationConfiguration) MarshalJSON() ([]byte, error) {
5591	type NoMethod CreativeOptimizationConfiguration
5592	raw := NoMethod(*s)
5593	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5594}
5595
5596// CreativeRotation: Creative Rotation.
5597type CreativeRotation struct {
5598	// CreativeAssignments: Creative assignments in this creative rotation.
5599	CreativeAssignments []*CreativeAssignment `json:"creativeAssignments,omitempty"`
5600
5601	// CreativeOptimizationConfigurationId: Creative optimization
5602	// configuration that is used by this ad. It should refer to one of the
5603	// existing optimization configurations in the ad's campaign. If it is
5604	// unset or set to 0, then the campaign's default optimization
5605	// configuration will be used for this ad.
5606	CreativeOptimizationConfigurationId int64 `json:"creativeOptimizationConfigurationId,omitempty,string"`
5607
5608	// Type: Type of creative rotation. Can be used to specify whether to
5609	// use sequential or random rotation.
5610	//
5611	// Possible values:
5612	//   "CREATIVE_ROTATION_TYPE_RANDOM"
5613	//   "CREATIVE_ROTATION_TYPE_SEQUENTIAL"
5614	Type string `json:"type,omitempty"`
5615
5616	// WeightCalculationStrategy: Strategy for calculating weights. Used
5617	// with CREATIVE_ROTATION_TYPE_RANDOM.
5618	//
5619	// Possible values:
5620	//   "WEIGHT_STRATEGY_CUSTOM"
5621	//   "WEIGHT_STRATEGY_EQUAL"
5622	//   "WEIGHT_STRATEGY_HIGHEST_CTR"
5623	//   "WEIGHT_STRATEGY_OPTIMIZED"
5624	WeightCalculationStrategy string `json:"weightCalculationStrategy,omitempty"`
5625
5626	// ForceSendFields is a list of field names (e.g. "CreativeAssignments")
5627	// to unconditionally include in API requests. By default, fields with
5628	// empty values are omitted from API requests. However, any non-pointer,
5629	// non-interface field appearing in ForceSendFields will be sent to the
5630	// server regardless of whether the field is empty or not. This may be
5631	// used to include empty fields in Patch requests.
5632	ForceSendFields []string `json:"-"`
5633
5634	// NullFields is a list of field names (e.g. "CreativeAssignments") to
5635	// include in API requests with the JSON null value. By default, fields
5636	// with empty values are omitted from API requests. However, any field
5637	// with an empty value appearing in NullFields will be sent to the
5638	// server as null. It is an error if a field in this list has a
5639	// non-empty value. This may be used to include null fields in Patch
5640	// requests.
5641	NullFields []string `json:"-"`
5642}
5643
5644func (s *CreativeRotation) MarshalJSON() ([]byte, error) {
5645	type NoMethod CreativeRotation
5646	raw := NoMethod(*s)
5647	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5648}
5649
5650// CreativeSettings: Creative Settings
5651type CreativeSettings struct {
5652	// IFrameFooter: Header text for iFrames for this site. Must be less
5653	// than or equal to 2000 characters long.
5654	IFrameFooter string `json:"iFrameFooter,omitempty"`
5655
5656	// IFrameHeader: Header text for iFrames for this site. Must be less
5657	// than or equal to 2000 characters long.
5658	IFrameHeader string `json:"iFrameHeader,omitempty"`
5659
5660	// ForceSendFields is a list of field names (e.g. "IFrameFooter") to
5661	// unconditionally include in API requests. By default, fields with
5662	// empty values are omitted from API requests. However, any non-pointer,
5663	// non-interface field appearing in ForceSendFields will be sent to the
5664	// server regardless of whether the field is empty or not. This may be
5665	// used to include empty fields in Patch requests.
5666	ForceSendFields []string `json:"-"`
5667
5668	// NullFields is a list of field names (e.g. "IFrameFooter") to include
5669	// in API requests with the JSON null value. By default, fields with
5670	// empty values are omitted from API requests. However, any field with
5671	// an empty value appearing in NullFields will be sent to the server as
5672	// null. It is an error if a field in this list has a non-empty value.
5673	// This may be used to include null fields in Patch requests.
5674	NullFields []string `json:"-"`
5675}
5676
5677func (s *CreativeSettings) MarshalJSON() ([]byte, error) {
5678	type NoMethod CreativeSettings
5679	raw := NoMethod(*s)
5680	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5681}
5682
5683// CreativesListResponse: Creative List Response
5684type CreativesListResponse struct {
5685	// Creatives: Creative collection.
5686	Creatives []*Creative `json:"creatives,omitempty"`
5687
5688	// Kind: Identifies what kind of resource this is. Value: the fixed
5689	// string "dfareporting#creativesListResponse".
5690	Kind string `json:"kind,omitempty"`
5691
5692	// NextPageToken: Pagination token to be used for the next list
5693	// operation.
5694	NextPageToken string `json:"nextPageToken,omitempty"`
5695
5696	// ServerResponse contains the HTTP response code and headers from the
5697	// server.
5698	googleapi.ServerResponse `json:"-"`
5699
5700	// ForceSendFields is a list of field names (e.g. "Creatives") to
5701	// unconditionally include in API requests. By default, fields with
5702	// empty values are omitted from API requests. However, any non-pointer,
5703	// non-interface field appearing in ForceSendFields will be sent to the
5704	// server regardless of whether the field is empty or not. This may be
5705	// used to include empty fields in Patch requests.
5706	ForceSendFields []string `json:"-"`
5707
5708	// NullFields is a list of field names (e.g. "Creatives") to include in
5709	// API requests with the JSON null value. By default, fields with empty
5710	// values are omitted from API requests. However, any field with an
5711	// empty value appearing in NullFields will be sent to the server as
5712	// null. It is an error if a field in this list has a non-empty value.
5713	// This may be used to include null fields in Patch requests.
5714	NullFields []string `json:"-"`
5715}
5716
5717func (s *CreativesListResponse) MarshalJSON() ([]byte, error) {
5718	type NoMethod CreativesListResponse
5719	raw := NoMethod(*s)
5720	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5721}
5722
5723// CrossDimensionReachReportCompatibleFields: Represents fields that are
5724// compatible to be selected for a report of type
5725// "CROSS_DIMENSION_REACH".
5726type CrossDimensionReachReportCompatibleFields struct {
5727	// Breakdown: Dimensions which are compatible to be selected in the
5728	// "breakdown" section of the report.
5729	Breakdown []*Dimension `json:"breakdown,omitempty"`
5730
5731	// DimensionFilters: Dimensions which are compatible to be selected in
5732	// the "dimensionFilters" section of the report.
5733	DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
5734
5735	// Kind: The kind of resource this is, in this case
5736	// dfareporting#crossDimensionReachReportCompatibleFields.
5737	Kind string `json:"kind,omitempty"`
5738
5739	// Metrics: Metrics which are compatible to be selected in the
5740	// "metricNames" section of the report.
5741	Metrics []*Metric `json:"metrics,omitempty"`
5742
5743	// OverlapMetrics: Metrics which are compatible to be selected in the
5744	// "overlapMetricNames" section of the report.
5745	OverlapMetrics []*Metric `json:"overlapMetrics,omitempty"`
5746
5747	// ForceSendFields is a list of field names (e.g. "Breakdown") to
5748	// unconditionally include in API requests. By default, fields with
5749	// empty values are omitted from API requests. However, any non-pointer,
5750	// non-interface field appearing in ForceSendFields will be sent to the
5751	// server regardless of whether the field is empty or not. This may be
5752	// used to include empty fields in Patch requests.
5753	ForceSendFields []string `json:"-"`
5754
5755	// NullFields is a list of field names (e.g. "Breakdown") 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 *CrossDimensionReachReportCompatibleFields) MarshalJSON() ([]byte, error) {
5765	type NoMethod CrossDimensionReachReportCompatibleFields
5766	raw := NoMethod(*s)
5767	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5768}
5769
5770// CustomFloodlightVariable: A custom floodlight variable.
5771type CustomFloodlightVariable struct {
5772	// Kind: Identifies what kind of resource this is. Value: the fixed
5773	// string "dfareporting#customFloodlightVariable".
5774	Kind string `json:"kind,omitempty"`
5775
5776	// Type: The type of custom floodlight variable to supply a value for.
5777	// These map to the "u[1-20]=" in the tags.
5778	//
5779	// Possible values:
5780	//   "U1"
5781	//   "U10"
5782	//   "U100"
5783	//   "U11"
5784	//   "U12"
5785	//   "U13"
5786	//   "U14"
5787	//   "U15"
5788	//   "U16"
5789	//   "U17"
5790	//   "U18"
5791	//   "U19"
5792	//   "U2"
5793	//   "U20"
5794	//   "U21"
5795	//   "U22"
5796	//   "U23"
5797	//   "U24"
5798	//   "U25"
5799	//   "U26"
5800	//   "U27"
5801	//   "U28"
5802	//   "U29"
5803	//   "U3"
5804	//   "U30"
5805	//   "U31"
5806	//   "U32"
5807	//   "U33"
5808	//   "U34"
5809	//   "U35"
5810	//   "U36"
5811	//   "U37"
5812	//   "U38"
5813	//   "U39"
5814	//   "U4"
5815	//   "U40"
5816	//   "U41"
5817	//   "U42"
5818	//   "U43"
5819	//   "U44"
5820	//   "U45"
5821	//   "U46"
5822	//   "U47"
5823	//   "U48"
5824	//   "U49"
5825	//   "U5"
5826	//   "U50"
5827	//   "U51"
5828	//   "U52"
5829	//   "U53"
5830	//   "U54"
5831	//   "U55"
5832	//   "U56"
5833	//   "U57"
5834	//   "U58"
5835	//   "U59"
5836	//   "U6"
5837	//   "U60"
5838	//   "U61"
5839	//   "U62"
5840	//   "U63"
5841	//   "U64"
5842	//   "U65"
5843	//   "U66"
5844	//   "U67"
5845	//   "U68"
5846	//   "U69"
5847	//   "U7"
5848	//   "U70"
5849	//   "U71"
5850	//   "U72"
5851	//   "U73"
5852	//   "U74"
5853	//   "U75"
5854	//   "U76"
5855	//   "U77"
5856	//   "U78"
5857	//   "U79"
5858	//   "U8"
5859	//   "U80"
5860	//   "U81"
5861	//   "U82"
5862	//   "U83"
5863	//   "U84"
5864	//   "U85"
5865	//   "U86"
5866	//   "U87"
5867	//   "U88"
5868	//   "U89"
5869	//   "U9"
5870	//   "U90"
5871	//   "U91"
5872	//   "U92"
5873	//   "U93"
5874	//   "U94"
5875	//   "U95"
5876	//   "U96"
5877	//   "U97"
5878	//   "U98"
5879	//   "U99"
5880	Type string `json:"type,omitempty"`
5881
5882	// Value: The value of the custom floodlight variable. The length of
5883	// string must not exceed 50 characters.
5884	Value string `json:"value,omitempty"`
5885
5886	// ForceSendFields is a list of field names (e.g. "Kind") to
5887	// unconditionally include in API requests. By default, fields with
5888	// empty values are omitted from API requests. However, any non-pointer,
5889	// non-interface field appearing in ForceSendFields will be sent to the
5890	// server regardless of whether the field is empty or not. This may be
5891	// used to include empty fields in Patch requests.
5892	ForceSendFields []string `json:"-"`
5893
5894	// NullFields is a list of field names (e.g. "Kind") to include in API
5895	// requests with the JSON null value. By default, fields with empty
5896	// values are omitted from API requests. However, any field with an
5897	// empty value appearing in NullFields will be sent to the server as
5898	// null. It is an error if a field in this list has a non-empty value.
5899	// This may be used to include null fields in Patch requests.
5900	NullFields []string `json:"-"`
5901}
5902
5903func (s *CustomFloodlightVariable) MarshalJSON() ([]byte, error) {
5904	type NoMethod CustomFloodlightVariable
5905	raw := NoMethod(*s)
5906	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5907}
5908
5909// CustomRichMediaEvents: Represents a Custom Rich Media Events group.
5910type CustomRichMediaEvents struct {
5911	// FilteredEventIds: List of custom rich media event IDs. Dimension
5912	// values must be all of type dfa:richMediaEventTypeIdAndName.
5913	FilteredEventIds []*DimensionValue `json:"filteredEventIds,omitempty"`
5914
5915	// Kind: The kind of resource this is, in this case
5916	// dfareporting#customRichMediaEvents.
5917	Kind string `json:"kind,omitempty"`
5918
5919	// ForceSendFields is a list of field names (e.g. "FilteredEventIds") to
5920	// unconditionally include in API requests. By default, fields with
5921	// empty values are omitted from API requests. However, any non-pointer,
5922	// non-interface field appearing in ForceSendFields will be sent to the
5923	// server regardless of whether the field is empty or not. This may be
5924	// used to include empty fields in Patch requests.
5925	ForceSendFields []string `json:"-"`
5926
5927	// NullFields is a list of field names (e.g. "FilteredEventIds") to
5928	// include in API requests with the JSON null value. By default, fields
5929	// with empty values are omitted from API requests. However, any field
5930	// with an empty value appearing in NullFields will be sent to the
5931	// server as null. It is an error if a field in this list has a
5932	// non-empty value. This may be used to include null fields in Patch
5933	// requests.
5934	NullFields []string `json:"-"`
5935}
5936
5937func (s *CustomRichMediaEvents) MarshalJSON() ([]byte, error) {
5938	type NoMethod CustomRichMediaEvents
5939	raw := NoMethod(*s)
5940	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5941}
5942
5943// DateRange: Represents a date range.
5944type DateRange struct {
5945	// EndDate: The end date of the date range, inclusive. A string of the
5946	// format: "yyyy-MM-dd".
5947	EndDate string `json:"endDate,omitempty"`
5948
5949	// Kind: The kind of resource this is, in this case
5950	// dfareporting#dateRange.
5951	Kind string `json:"kind,omitempty"`
5952
5953	// RelativeDateRange: The date range relative to the date of when the
5954	// report is run.
5955	//
5956	// Possible values:
5957	//   "LAST_14_DAYS"
5958	//   "LAST_24_MONTHS"
5959	//   "LAST_30_DAYS"
5960	//   "LAST_365_DAYS"
5961	//   "LAST_60_DAYS"
5962	//   "LAST_7_DAYS"
5963	//   "LAST_90_DAYS"
5964	//   "MONTH_TO_DATE"
5965	//   "PREVIOUS_MONTH"
5966	//   "PREVIOUS_QUARTER"
5967	//   "PREVIOUS_WEEK"
5968	//   "PREVIOUS_YEAR"
5969	//   "QUARTER_TO_DATE"
5970	//   "TODAY"
5971	//   "WEEK_TO_DATE"
5972	//   "YEAR_TO_DATE"
5973	//   "YESTERDAY"
5974	RelativeDateRange string `json:"relativeDateRange,omitempty"`
5975
5976	// StartDate: The start date of the date range, inclusive. A string of
5977	// the format: "yyyy-MM-dd".
5978	StartDate string `json:"startDate,omitempty"`
5979
5980	// ForceSendFields is a list of field names (e.g. "EndDate") to
5981	// unconditionally include in API requests. By default, fields with
5982	// empty values are omitted from API requests. However, any non-pointer,
5983	// non-interface field appearing in ForceSendFields will be sent to the
5984	// server regardless of whether the field is empty or not. This may be
5985	// used to include empty fields in Patch requests.
5986	ForceSendFields []string `json:"-"`
5987
5988	// NullFields is a list of field names (e.g. "EndDate") to include in
5989	// API requests with the JSON null value. By default, fields with empty
5990	// values are omitted from API requests. However, any field with an
5991	// empty value appearing in NullFields will be sent to the server as
5992	// null. It is an error if a field in this list has a non-empty value.
5993	// This may be used to include null fields in Patch requests.
5994	NullFields []string `json:"-"`
5995}
5996
5997func (s *DateRange) MarshalJSON() ([]byte, error) {
5998	type NoMethod DateRange
5999	raw := NoMethod(*s)
6000	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6001}
6002
6003// DayPartTargeting: Day Part Targeting.
6004type DayPartTargeting struct {
6005	// DaysOfWeek: Days of the week when the ad will serve.
6006	//
6007	// Acceptable values are:
6008	// - "SUNDAY"
6009	// - "MONDAY"
6010	// - "TUESDAY"
6011	// - "WEDNESDAY"
6012	// - "THURSDAY"
6013	// - "FRIDAY"
6014	// - "SATURDAY"
6015	//
6016	// Possible values:
6017	//   "FRIDAY"
6018	//   "MONDAY"
6019	//   "SATURDAY"
6020	//   "SUNDAY"
6021	//   "THURSDAY"
6022	//   "TUESDAY"
6023	//   "WEDNESDAY"
6024	DaysOfWeek []string `json:"daysOfWeek,omitempty"`
6025
6026	// HoursOfDay: Hours of the day when the ad will serve, where 0 is
6027	// midnight to 1 AM and 23 is 11 PM to midnight. Can be specified with
6028	// days of week, in which case the ad would serve during these hours on
6029	// the specified days. For example if Monday, Wednesday, Friday are the
6030	// days of week specified and 9-10am, 3-5pm (hours 9, 15, and 16) is
6031	// specified, the ad would serve Monday, Wednesdays, and Fridays at
6032	// 9-10am and 3-5pm. Acceptable values are 0 to 23, inclusive.
6033	HoursOfDay []int64 `json:"hoursOfDay,omitempty"`
6034
6035	// UserLocalTime: Whether or not to use the user's local time. If false,
6036	// the America/New York time zone applies.
6037	UserLocalTime bool `json:"userLocalTime,omitempty"`
6038
6039	// ForceSendFields is a list of field names (e.g. "DaysOfWeek") to
6040	// unconditionally include in API requests. By default, fields with
6041	// empty values are omitted from API requests. However, any non-pointer,
6042	// non-interface field appearing in ForceSendFields will be sent to the
6043	// server regardless of whether the field is empty or not. This may be
6044	// used to include empty fields in Patch requests.
6045	ForceSendFields []string `json:"-"`
6046
6047	// NullFields is a list of field names (e.g. "DaysOfWeek") to include in
6048	// API requests with the JSON null value. By default, fields with empty
6049	// values are omitted from API requests. However, any field with an
6050	// empty value appearing in NullFields will be sent to the server as
6051	// null. It is an error if a field in this list has a non-empty value.
6052	// This may be used to include null fields in Patch requests.
6053	NullFields []string `json:"-"`
6054}
6055
6056func (s *DayPartTargeting) MarshalJSON() ([]byte, error) {
6057	type NoMethod DayPartTargeting
6058	raw := NoMethod(*s)
6059	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6060}
6061
6062// DeepLink: Contains information about a landing page deep link.
6063type DeepLink struct {
6064	// AppUrl: The URL of the mobile app being linked to.
6065	AppUrl string `json:"appUrl,omitempty"`
6066
6067	// FallbackUrl: The fallback URL. This URL will be served to users who
6068	// do not have the mobile app installed.
6069	FallbackUrl string `json:"fallbackUrl,omitempty"`
6070
6071	// Kind: Identifies what kind of resource this is. Value: the fixed
6072	// string "dfareporting#deepLink".
6073	Kind string `json:"kind,omitempty"`
6074
6075	// MobileApp: The mobile app targeted by this deep link.
6076	MobileApp *MobileApp `json:"mobileApp,omitempty"`
6077
6078	// RemarketingListIds: Ads served to users on these remarketing lists
6079	// will use this deep link. Applicable when mobileApp.directory is
6080	// APPLE_APP_STORE.
6081	RemarketingListIds googleapi.Int64s `json:"remarketingListIds,omitempty"`
6082
6083	// ForceSendFields is a list of field names (e.g. "AppUrl") to
6084	// unconditionally include in API requests. By default, fields with
6085	// empty values are omitted from API requests. However, any non-pointer,
6086	// non-interface field appearing in ForceSendFields will be sent to the
6087	// server regardless of whether the field is empty or not. This may be
6088	// used to include empty fields in Patch requests.
6089	ForceSendFields []string `json:"-"`
6090
6091	// NullFields is a list of field names (e.g. "AppUrl") to include in API
6092	// requests with the JSON null value. By default, fields with empty
6093	// values are omitted from API requests. However, any field with an
6094	// empty value appearing in NullFields will be sent to the server as
6095	// null. It is an error if a field in this list has a non-empty value.
6096	// This may be used to include null fields in Patch requests.
6097	NullFields []string `json:"-"`
6098}
6099
6100func (s *DeepLink) MarshalJSON() ([]byte, error) {
6101	type NoMethod DeepLink
6102	raw := NoMethod(*s)
6103	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6104}
6105
6106// DefaultClickThroughEventTagProperties: Properties of inheriting and
6107// overriding the default click-through event tag. A campaign may
6108// override the event tag defined at the advertiser level, and an ad may
6109// also override the campaign's setting further.
6110type DefaultClickThroughEventTagProperties struct {
6111	// DefaultClickThroughEventTagId: ID of the click-through event tag to
6112	// apply to all ads in this entity's scope.
6113	DefaultClickThroughEventTagId int64 `json:"defaultClickThroughEventTagId,omitempty,string"`
6114
6115	// OverrideInheritedEventTag: Whether this entity should override the
6116	// inherited default click-through event tag with its own defined value.
6117	OverrideInheritedEventTag bool `json:"overrideInheritedEventTag,omitempty"`
6118
6119	// ForceSendFields is a list of field names (e.g.
6120	// "DefaultClickThroughEventTagId") to unconditionally include in API
6121	// requests. By default, fields with empty values are omitted from API
6122	// requests. However, any non-pointer, non-interface field appearing in
6123	// ForceSendFields will be sent to the server regardless of whether the
6124	// field is empty or not. This may be used to include empty fields in
6125	// Patch requests.
6126	ForceSendFields []string `json:"-"`
6127
6128	// NullFields is a list of field names (e.g.
6129	// "DefaultClickThroughEventTagId") to include in API requests with the
6130	// JSON null value. By default, fields with empty values are omitted
6131	// from API requests. However, any field with an empty value appearing
6132	// in NullFields will be sent to the server as null. It is an error if a
6133	// field in this list has a non-empty value. This may be used to include
6134	// null fields in Patch requests.
6135	NullFields []string `json:"-"`
6136}
6137
6138func (s *DefaultClickThroughEventTagProperties) MarshalJSON() ([]byte, error) {
6139	type NoMethod DefaultClickThroughEventTagProperties
6140	raw := NoMethod(*s)
6141	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6142}
6143
6144// DeliverySchedule: Delivery Schedule.
6145type DeliverySchedule struct {
6146	// FrequencyCap: Limit on the number of times an individual user can be
6147	// served the ad within a specified period of time.
6148	FrequencyCap *FrequencyCap `json:"frequencyCap,omitempty"`
6149
6150	// HardCutoff: Whether or not hard cutoff is enabled. If true, the ad
6151	// will not serve after the end date and time. Otherwise the ad will
6152	// continue to be served until it has reached its delivery goals.
6153	HardCutoff bool `json:"hardCutoff,omitempty"`
6154
6155	// ImpressionRatio: Impression ratio for this ad. This ratio determines
6156	// how often each ad is served relative to the others. For example, if
6157	// ad A has an impression ratio of 1 and ad B has an impression ratio of
6158	// 3, then Campaign Manager will serve ad B three times as often as ad
6159	// A. Acceptable values are 1 to 10, inclusive.
6160	ImpressionRatio int64 `json:"impressionRatio,omitempty,string"`
6161
6162	// Priority: Serving priority of an ad, with respect to other ads. The
6163	// lower the priority number, the greater the priority with which it is
6164	// served.
6165	//
6166	// Possible values:
6167	//   "AD_PRIORITY_01"
6168	//   "AD_PRIORITY_02"
6169	//   "AD_PRIORITY_03"
6170	//   "AD_PRIORITY_04"
6171	//   "AD_PRIORITY_05"
6172	//   "AD_PRIORITY_06"
6173	//   "AD_PRIORITY_07"
6174	//   "AD_PRIORITY_08"
6175	//   "AD_PRIORITY_09"
6176	//   "AD_PRIORITY_10"
6177	//   "AD_PRIORITY_11"
6178	//   "AD_PRIORITY_12"
6179	//   "AD_PRIORITY_13"
6180	//   "AD_PRIORITY_14"
6181	//   "AD_PRIORITY_15"
6182	//   "AD_PRIORITY_16"
6183	Priority string `json:"priority,omitempty"`
6184
6185	// ForceSendFields is a list of field names (e.g. "FrequencyCap") to
6186	// unconditionally include in API requests. By default, fields with
6187	// empty values are omitted from API requests. However, any non-pointer,
6188	// non-interface field appearing in ForceSendFields will be sent to the
6189	// server regardless of whether the field is empty or not. This may be
6190	// used to include empty fields in Patch requests.
6191	ForceSendFields []string `json:"-"`
6192
6193	// NullFields is a list of field names (e.g. "FrequencyCap") to include
6194	// in API requests with the JSON null value. By default, fields with
6195	// empty values are omitted from API requests. However, any field with
6196	// an empty value appearing in NullFields will be sent to the server as
6197	// null. It is an error if a field in this list has a non-empty value.
6198	// This may be used to include null fields in Patch requests.
6199	NullFields []string `json:"-"`
6200}
6201
6202func (s *DeliverySchedule) MarshalJSON() ([]byte, error) {
6203	type NoMethod DeliverySchedule
6204	raw := NoMethod(*s)
6205	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6206}
6207
6208// DfpSettings: Google Ad Manager Settings
6209type DfpSettings struct {
6210	// DfpNetworkCode: Ad Manager network code for this directory site.
6211	DfpNetworkCode string `json:"dfpNetworkCode,omitempty"`
6212
6213	// DfpNetworkName: Ad Manager network name for this directory site.
6214	DfpNetworkName string `json:"dfpNetworkName,omitempty"`
6215
6216	// ProgrammaticPlacementAccepted: Whether this directory site accepts
6217	// programmatic placements.
6218	ProgrammaticPlacementAccepted bool `json:"programmaticPlacementAccepted,omitempty"`
6219
6220	// PubPaidPlacementAccepted: Whether this directory site accepts
6221	// publisher-paid tags.
6222	PubPaidPlacementAccepted bool `json:"pubPaidPlacementAccepted,omitempty"`
6223
6224	// PublisherPortalOnly: Whether this directory site is available only
6225	// via Publisher Portal.
6226	PublisherPortalOnly bool `json:"publisherPortalOnly,omitempty"`
6227
6228	// ForceSendFields is a list of field names (e.g. "DfpNetworkCode") to
6229	// unconditionally include in API requests. By default, fields with
6230	// empty values are omitted from API requests. However, any non-pointer,
6231	// non-interface field appearing in ForceSendFields will be sent to the
6232	// server regardless of whether the field is empty or not. This may be
6233	// used to include empty fields in Patch requests.
6234	ForceSendFields []string `json:"-"`
6235
6236	// NullFields is a list of field names (e.g. "DfpNetworkCode") to
6237	// include in API requests with the JSON null value. By default, fields
6238	// with empty values are omitted from API requests. However, any field
6239	// with an empty value appearing in NullFields will be sent to the
6240	// server as null. It is an error if a field in this list has a
6241	// non-empty value. This may be used to include null fields in Patch
6242	// requests.
6243	NullFields []string `json:"-"`
6244}
6245
6246func (s *DfpSettings) MarshalJSON() ([]byte, error) {
6247	type NoMethod DfpSettings
6248	raw := NoMethod(*s)
6249	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6250}
6251
6252// Dimension: Represents a dimension.
6253type Dimension struct {
6254	// Kind: The kind of resource this is, in this case
6255	// dfareporting#dimension.
6256	Kind string `json:"kind,omitempty"`
6257
6258	// Name: The dimension name, e.g. dfa:advertiser
6259	Name string `json:"name,omitempty"`
6260
6261	// ForceSendFields is a list of field names (e.g. "Kind") to
6262	// unconditionally include in API requests. By default, fields with
6263	// empty values are omitted from API requests. However, any non-pointer,
6264	// non-interface field appearing in ForceSendFields will be sent to the
6265	// server regardless of whether the field is empty or not. This may be
6266	// used to include empty fields in Patch requests.
6267	ForceSendFields []string `json:"-"`
6268
6269	// NullFields is a list of field names (e.g. "Kind") to include in API
6270	// requests with the JSON null value. By default, fields with empty
6271	// values are omitted from API requests. However, any field with an
6272	// empty value appearing in NullFields will be sent to the server as
6273	// null. It is an error if a field in this list has a non-empty value.
6274	// This may be used to include null fields in Patch requests.
6275	NullFields []string `json:"-"`
6276}
6277
6278func (s *Dimension) MarshalJSON() ([]byte, error) {
6279	type NoMethod Dimension
6280	raw := NoMethod(*s)
6281	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6282}
6283
6284// DimensionFilter: Represents a dimension filter.
6285type DimensionFilter struct {
6286	// DimensionName: The name of the dimension to filter.
6287	DimensionName string `json:"dimensionName,omitempty"`
6288
6289	// Kind: The kind of resource this is, in this case
6290	// dfareporting#dimensionFilter.
6291	Kind string `json:"kind,omitempty"`
6292
6293	// Value: The value of the dimension to filter.
6294	Value string `json:"value,omitempty"`
6295
6296	// ForceSendFields is a list of field names (e.g. "DimensionName") to
6297	// unconditionally include in API requests. By default, fields with
6298	// empty values are omitted from API requests. However, any non-pointer,
6299	// non-interface field appearing in ForceSendFields will be sent to the
6300	// server regardless of whether the field is empty or not. This may be
6301	// used to include empty fields in Patch requests.
6302	ForceSendFields []string `json:"-"`
6303
6304	// NullFields is a list of field names (e.g. "DimensionName") to include
6305	// in API requests with the JSON null value. By default, fields with
6306	// empty values are omitted from API requests. However, any field with
6307	// an empty value appearing in NullFields will be sent to the server as
6308	// null. It is an error if a field in this list has a non-empty value.
6309	// This may be used to include null fields in Patch requests.
6310	NullFields []string `json:"-"`
6311}
6312
6313func (s *DimensionFilter) MarshalJSON() ([]byte, error) {
6314	type NoMethod DimensionFilter
6315	raw := NoMethod(*s)
6316	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6317}
6318
6319// DimensionValue: Represents a DimensionValue resource.
6320type DimensionValue struct {
6321	// DimensionName: The name of the dimension.
6322	DimensionName string `json:"dimensionName,omitempty"`
6323
6324	// Etag: The eTag of this response for caching purposes.
6325	Etag string `json:"etag,omitempty"`
6326
6327	// Id: The ID associated with the value if available.
6328	Id string `json:"id,omitempty"`
6329
6330	// Kind: The kind of resource this is, in this case
6331	// dfareporting#dimensionValue.
6332	Kind string `json:"kind,omitempty"`
6333
6334	// MatchType: Determines how the 'value' field is matched when
6335	// filtering. If not specified, defaults to EXACT. If set to
6336	// WILDCARD_EXPRESSION, '*' is allowed as a placeholder for variable
6337	// length character sequences, and it can be escaped with a backslash.
6338	// Note, only paid search dimensions ('dfa:paidSearch*') allow a
6339	// matchType other than EXACT.
6340	//
6341	// Possible values:
6342	//   "BEGINS_WITH"
6343	//   "CONTAINS"
6344	//   "EXACT"
6345	//   "WILDCARD_EXPRESSION"
6346	MatchType string `json:"matchType,omitempty"`
6347
6348	// Value: The value of the dimension.
6349	Value string `json:"value,omitempty"`
6350
6351	// ForceSendFields is a list of field names (e.g. "DimensionName") to
6352	// unconditionally include in API requests. By default, fields with
6353	// empty values are omitted from API requests. However, any non-pointer,
6354	// non-interface field appearing in ForceSendFields will be sent to the
6355	// server regardless of whether the field is empty or not. This may be
6356	// used to include empty fields in Patch requests.
6357	ForceSendFields []string `json:"-"`
6358
6359	// NullFields is a list of field names (e.g. "DimensionName") to include
6360	// in API requests with the JSON null value. By default, fields with
6361	// empty values are omitted from API requests. However, any field with
6362	// an empty value appearing in NullFields will be sent to the server as
6363	// null. It is an error if a field in this list has a non-empty value.
6364	// This may be used to include null fields in Patch requests.
6365	NullFields []string `json:"-"`
6366}
6367
6368func (s *DimensionValue) MarshalJSON() ([]byte, error) {
6369	type NoMethod DimensionValue
6370	raw := NoMethod(*s)
6371	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6372}
6373
6374// DimensionValueList: Represents the list of DimensionValue resources.
6375type DimensionValueList struct {
6376	// Etag: The eTag of this response for caching purposes.
6377	Etag string `json:"etag,omitempty"`
6378
6379	// Items: The dimension values returned in this response.
6380	Items []*DimensionValue `json:"items,omitempty"`
6381
6382	// Kind: The kind of list this is, in this case
6383	// dfareporting#dimensionValueList.
6384	Kind string `json:"kind,omitempty"`
6385
6386	// NextPageToken: Continuation token used to page through dimension
6387	// values. To retrieve the next page of results, set the next request's
6388	// "pageToken" to the value of this field. The page token is only valid
6389	// for a limited amount of time and should not be persisted.
6390	NextPageToken string `json:"nextPageToken,omitempty"`
6391
6392	// ServerResponse contains the HTTP response code and headers from the
6393	// server.
6394	googleapi.ServerResponse `json:"-"`
6395
6396	// ForceSendFields is a list of field names (e.g. "Etag") to
6397	// unconditionally include in API requests. By default, fields with
6398	// empty values are omitted from API requests. However, any non-pointer,
6399	// non-interface field appearing in ForceSendFields will be sent to the
6400	// server regardless of whether the field is empty or not. This may be
6401	// used to include empty fields in Patch requests.
6402	ForceSendFields []string `json:"-"`
6403
6404	// NullFields is a list of field names (e.g. "Etag") to include in API
6405	// requests with the JSON null value. By default, fields with empty
6406	// values are omitted from API requests. However, any field with an
6407	// empty value appearing in NullFields will be sent to the server as
6408	// null. It is an error if a field in this list has a non-empty value.
6409	// This may be used to include null fields in Patch requests.
6410	NullFields []string `json:"-"`
6411}
6412
6413func (s *DimensionValueList) MarshalJSON() ([]byte, error) {
6414	type NoMethod DimensionValueList
6415	raw := NoMethod(*s)
6416	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6417}
6418
6419// DimensionValueRequest: Represents a DimensionValuesRequest.
6420type DimensionValueRequest struct {
6421	// DimensionName: The name of the dimension for which values should be
6422	// requested.
6423	DimensionName string `json:"dimensionName,omitempty"`
6424
6425	// EndDate: The end date of the date range for which to retrieve
6426	// dimension values. A string of the format "yyyy-MM-dd".
6427	EndDate string `json:"endDate,omitempty"`
6428
6429	// Filters: The list of filters by which to filter values. The filters
6430	// are ANDed.
6431	Filters []*DimensionFilter `json:"filters,omitempty"`
6432
6433	// Kind: The kind of request this is, in this case
6434	// dfareporting#dimensionValueRequest.
6435	Kind string `json:"kind,omitempty"`
6436
6437	// StartDate: The start date of the date range for which to retrieve
6438	// dimension values. A string of the format "yyyy-MM-dd".
6439	StartDate string `json:"startDate,omitempty"`
6440
6441	// ForceSendFields is a list of field names (e.g. "DimensionName") to
6442	// unconditionally include in API requests. By default, fields with
6443	// empty values are omitted from API requests. However, any non-pointer,
6444	// non-interface field appearing in ForceSendFields will be sent to the
6445	// server regardless of whether the field is empty or not. This may be
6446	// used to include empty fields in Patch requests.
6447	ForceSendFields []string `json:"-"`
6448
6449	// NullFields is a list of field names (e.g. "DimensionName") to include
6450	// in API requests with the JSON null value. By default, fields with
6451	// empty values are omitted from API requests. However, any field with
6452	// an empty value appearing in NullFields will be sent to the server as
6453	// null. It is an error if a field in this list has a non-empty value.
6454	// This may be used to include null fields in Patch requests.
6455	NullFields []string `json:"-"`
6456}
6457
6458func (s *DimensionValueRequest) MarshalJSON() ([]byte, error) {
6459	type NoMethod DimensionValueRequest
6460	raw := NoMethod(*s)
6461	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6462}
6463
6464// DirectorySite: DirectorySites contains properties of a website from
6465// the Site Directory. Sites need to be added to an account via the
6466// Sites resource before they can be assigned to a placement.
6467type DirectorySite struct {
6468	// Active: Whether this directory site is active.
6469	Active bool `json:"active,omitempty"`
6470
6471	// ContactAssignments: Directory site contacts.
6472	ContactAssignments []*DirectorySiteContactAssignment `json:"contactAssignments,omitempty"`
6473
6474	// CountryId: Country ID of this directory site. This is a read-only
6475	// field.
6476	CountryId int64 `json:"countryId,omitempty,string"`
6477
6478	// CurrencyId: Currency ID of this directory site. This is a read-only
6479	// field.
6480	// Possible values are:
6481	// - "1" for USD
6482	// - "2" for GBP
6483	// - "3" for ESP
6484	// - "4" for SEK
6485	// - "5" for CAD
6486	// - "6" for JPY
6487	// - "7" for DEM
6488	// - "8" for AUD
6489	// - "9" for FRF
6490	// - "10" for ITL
6491	// - "11" for DKK
6492	// - "12" for NOK
6493	// - "13" for FIM
6494	// - "14" for ZAR
6495	// - "15" for IEP
6496	// - "16" for NLG
6497	// - "17" for EUR
6498	// - "18" for KRW
6499	// - "19" for TWD
6500	// - "20" for SGD
6501	// - "21" for CNY
6502	// - "22" for HKD
6503	// - "23" for NZD
6504	// - "24" for MYR
6505	// - "25" for BRL
6506	// - "26" for PTE
6507	// - "27" for MXP
6508	// - "28" for CLP
6509	// - "29" for TRY
6510	// - "30" for ARS
6511	// - "31" for PEN
6512	// - "32" for ILS
6513	// - "33" for CHF
6514	// - "34" for VEF
6515	// - "35" for COP
6516	// - "36" for GTQ
6517	// - "37" for PLN
6518	// - "39" for INR
6519	// - "40" for THB
6520	// - "41" for IDR
6521	// - "42" for CZK
6522	// - "43" for RON
6523	// - "44" for HUF
6524	// - "45" for RUB
6525	// - "46" for AED
6526	// - "47" for BGN
6527	// - "48" for HRK
6528	// - "49" for MXN
6529	// - "50" for NGN
6530	CurrencyId int64 `json:"currencyId,omitempty,string"`
6531
6532	// Description: Description of this directory site. This is a read-only
6533	// field.
6534	Description string `json:"description,omitempty"`
6535
6536	// Id: ID of this directory site. This is a read-only, auto-generated
6537	// field.
6538	Id int64 `json:"id,omitempty,string"`
6539
6540	// IdDimensionValue: Dimension value for the ID of this directory site.
6541	// This is a read-only, auto-generated field.
6542	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
6543
6544	// InpageTagFormats: Tag types for regular placements.
6545	//
6546	// Acceptable values are:
6547	// - "STANDARD"
6548	// - "IFRAME_JAVASCRIPT_INPAGE"
6549	// - "INTERNAL_REDIRECT_INPAGE"
6550	// - "JAVASCRIPT_INPAGE"
6551	//
6552	// Possible values:
6553	//   "IFRAME_JAVASCRIPT_INPAGE"
6554	//   "INTERNAL_REDIRECT_INPAGE"
6555	//   "JAVASCRIPT_INPAGE"
6556	//   "STANDARD"
6557	InpageTagFormats []string `json:"inpageTagFormats,omitempty"`
6558
6559	// InterstitialTagFormats: Tag types for interstitial
6560	// placements.
6561	//
6562	// Acceptable values are:
6563	// - "IFRAME_JAVASCRIPT_INTERSTITIAL"
6564	// - "INTERNAL_REDIRECT_INTERSTITIAL"
6565	// - "JAVASCRIPT_INTERSTITIAL"
6566	//
6567	// Possible values:
6568	//   "IFRAME_JAVASCRIPT_INTERSTITIAL"
6569	//   "INTERNAL_REDIRECT_INTERSTITIAL"
6570	//   "JAVASCRIPT_INTERSTITIAL"
6571	InterstitialTagFormats []string `json:"interstitialTagFormats,omitempty"`
6572
6573	// Kind: Identifies what kind of resource this is. Value: the fixed
6574	// string "dfareporting#directorySite".
6575	Kind string `json:"kind,omitempty"`
6576
6577	// Name: Name of this directory site.
6578	Name string `json:"name,omitempty"`
6579
6580	// ParentId: Parent directory site ID.
6581	ParentId int64 `json:"parentId,omitempty,string"`
6582
6583	// Settings: Directory site settings.
6584	Settings *DirectorySiteSettings `json:"settings,omitempty"`
6585
6586	// Url: URL of this directory site.
6587	Url string `json:"url,omitempty"`
6588
6589	// ServerResponse contains the HTTP response code and headers from the
6590	// server.
6591	googleapi.ServerResponse `json:"-"`
6592
6593	// ForceSendFields is a list of field names (e.g. "Active") to
6594	// unconditionally include in API requests. By default, fields with
6595	// empty values are omitted from API requests. However, any non-pointer,
6596	// non-interface field appearing in ForceSendFields will be sent to the
6597	// server regardless of whether the field is empty or not. This may be
6598	// used to include empty fields in Patch requests.
6599	ForceSendFields []string `json:"-"`
6600
6601	// NullFields is a list of field names (e.g. "Active") to include in API
6602	// requests with the JSON null value. By default, fields with empty
6603	// values are omitted from API requests. However, any field with an
6604	// empty value appearing in NullFields will be sent to the server as
6605	// null. It is an error if a field in this list has a non-empty value.
6606	// This may be used to include null fields in Patch requests.
6607	NullFields []string `json:"-"`
6608}
6609
6610func (s *DirectorySite) MarshalJSON() ([]byte, error) {
6611	type NoMethod DirectorySite
6612	raw := NoMethod(*s)
6613	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6614}
6615
6616// DirectorySiteContact: Contains properties of a Site Directory
6617// contact.
6618type DirectorySiteContact struct {
6619	// Address: Address of this directory site contact.
6620	Address string `json:"address,omitempty"`
6621
6622	// Email: Email address of this directory site contact.
6623	Email string `json:"email,omitempty"`
6624
6625	// FirstName: First name of this directory site contact.
6626	FirstName string `json:"firstName,omitempty"`
6627
6628	// Id: ID of this directory site contact. This is a read-only,
6629	// auto-generated field.
6630	Id int64 `json:"id,omitempty,string"`
6631
6632	// Kind: Identifies what kind of resource this is. Value: the fixed
6633	// string "dfareporting#directorySiteContact".
6634	Kind string `json:"kind,omitempty"`
6635
6636	// LastName: Last name of this directory site contact.
6637	LastName string `json:"lastName,omitempty"`
6638
6639	// Phone: Phone number of this directory site contact.
6640	Phone string `json:"phone,omitempty"`
6641
6642	// Role: Directory site contact role.
6643	//
6644	// Possible values:
6645	//   "ADMIN"
6646	//   "EDIT"
6647	//   "VIEW"
6648	Role string `json:"role,omitempty"`
6649
6650	// Title: Title or designation of this directory site contact.
6651	Title string `json:"title,omitempty"`
6652
6653	// Type: Directory site contact type.
6654	//
6655	// Possible values:
6656	//   "BILLING"
6657	//   "OTHER"
6658	//   "SALES"
6659	//   "TECHNICAL"
6660	Type string `json:"type,omitempty"`
6661
6662	// ServerResponse contains the HTTP response code and headers from the
6663	// server.
6664	googleapi.ServerResponse `json:"-"`
6665
6666	// ForceSendFields is a list of field names (e.g. "Address") to
6667	// unconditionally include in API requests. By default, fields with
6668	// empty values are omitted from API requests. However, any non-pointer,
6669	// non-interface field appearing in ForceSendFields will be sent to the
6670	// server regardless of whether the field is empty or not. This may be
6671	// used to include empty fields in Patch requests.
6672	ForceSendFields []string `json:"-"`
6673
6674	// NullFields is a list of field names (e.g. "Address") to include in
6675	// API requests with the JSON null value. By default, fields with empty
6676	// values are omitted from API requests. However, any field with an
6677	// empty value appearing in NullFields will be sent to the server as
6678	// null. It is an error if a field in this list has a non-empty value.
6679	// This may be used to include null fields in Patch requests.
6680	NullFields []string `json:"-"`
6681}
6682
6683func (s *DirectorySiteContact) MarshalJSON() ([]byte, error) {
6684	type NoMethod DirectorySiteContact
6685	raw := NoMethod(*s)
6686	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6687}
6688
6689// DirectorySiteContactAssignment: Directory Site Contact Assignment
6690type DirectorySiteContactAssignment struct {
6691	// ContactId: ID of this directory site contact. This is a read-only,
6692	// auto-generated field.
6693	ContactId int64 `json:"contactId,omitempty,string"`
6694
6695	// Visibility: Visibility of this directory site contact assignment.
6696	// When set to PUBLIC this contact assignment is visible to all account
6697	// and agency users; when set to PRIVATE it is visible only to the site.
6698	//
6699	// Possible values:
6700	//   "PRIVATE"
6701	//   "PUBLIC"
6702	Visibility string `json:"visibility,omitempty"`
6703
6704	// ForceSendFields is a list of field names (e.g. "ContactId") to
6705	// unconditionally include in API requests. By default, fields with
6706	// empty values are omitted from API requests. However, any non-pointer,
6707	// non-interface field appearing in ForceSendFields will be sent to the
6708	// server regardless of whether the field is empty or not. This may be
6709	// used to include empty fields in Patch requests.
6710	ForceSendFields []string `json:"-"`
6711
6712	// NullFields is a list of field names (e.g. "ContactId") to include in
6713	// API requests with the JSON null value. By default, fields with empty
6714	// values are omitted from API requests. However, any field with an
6715	// empty value appearing in NullFields will be sent to the server as
6716	// null. It is an error if a field in this list has a non-empty value.
6717	// This may be used to include null fields in Patch requests.
6718	NullFields []string `json:"-"`
6719}
6720
6721func (s *DirectorySiteContactAssignment) MarshalJSON() ([]byte, error) {
6722	type NoMethod DirectorySiteContactAssignment
6723	raw := NoMethod(*s)
6724	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6725}
6726
6727// DirectorySiteContactsListResponse: Directory Site Contact List
6728// Response
6729type DirectorySiteContactsListResponse struct {
6730	// DirectorySiteContacts: Directory site contact collection
6731	DirectorySiteContacts []*DirectorySiteContact `json:"directorySiteContacts,omitempty"`
6732
6733	// Kind: Identifies what kind of resource this is. Value: the fixed
6734	// string "dfareporting#directorySiteContactsListResponse".
6735	Kind string `json:"kind,omitempty"`
6736
6737	// NextPageToken: Pagination token to be used for the next list
6738	// operation.
6739	NextPageToken string `json:"nextPageToken,omitempty"`
6740
6741	// ServerResponse contains the HTTP response code and headers from the
6742	// server.
6743	googleapi.ServerResponse `json:"-"`
6744
6745	// ForceSendFields is a list of field names (e.g.
6746	// "DirectorySiteContacts") to unconditionally include in API requests.
6747	// By default, fields with empty values are omitted from API requests.
6748	// However, any non-pointer, non-interface field appearing in
6749	// ForceSendFields will be sent to the server regardless of whether the
6750	// field is empty or not. This may be used to include empty fields in
6751	// Patch requests.
6752	ForceSendFields []string `json:"-"`
6753
6754	// NullFields is a list of field names (e.g. "DirectorySiteContacts") to
6755	// include in API requests with the JSON null value. By default, fields
6756	// with empty values are omitted from API requests. However, any field
6757	// with an empty value appearing in NullFields will be sent to the
6758	// server as null. It is an error if a field in this list has a
6759	// non-empty value. This may be used to include null fields in Patch
6760	// requests.
6761	NullFields []string `json:"-"`
6762}
6763
6764func (s *DirectorySiteContactsListResponse) MarshalJSON() ([]byte, error) {
6765	type NoMethod DirectorySiteContactsListResponse
6766	raw := NoMethod(*s)
6767	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6768}
6769
6770// DirectorySiteSettings: Directory Site Settings
6771type DirectorySiteSettings struct {
6772	// ActiveViewOptOut: Whether this directory site has disabled active
6773	// view creatives.
6774	ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
6775
6776	// DfpSettings: Directory site Ad Manager settings.
6777	DfpSettings *DfpSettings `json:"dfpSettings,omitempty"`
6778
6779	// InstreamVideoPlacementAccepted: Whether this site accepts in-stream
6780	// video ads.
6781	InstreamVideoPlacementAccepted bool `json:"instreamVideoPlacementAccepted,omitempty"`
6782
6783	// InterstitialPlacementAccepted: Whether this site accepts interstitial
6784	// ads.
6785	InterstitialPlacementAccepted bool `json:"interstitialPlacementAccepted,omitempty"`
6786
6787	// NielsenOcrOptOut: Whether this directory site has disabled Nielsen
6788	// OCR reach ratings.
6789	NielsenOcrOptOut bool `json:"nielsenOcrOptOut,omitempty"`
6790
6791	// VerificationTagOptOut: Whether this directory site has disabled
6792	// generation of Verification ins tags.
6793	VerificationTagOptOut bool `json:"verificationTagOptOut,omitempty"`
6794
6795	// VideoActiveViewOptOut: Whether this directory site has disabled
6796	// active view for in-stream video creatives. This is a read-only field.
6797	VideoActiveViewOptOut bool `json:"videoActiveViewOptOut,omitempty"`
6798
6799	// ForceSendFields is a list of field names (e.g. "ActiveViewOptOut") to
6800	// unconditionally include in API requests. By default, fields with
6801	// empty values are omitted from API requests. However, any non-pointer,
6802	// non-interface field appearing in ForceSendFields will be sent to the
6803	// server regardless of whether the field is empty or not. This may be
6804	// used to include empty fields in Patch requests.
6805	ForceSendFields []string `json:"-"`
6806
6807	// NullFields is a list of field names (e.g. "ActiveViewOptOut") to
6808	// include in API requests with the JSON null value. By default, fields
6809	// with empty values are omitted from API requests. However, any field
6810	// with an empty value appearing in NullFields will be sent to the
6811	// server as null. It is an error if a field in this list has a
6812	// non-empty value. This may be used to include null fields in Patch
6813	// requests.
6814	NullFields []string `json:"-"`
6815}
6816
6817func (s *DirectorySiteSettings) MarshalJSON() ([]byte, error) {
6818	type NoMethod DirectorySiteSettings
6819	raw := NoMethod(*s)
6820	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6821}
6822
6823// DirectorySitesListResponse: Directory Site List Response
6824type DirectorySitesListResponse struct {
6825	// DirectorySites: Directory site collection.
6826	DirectorySites []*DirectorySite `json:"directorySites,omitempty"`
6827
6828	// Kind: Identifies what kind of resource this is. Value: the fixed
6829	// string "dfareporting#directorySitesListResponse".
6830	Kind string `json:"kind,omitempty"`
6831
6832	// NextPageToken: Pagination token to be used for the next list
6833	// operation.
6834	NextPageToken string `json:"nextPageToken,omitempty"`
6835
6836	// ServerResponse contains the HTTP response code and headers from the
6837	// server.
6838	googleapi.ServerResponse `json:"-"`
6839
6840	// ForceSendFields is a list of field names (e.g. "DirectorySites") to
6841	// unconditionally include in API requests. By default, fields with
6842	// empty values are omitted from API requests. However, any non-pointer,
6843	// non-interface field appearing in ForceSendFields will be sent to the
6844	// server regardless of whether the field is empty or not. This may be
6845	// used to include empty fields in Patch requests.
6846	ForceSendFields []string `json:"-"`
6847
6848	// NullFields is a list of field names (e.g. "DirectorySites") to
6849	// include in API requests with the JSON null value. By default, fields
6850	// with empty values are omitted from API requests. However, any field
6851	// with an empty value appearing in NullFields will be sent to the
6852	// server as null. It is an error if a field in this list has a
6853	// non-empty value. This may be used to include null fields in Patch
6854	// requests.
6855	NullFields []string `json:"-"`
6856}
6857
6858func (s *DirectorySitesListResponse) MarshalJSON() ([]byte, error) {
6859	type NoMethod DirectorySitesListResponse
6860	raw := NoMethod(*s)
6861	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6862}
6863
6864// DynamicTargetingKey: Contains properties of a dynamic targeting key.
6865// Dynamic targeting keys are unique, user-friendly labels, created at
6866// the advertiser level in DCM, that can be assigned to ads, creatives,
6867// and placements and used for targeting with Studio dynamic creatives.
6868// Use these labels instead of numeric Campaign Manager IDs (such as
6869// placement IDs) to save time and avoid errors in your dynamic feeds.
6870type DynamicTargetingKey struct {
6871	// Kind: Identifies what kind of resource this is. Value: the fixed
6872	// string "dfareporting#dynamicTargetingKey".
6873	Kind string `json:"kind,omitempty"`
6874
6875	// Name: Name of this dynamic targeting key. This is a required field.
6876	// Must be less than 256 characters long and cannot contain commas. All
6877	// characters are converted to lowercase.
6878	Name string `json:"name,omitempty"`
6879
6880	// ObjectId: ID of the object of this dynamic targeting key. This is a
6881	// required field.
6882	ObjectId int64 `json:"objectId,omitempty,string"`
6883
6884	// ObjectType: Type of the object of this dynamic targeting key. This is
6885	// a required field.
6886	//
6887	// Possible values:
6888	//   "OBJECT_AD"
6889	//   "OBJECT_ADVERTISER"
6890	//   "OBJECT_CREATIVE"
6891	//   "OBJECT_PLACEMENT"
6892	ObjectType string `json:"objectType,omitempty"`
6893
6894	// ServerResponse contains the HTTP response code and headers from the
6895	// server.
6896	googleapi.ServerResponse `json:"-"`
6897
6898	// ForceSendFields is a list of field names (e.g. "Kind") to
6899	// unconditionally include in API requests. By default, fields with
6900	// empty values are omitted from API requests. However, any non-pointer,
6901	// non-interface field appearing in ForceSendFields will be sent to the
6902	// server regardless of whether the field is empty or not. This may be
6903	// used to include empty fields in Patch requests.
6904	ForceSendFields []string `json:"-"`
6905
6906	// NullFields is a list of field names (e.g. "Kind") to include in API
6907	// requests with the JSON null value. By default, fields with empty
6908	// values are omitted from API requests. However, any field with an
6909	// empty value appearing in NullFields will be sent to the server as
6910	// null. It is an error if a field in this list has a non-empty value.
6911	// This may be used to include null fields in Patch requests.
6912	NullFields []string `json:"-"`
6913}
6914
6915func (s *DynamicTargetingKey) MarshalJSON() ([]byte, error) {
6916	type NoMethod DynamicTargetingKey
6917	raw := NoMethod(*s)
6918	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6919}
6920
6921// DynamicTargetingKeysListResponse: Dynamic Targeting Key List Response
6922type DynamicTargetingKeysListResponse struct {
6923	// DynamicTargetingKeys: Dynamic targeting key collection.
6924	DynamicTargetingKeys []*DynamicTargetingKey `json:"dynamicTargetingKeys,omitempty"`
6925
6926	// Kind: Identifies what kind of resource this is. Value: the fixed
6927	// string "dfareporting#dynamicTargetingKeysListResponse".
6928	Kind string `json:"kind,omitempty"`
6929
6930	// ServerResponse contains the HTTP response code and headers from the
6931	// server.
6932	googleapi.ServerResponse `json:"-"`
6933
6934	// ForceSendFields is a list of field names (e.g.
6935	// "DynamicTargetingKeys") to unconditionally include in API requests.
6936	// By default, fields with empty values are omitted from API requests.
6937	// However, any non-pointer, non-interface field appearing in
6938	// ForceSendFields will be sent to the server regardless of whether the
6939	// field is empty or not. This may be used to include empty fields in
6940	// Patch requests.
6941	ForceSendFields []string `json:"-"`
6942
6943	// NullFields is a list of field names (e.g. "DynamicTargetingKeys") to
6944	// include in API requests with the JSON null value. By default, fields
6945	// with empty values are omitted from API requests. However, any field
6946	// with an empty value appearing in NullFields will be sent to the
6947	// server as null. It is an error if a field in this list has a
6948	// non-empty value. This may be used to include null fields in Patch
6949	// requests.
6950	NullFields []string `json:"-"`
6951}
6952
6953func (s *DynamicTargetingKeysListResponse) MarshalJSON() ([]byte, error) {
6954	type NoMethod DynamicTargetingKeysListResponse
6955	raw := NoMethod(*s)
6956	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6957}
6958
6959// EncryptionInfo: A description of how user IDs are encrypted.
6960type EncryptionInfo struct {
6961	// EncryptionEntityId: The encryption entity ID. This should match the
6962	// encryption configuration for ad serving or Data Transfer.
6963	EncryptionEntityId int64 `json:"encryptionEntityId,omitempty,string"`
6964
6965	// EncryptionEntityType: The encryption entity type. This should match
6966	// the encryption configuration for ad serving or Data Transfer.
6967	//
6968	// Possible values:
6969	//   "ADWORDS_CUSTOMER"
6970	//   "DBM_ADVERTISER"
6971	//   "DBM_PARTNER"
6972	//   "DCM_ACCOUNT"
6973	//   "DCM_ADVERTISER"
6974	//   "DFP_NETWORK_CODE"
6975	//   "ENCRYPTION_ENTITY_TYPE_UNKNOWN"
6976	EncryptionEntityType string `json:"encryptionEntityType,omitempty"`
6977
6978	// EncryptionSource: Describes whether the encrypted cookie was received
6979	// from ad serving (the %m macro) or from Data Transfer.
6980	//
6981	// Possible values:
6982	//   "AD_SERVING"
6983	//   "DATA_TRANSFER"
6984	//   "ENCRYPTION_SCOPE_UNKNOWN"
6985	EncryptionSource string `json:"encryptionSource,omitempty"`
6986
6987	// Kind: Identifies what kind of resource this is. Value: the fixed
6988	// string "dfareporting#encryptionInfo".
6989	Kind string `json:"kind,omitempty"`
6990
6991	// ForceSendFields is a list of field names (e.g. "EncryptionEntityId")
6992	// to unconditionally include in API requests. By default, fields with
6993	// empty values are omitted from API requests. However, any non-pointer,
6994	// non-interface field appearing in ForceSendFields will be sent to the
6995	// server regardless of whether the field is empty or not. This may be
6996	// used to include empty fields in Patch requests.
6997	ForceSendFields []string `json:"-"`
6998
6999	// NullFields is a list of field names (e.g. "EncryptionEntityId") to
7000	// include in API requests with the JSON null value. By default, fields
7001	// with empty values are omitted from API requests. However, any field
7002	// with an empty value appearing in NullFields will be sent to the
7003	// server as null. It is an error if a field in this list has a
7004	// non-empty value. This may be used to include null fields in Patch
7005	// requests.
7006	NullFields []string `json:"-"`
7007}
7008
7009func (s *EncryptionInfo) MarshalJSON() ([]byte, error) {
7010	type NoMethod EncryptionInfo
7011	raw := NoMethod(*s)
7012	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7013}
7014
7015// EventTag: Contains properties of an event tag.
7016type EventTag struct {
7017	// AccountId: Account ID of this event tag. This is a read-only field
7018	// that can be left blank.
7019	AccountId int64 `json:"accountId,omitempty,string"`
7020
7021	// AdvertiserId: Advertiser ID of this event tag. This field or the
7022	// campaignId field is required on insertion.
7023	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7024
7025	// AdvertiserIdDimensionValue: Dimension value for the ID of the
7026	// advertiser. This is a read-only, auto-generated field.
7027	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7028
7029	// CampaignId: Campaign ID of this event tag. This field or the
7030	// advertiserId field is required on insertion.
7031	CampaignId int64 `json:"campaignId,omitempty,string"`
7032
7033	// CampaignIdDimensionValue: Dimension value for the ID of the campaign.
7034	// This is a read-only, auto-generated field.
7035	CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
7036
7037	// EnabledByDefault: Whether this event tag should be automatically
7038	// enabled for all of the advertiser's campaigns and ads.
7039	EnabledByDefault bool `json:"enabledByDefault,omitempty"`
7040
7041	// ExcludeFromAdxRequests: Whether to remove this event tag from ads
7042	// that are trafficked through Display & Video 360 to Ad Exchange. This
7043	// may be useful if the event tag uses a pixel that is unapproved for Ad
7044	// Exchange bids on one or more networks, such as the Google Display
7045	// Network.
7046	ExcludeFromAdxRequests bool `json:"excludeFromAdxRequests,omitempty"`
7047
7048	// Id: ID of this event tag. This is a read-only, auto-generated field.
7049	Id int64 `json:"id,omitempty,string"`
7050
7051	// Kind: Identifies what kind of resource this is. Value: the fixed
7052	// string "dfareporting#eventTag".
7053	Kind string `json:"kind,omitempty"`
7054
7055	// Name: Name of this event tag. This is a required field and must be
7056	// less than 256 characters long.
7057	Name string `json:"name,omitempty"`
7058
7059	// SiteFilterType: Site filter type for this event tag. If no type is
7060	// specified then the event tag will be applied to all sites.
7061	//
7062	// Possible values:
7063	//   "BLACKLIST"
7064	//   "WHITELIST"
7065	SiteFilterType string `json:"siteFilterType,omitempty"`
7066
7067	// SiteIds: Filter list of site IDs associated with this event tag. The
7068	// siteFilterType determines whether this is a whitelist or blacklist
7069	// filter.
7070	SiteIds googleapi.Int64s `json:"siteIds,omitempty"`
7071
7072	// SslCompliant: Whether this tag is SSL-compliant or not. This is a
7073	// read-only field.
7074	SslCompliant bool `json:"sslCompliant,omitempty"`
7075
7076	// Status: Status of this event tag. Must be ENABLED for this event tag
7077	// to fire. This is a required field.
7078	//
7079	// Possible values:
7080	//   "DISABLED"
7081	//   "ENABLED"
7082	Status string `json:"status,omitempty"`
7083
7084	// SubaccountId: Subaccount ID of this event tag. This is a read-only
7085	// field that can be left blank.
7086	SubaccountId int64 `json:"subaccountId,omitempty,string"`
7087
7088	// Type: Event tag type. Can be used to specify whether to use a
7089	// third-party pixel, a third-party JavaScript URL, or a third-party
7090	// click-through URL for either impression or click tracking. This is a
7091	// required field.
7092	//
7093	// Possible values:
7094	//   "CLICK_THROUGH_EVENT_TAG"
7095	//   "IMPRESSION_IMAGE_EVENT_TAG"
7096	//   "IMPRESSION_JAVASCRIPT_EVENT_TAG"
7097	Type string `json:"type,omitempty"`
7098
7099	// Url: Payload URL for this event tag. The URL on a click-through event
7100	// tag should have a landing page URL appended to the end of it. This
7101	// field is required on insertion.
7102	Url string `json:"url,omitempty"`
7103
7104	// UrlEscapeLevels: Number of times the landing page URL should be
7105	// URL-escaped before being appended to the click-through event tag URL.
7106	// Only applies to click-through event tags as specified by the event
7107	// tag type.
7108	UrlEscapeLevels int64 `json:"urlEscapeLevels,omitempty"`
7109
7110	// ServerResponse contains the HTTP response code and headers from the
7111	// server.
7112	googleapi.ServerResponse `json:"-"`
7113
7114	// ForceSendFields is a list of field names (e.g. "AccountId") to
7115	// unconditionally include in API requests. By default, fields with
7116	// empty values are omitted from API requests. However, any non-pointer,
7117	// non-interface field appearing in ForceSendFields will be sent to the
7118	// server regardless of whether the field is empty or not. This may be
7119	// used to include empty fields in Patch requests.
7120	ForceSendFields []string `json:"-"`
7121
7122	// NullFields is a list of field names (e.g. "AccountId") to include in
7123	// API requests with the JSON null value. By default, fields with empty
7124	// values are omitted from API requests. However, any field with an
7125	// empty value appearing in NullFields will be sent to the server as
7126	// null. It is an error if a field in this list has a non-empty value.
7127	// This may be used to include null fields in Patch requests.
7128	NullFields []string `json:"-"`
7129}
7130
7131func (s *EventTag) MarshalJSON() ([]byte, error) {
7132	type NoMethod EventTag
7133	raw := NoMethod(*s)
7134	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7135}
7136
7137// EventTagOverride: Event tag override information.
7138type EventTagOverride struct {
7139	// Enabled: Whether this override is enabled.
7140	Enabled bool `json:"enabled,omitempty"`
7141
7142	// Id: ID of this event tag override. This is a read-only,
7143	// auto-generated field.
7144	Id int64 `json:"id,omitempty,string"`
7145
7146	// ForceSendFields is a list of field names (e.g. "Enabled") to
7147	// unconditionally include in API requests. By default, fields with
7148	// empty values are omitted from API requests. However, any non-pointer,
7149	// non-interface field appearing in ForceSendFields will be sent to the
7150	// server regardless of whether the field is empty or not. This may be
7151	// used to include empty fields in Patch requests.
7152	ForceSendFields []string `json:"-"`
7153
7154	// NullFields is a list of field names (e.g. "Enabled") to include in
7155	// API requests with the JSON null value. By default, fields with empty
7156	// values are omitted from API requests. However, any field with an
7157	// empty value appearing in NullFields will be sent to the server as
7158	// null. It is an error if a field in this list has a non-empty value.
7159	// This may be used to include null fields in Patch requests.
7160	NullFields []string `json:"-"`
7161}
7162
7163func (s *EventTagOverride) MarshalJSON() ([]byte, error) {
7164	type NoMethod EventTagOverride
7165	raw := NoMethod(*s)
7166	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7167}
7168
7169// EventTagsListResponse: Event Tag List Response
7170type EventTagsListResponse struct {
7171	// EventTags: Event tag collection.
7172	EventTags []*EventTag `json:"eventTags,omitempty"`
7173
7174	// Kind: Identifies what kind of resource this is. Value: the fixed
7175	// string "dfareporting#eventTagsListResponse".
7176	Kind string `json:"kind,omitempty"`
7177
7178	// ServerResponse contains the HTTP response code and headers from the
7179	// server.
7180	googleapi.ServerResponse `json:"-"`
7181
7182	// ForceSendFields is a list of field names (e.g. "EventTags") to
7183	// unconditionally include in API requests. By default, fields with
7184	// empty values are omitted from API requests. However, any non-pointer,
7185	// non-interface field appearing in ForceSendFields will be sent to the
7186	// server regardless of whether the field is empty or not. This may be
7187	// used to include empty fields in Patch requests.
7188	ForceSendFields []string `json:"-"`
7189
7190	// NullFields is a list of field names (e.g. "EventTags") to include in
7191	// API requests with the JSON null value. By default, fields with empty
7192	// values are omitted from API requests. However, any field with an
7193	// empty value appearing in NullFields will be sent to the server as
7194	// null. It is an error if a field in this list has a non-empty value.
7195	// This may be used to include null fields in Patch requests.
7196	NullFields []string `json:"-"`
7197}
7198
7199func (s *EventTagsListResponse) MarshalJSON() ([]byte, error) {
7200	type NoMethod EventTagsListResponse
7201	raw := NoMethod(*s)
7202	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7203}
7204
7205// File: Represents a File resource. A file contains the metadata for a
7206// report run. It shows the status of the run and holds the URLs to the
7207// generated report data if the run is finished and the status is
7208// "REPORT_AVAILABLE".
7209type File struct {
7210	// DateRange: The date range for which the file has report data. The
7211	// date range will always be the absolute date range for which the
7212	// report is run.
7213	DateRange *DateRange `json:"dateRange,omitempty"`
7214
7215	// Etag: The eTag of this response for caching purposes.
7216	Etag string `json:"etag,omitempty"`
7217
7218	// FileName: The filename of the file.
7219	FileName string `json:"fileName,omitempty"`
7220
7221	// Format: The output format of the report. Only available once the file
7222	// is available.
7223	//
7224	// Possible values:
7225	//   "CSV"
7226	//   "EXCEL"
7227	Format string `json:"format,omitempty"`
7228
7229	// Id: The unique ID of this report file.
7230	Id int64 `json:"id,omitempty,string"`
7231
7232	// Kind: The kind of resource this is, in this case dfareporting#file.
7233	Kind string `json:"kind,omitempty"`
7234
7235	// LastModifiedTime: The timestamp in milliseconds since epoch when this
7236	// file was last modified.
7237	LastModifiedTime int64 `json:"lastModifiedTime,omitempty,string"`
7238
7239	// ReportId: The ID of the report this file was generated from.
7240	ReportId int64 `json:"reportId,omitempty,string"`
7241
7242	// Status: The status of the report file.
7243	//
7244	// Possible values:
7245	//   "CANCELLED"
7246	//   "FAILED"
7247	//   "PROCESSING"
7248	//   "REPORT_AVAILABLE"
7249	Status string `json:"status,omitempty"`
7250
7251	// Urls: The URLs where the completed report file can be downloaded.
7252	Urls *FileUrls `json:"urls,omitempty"`
7253
7254	// ServerResponse contains the HTTP response code and headers from the
7255	// server.
7256	googleapi.ServerResponse `json:"-"`
7257
7258	// ForceSendFields is a list of field names (e.g. "DateRange") to
7259	// unconditionally include in API requests. By default, fields with
7260	// empty values are omitted from API requests. However, any non-pointer,
7261	// non-interface field appearing in ForceSendFields will be sent to the
7262	// server regardless of whether the field is empty or not. This may be
7263	// used to include empty fields in Patch requests.
7264	ForceSendFields []string `json:"-"`
7265
7266	// NullFields is a list of field names (e.g. "DateRange") to include in
7267	// API requests with the JSON null value. By default, fields with empty
7268	// values are omitted from API requests. However, any field with an
7269	// empty value appearing in NullFields will be sent to the server as
7270	// null. It is an error if a field in this list has a non-empty value.
7271	// This may be used to include null fields in Patch requests.
7272	NullFields []string `json:"-"`
7273}
7274
7275func (s *File) MarshalJSON() ([]byte, error) {
7276	type NoMethod File
7277	raw := NoMethod(*s)
7278	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7279}
7280
7281// FileUrls: The URLs where the completed report file can be downloaded.
7282type FileUrls struct {
7283	// ApiUrl: The URL for downloading the report data through the API.
7284	ApiUrl string `json:"apiUrl,omitempty"`
7285
7286	// BrowserUrl: The URL for downloading the report data through a
7287	// browser.
7288	BrowserUrl string `json:"browserUrl,omitempty"`
7289
7290	// ForceSendFields is a list of field names (e.g. "ApiUrl") to
7291	// unconditionally include in API requests. By default, fields with
7292	// empty values are omitted from API requests. However, any non-pointer,
7293	// non-interface field appearing in ForceSendFields will be sent to the
7294	// server regardless of whether the field is empty or not. This may be
7295	// used to include empty fields in Patch requests.
7296	ForceSendFields []string `json:"-"`
7297
7298	// NullFields is a list of field names (e.g. "ApiUrl") to include in API
7299	// requests with the JSON null value. By default, fields with empty
7300	// values are omitted from API requests. However, any field with an
7301	// empty value appearing in NullFields will be sent to the server as
7302	// null. It is an error if a field in this list has a non-empty value.
7303	// This may be used to include null fields in Patch requests.
7304	NullFields []string `json:"-"`
7305}
7306
7307func (s *FileUrls) MarshalJSON() ([]byte, error) {
7308	type NoMethod FileUrls
7309	raw := NoMethod(*s)
7310	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7311}
7312
7313// FileList: Represents the list of File resources.
7314type FileList struct {
7315	// Etag: The eTag of this response for caching purposes.
7316	Etag string `json:"etag,omitempty"`
7317
7318	// Items: The files returned in this response.
7319	Items []*File `json:"items,omitempty"`
7320
7321	// Kind: The kind of list this is, in this case dfareporting#fileList.
7322	Kind string `json:"kind,omitempty"`
7323
7324	// NextPageToken: Continuation token used to page through files. To
7325	// retrieve the next page of results, set the next request's "pageToken"
7326	// to the value of this field. The page token is only valid for a
7327	// limited amount of time and should not be persisted.
7328	NextPageToken string `json:"nextPageToken,omitempty"`
7329
7330	// ServerResponse contains the HTTP response code and headers from the
7331	// server.
7332	googleapi.ServerResponse `json:"-"`
7333
7334	// ForceSendFields is a list of field names (e.g. "Etag") to
7335	// unconditionally include in API requests. By default, fields with
7336	// empty values are omitted from API requests. However, any non-pointer,
7337	// non-interface field appearing in ForceSendFields will be sent to the
7338	// server regardless of whether the field is empty or not. This may be
7339	// used to include empty fields in Patch requests.
7340	ForceSendFields []string `json:"-"`
7341
7342	// NullFields is a list of field names (e.g. "Etag") to include in API
7343	// requests with the JSON null value. By default, fields with empty
7344	// values are omitted from API requests. However, any field with an
7345	// empty value appearing in NullFields will be sent to the server as
7346	// null. It is an error if a field in this list has a non-empty value.
7347	// This may be used to include null fields in Patch requests.
7348	NullFields []string `json:"-"`
7349}
7350
7351func (s *FileList) MarshalJSON() ([]byte, error) {
7352	type NoMethod FileList
7353	raw := NoMethod(*s)
7354	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7355}
7356
7357// Flight: Flight
7358type Flight struct {
7359	// EndDate: Inventory item flight end date.
7360	EndDate string `json:"endDate,omitempty"`
7361
7362	// RateOrCost: Rate or cost of this flight.
7363	RateOrCost int64 `json:"rateOrCost,omitempty,string"`
7364
7365	// StartDate: Inventory item flight start date.
7366	StartDate string `json:"startDate,omitempty"`
7367
7368	// Units: Units of this flight.
7369	Units int64 `json:"units,omitempty,string"`
7370
7371	// ForceSendFields is a list of field names (e.g. "EndDate") to
7372	// unconditionally include in API requests. By default, fields with
7373	// empty values are omitted from API requests. However, any non-pointer,
7374	// non-interface field appearing in ForceSendFields will be sent to the
7375	// server regardless of whether the field is empty or not. This may be
7376	// used to include empty fields in Patch requests.
7377	ForceSendFields []string `json:"-"`
7378
7379	// NullFields is a list of field names (e.g. "EndDate") to include in
7380	// API requests with the JSON null value. By default, fields with empty
7381	// values are omitted from API requests. However, any field with an
7382	// empty value appearing in NullFields will be sent to the server as
7383	// null. It is an error if a field in this list has a non-empty value.
7384	// This may be used to include null fields in Patch requests.
7385	NullFields []string `json:"-"`
7386}
7387
7388func (s *Flight) MarshalJSON() ([]byte, error) {
7389	type NoMethod Flight
7390	raw := NoMethod(*s)
7391	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7392}
7393
7394// FloodlightActivitiesGenerateTagResponse: Floodlight Activity
7395// GenerateTag Response
7396type FloodlightActivitiesGenerateTagResponse struct {
7397	// FloodlightActivityTag: Generated tag for this Floodlight activity.
7398	// For global site tags, this is the event snippet.
7399	FloodlightActivityTag string `json:"floodlightActivityTag,omitempty"`
7400
7401	// GlobalSiteTagGlobalSnippet: The global snippet section of a global
7402	// site tag. The global site tag sets new cookies on your domain, which
7403	// will store a unique identifier for a user or the ad click that
7404	// brought the user to your site. Learn more.
7405	GlobalSiteTagGlobalSnippet string `json:"globalSiteTagGlobalSnippet,omitempty"`
7406
7407	// Kind: Identifies what kind of resource this is. Value: the fixed
7408	// string "dfareporting#floodlightActivitiesGenerateTagResponse".
7409	Kind string `json:"kind,omitempty"`
7410
7411	// ServerResponse contains the HTTP response code and headers from the
7412	// server.
7413	googleapi.ServerResponse `json:"-"`
7414
7415	// ForceSendFields is a list of field names (e.g.
7416	// "FloodlightActivityTag") to unconditionally include in API requests.
7417	// By default, fields with empty values are omitted from API requests.
7418	// However, any non-pointer, non-interface field appearing in
7419	// ForceSendFields will be sent to the server regardless of whether the
7420	// field is empty or not. This may be used to include empty fields in
7421	// Patch requests.
7422	ForceSendFields []string `json:"-"`
7423
7424	// NullFields is a list of field names (e.g. "FloodlightActivityTag") to
7425	// include in API requests with the JSON null value. By default, fields
7426	// with empty values are omitted from API requests. However, any field
7427	// with an empty value appearing in NullFields will be sent to the
7428	// server as null. It is an error if a field in this list has a
7429	// non-empty value. This may be used to include null fields in Patch
7430	// requests.
7431	NullFields []string `json:"-"`
7432}
7433
7434func (s *FloodlightActivitiesGenerateTagResponse) MarshalJSON() ([]byte, error) {
7435	type NoMethod FloodlightActivitiesGenerateTagResponse
7436	raw := NoMethod(*s)
7437	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7438}
7439
7440// FloodlightActivitiesListResponse: Floodlight Activity List Response
7441type FloodlightActivitiesListResponse struct {
7442	// FloodlightActivities: Floodlight activity collection.
7443	FloodlightActivities []*FloodlightActivity `json:"floodlightActivities,omitempty"`
7444
7445	// Kind: Identifies what kind of resource this is. Value: the fixed
7446	// string "dfareporting#floodlightActivitiesListResponse".
7447	Kind string `json:"kind,omitempty"`
7448
7449	// NextPageToken: Pagination token to be used for the next list
7450	// operation.
7451	NextPageToken string `json:"nextPageToken,omitempty"`
7452
7453	// ServerResponse contains the HTTP response code and headers from the
7454	// server.
7455	googleapi.ServerResponse `json:"-"`
7456
7457	// ForceSendFields is a list of field names (e.g.
7458	// "FloodlightActivities") to unconditionally include in API requests.
7459	// By default, fields with empty values are omitted from API requests.
7460	// However, any non-pointer, non-interface field appearing in
7461	// ForceSendFields will be sent to the server regardless of whether the
7462	// field is empty or not. This may be used to include empty fields in
7463	// Patch requests.
7464	ForceSendFields []string `json:"-"`
7465
7466	// NullFields is a list of field names (e.g. "FloodlightActivities") to
7467	// include in API requests with the JSON null value. By default, fields
7468	// with empty values are omitted from API requests. However, any field
7469	// with an empty value appearing in NullFields will be sent to the
7470	// server as null. It is an error if a field in this list has a
7471	// non-empty value. This may be used to include null fields in Patch
7472	// requests.
7473	NullFields []string `json:"-"`
7474}
7475
7476func (s *FloodlightActivitiesListResponse) MarshalJSON() ([]byte, error) {
7477	type NoMethod FloodlightActivitiesListResponse
7478	raw := NoMethod(*s)
7479	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7480}
7481
7482// FloodlightActivity: Contains properties of a Floodlight activity.
7483type FloodlightActivity struct {
7484	// AccountId: Account ID of this floodlight activity. This is a
7485	// read-only field that can be left blank.
7486	AccountId int64 `json:"accountId,omitempty,string"`
7487
7488	// AdvertiserId: Advertiser ID of this floodlight activity. If this
7489	// field is left blank, the value will be copied over either from the
7490	// activity group's advertiser or the existing activity's advertiser.
7491	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7492
7493	// AdvertiserIdDimensionValue: Dimension value for the ID of the
7494	// advertiser. This is a read-only, auto-generated field.
7495	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7496
7497	// CacheBustingType: Code type used for cache busting in the generated
7498	// tag. Applicable only when floodlightActivityGroupType is COUNTER and
7499	// countingMethod is STANDARD_COUNTING or UNIQUE_COUNTING.
7500	//
7501	// Possible values:
7502	//   "ACTIVE_SERVER_PAGE"
7503	//   "COLD_FUSION"
7504	//   "JAVASCRIPT"
7505	//   "JSP"
7506	//   "PHP"
7507	CacheBustingType string `json:"cacheBustingType,omitempty"`
7508
7509	// CountingMethod: Counting method for conversions for this floodlight
7510	// activity. This is a required field.
7511	//
7512	// Possible values:
7513	//   "ITEMS_SOLD_COUNTING"
7514	//   "SESSION_COUNTING"
7515	//   "STANDARD_COUNTING"
7516	//   "TRANSACTIONS_COUNTING"
7517	//   "UNIQUE_COUNTING"
7518	CountingMethod string `json:"countingMethod,omitempty"`
7519
7520	// DefaultTags: Dynamic floodlight tags.
7521	DefaultTags []*FloodlightActivityDynamicTag `json:"defaultTags,omitempty"`
7522
7523	// ExpectedUrl: URL where this tag will be deployed. If specified, must
7524	// be less than 256 characters long.
7525	ExpectedUrl string `json:"expectedUrl,omitempty"`
7526
7527	// FloodlightActivityGroupId: Floodlight activity group ID of this
7528	// floodlight activity. This is a required field.
7529	FloodlightActivityGroupId int64 `json:"floodlightActivityGroupId,omitempty,string"`
7530
7531	// FloodlightActivityGroupName: Name of the associated floodlight
7532	// activity group. This is a read-only field.
7533	FloodlightActivityGroupName string `json:"floodlightActivityGroupName,omitempty"`
7534
7535	// FloodlightActivityGroupTagString: Tag string of the associated
7536	// floodlight activity group. This is a read-only field.
7537	FloodlightActivityGroupTagString string `json:"floodlightActivityGroupTagString,omitempty"`
7538
7539	// FloodlightActivityGroupType: Type of the associated floodlight
7540	// activity group. This is a read-only field.
7541	//
7542	// Possible values:
7543	//   "COUNTER"
7544	//   "SALE"
7545	FloodlightActivityGroupType string `json:"floodlightActivityGroupType,omitempty"`
7546
7547	// FloodlightConfigurationId: Floodlight configuration ID of this
7548	// floodlight activity. If this field is left blank, the value will be
7549	// copied over either from the activity group's floodlight configuration
7550	// or from the existing activity's floodlight configuration.
7551	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
7552
7553	// FloodlightConfigurationIdDimensionValue: Dimension value for the ID
7554	// of the floodlight configuration. This is a read-only, auto-generated
7555	// field.
7556	FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
7557
7558	// FloodlightTagType: The type of Floodlight tag this activity will
7559	// generate. This is a required field.
7560	//
7561	// Possible values:
7562	//   "GLOBAL_SITE_TAG"
7563	//   "IFRAME"
7564	//   "IMAGE"
7565	FloodlightTagType string `json:"floodlightTagType,omitempty"`
7566
7567	// Hidden: Whether this activity is archived.
7568	Hidden bool `json:"hidden,omitempty"`
7569
7570	// Id: ID of this floodlight activity. This is a read-only,
7571	// auto-generated field.
7572	Id int64 `json:"id,omitempty,string"`
7573
7574	// IdDimensionValue: Dimension value for the ID of this floodlight
7575	// activity. This is a read-only, auto-generated field.
7576	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7577
7578	// Kind: Identifies what kind of resource this is. Value: the fixed
7579	// string "dfareporting#floodlightActivity".
7580	Kind string `json:"kind,omitempty"`
7581
7582	// Name: Name of this floodlight activity. This is a required field.
7583	// Must be less than 129 characters long and cannot contain quotes.
7584	Name string `json:"name,omitempty"`
7585
7586	// Notes: General notes or implementation instructions for the tag.
7587	Notes string `json:"notes,omitempty"`
7588
7589	// PublisherTags: Publisher dynamic floodlight tags.
7590	PublisherTags []*FloodlightActivityPublisherDynamicTag `json:"publisherTags,omitempty"`
7591
7592	// Secure: Whether this tag should use SSL.
7593	Secure bool `json:"secure,omitempty"`
7594
7595	// SslCompliant: Whether the floodlight activity is SSL-compliant. This
7596	// is a read-only field, its value detected by the system from the
7597	// floodlight tags.
7598	SslCompliant bool `json:"sslCompliant,omitempty"`
7599
7600	// SslRequired: Whether this floodlight activity must be SSL-compliant.
7601	SslRequired bool `json:"sslRequired,omitempty"`
7602
7603	// SubaccountId: Subaccount ID of this floodlight activity. This is a
7604	// read-only field that can be left blank.
7605	SubaccountId int64 `json:"subaccountId,omitempty,string"`
7606
7607	// TagFormat: Tag format type for the floodlight activity. If left
7608	// blank, the tag format will default to HTML.
7609	//
7610	// Possible values:
7611	//   "HTML"
7612	//   "XHTML"
7613	TagFormat string `json:"tagFormat,omitempty"`
7614
7615	// TagString: Value of the cat= parameter in the floodlight tag, which
7616	// the ad servers use to identify the activity. This is optional: if
7617	// empty, a new tag string will be generated for you. This string must
7618	// be 1 to 8 characters long, with valid characters being
7619	// [a-z][A-Z][0-9][-][ _ ]. This tag string must also be unique among
7620	// activities of the same activity group. This field is read-only after
7621	// insertion.
7622	TagString string `json:"tagString,omitempty"`
7623
7624	// UserDefinedVariableTypes: List of the user-defined variables used by
7625	// this conversion tag. These map to the "u[1-100]=" in the tags. Each
7626	// of these can have a user defined type.
7627	// Acceptable values are U1 to U100, inclusive.
7628	//
7629	// Possible values:
7630	//   "U1"
7631	//   "U10"
7632	//   "U100"
7633	//   "U11"
7634	//   "U12"
7635	//   "U13"
7636	//   "U14"
7637	//   "U15"
7638	//   "U16"
7639	//   "U17"
7640	//   "U18"
7641	//   "U19"
7642	//   "U2"
7643	//   "U20"
7644	//   "U21"
7645	//   "U22"
7646	//   "U23"
7647	//   "U24"
7648	//   "U25"
7649	//   "U26"
7650	//   "U27"
7651	//   "U28"
7652	//   "U29"
7653	//   "U3"
7654	//   "U30"
7655	//   "U31"
7656	//   "U32"
7657	//   "U33"
7658	//   "U34"
7659	//   "U35"
7660	//   "U36"
7661	//   "U37"
7662	//   "U38"
7663	//   "U39"
7664	//   "U4"
7665	//   "U40"
7666	//   "U41"
7667	//   "U42"
7668	//   "U43"
7669	//   "U44"
7670	//   "U45"
7671	//   "U46"
7672	//   "U47"
7673	//   "U48"
7674	//   "U49"
7675	//   "U5"
7676	//   "U50"
7677	//   "U51"
7678	//   "U52"
7679	//   "U53"
7680	//   "U54"
7681	//   "U55"
7682	//   "U56"
7683	//   "U57"
7684	//   "U58"
7685	//   "U59"
7686	//   "U6"
7687	//   "U60"
7688	//   "U61"
7689	//   "U62"
7690	//   "U63"
7691	//   "U64"
7692	//   "U65"
7693	//   "U66"
7694	//   "U67"
7695	//   "U68"
7696	//   "U69"
7697	//   "U7"
7698	//   "U70"
7699	//   "U71"
7700	//   "U72"
7701	//   "U73"
7702	//   "U74"
7703	//   "U75"
7704	//   "U76"
7705	//   "U77"
7706	//   "U78"
7707	//   "U79"
7708	//   "U8"
7709	//   "U80"
7710	//   "U81"
7711	//   "U82"
7712	//   "U83"
7713	//   "U84"
7714	//   "U85"
7715	//   "U86"
7716	//   "U87"
7717	//   "U88"
7718	//   "U89"
7719	//   "U9"
7720	//   "U90"
7721	//   "U91"
7722	//   "U92"
7723	//   "U93"
7724	//   "U94"
7725	//   "U95"
7726	//   "U96"
7727	//   "U97"
7728	//   "U98"
7729	//   "U99"
7730	UserDefinedVariableTypes []string `json:"userDefinedVariableTypes,omitempty"`
7731
7732	// ServerResponse contains the HTTP response code and headers from the
7733	// server.
7734	googleapi.ServerResponse `json:"-"`
7735
7736	// ForceSendFields is a list of field names (e.g. "AccountId") to
7737	// unconditionally include in API requests. By default, fields with
7738	// empty values are omitted from API requests. However, any non-pointer,
7739	// non-interface field appearing in ForceSendFields will be sent to the
7740	// server regardless of whether the field is empty or not. This may be
7741	// used to include empty fields in Patch requests.
7742	ForceSendFields []string `json:"-"`
7743
7744	// NullFields is a list of field names (e.g. "AccountId") to include in
7745	// API requests with the JSON null value. By default, fields with empty
7746	// values are omitted from API requests. However, any field with an
7747	// empty value appearing in NullFields will be sent to the server as
7748	// null. It is an error if a field in this list has a non-empty value.
7749	// This may be used to include null fields in Patch requests.
7750	NullFields []string `json:"-"`
7751}
7752
7753func (s *FloodlightActivity) MarshalJSON() ([]byte, error) {
7754	type NoMethod FloodlightActivity
7755	raw := NoMethod(*s)
7756	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7757}
7758
7759// FloodlightActivityDynamicTag: Dynamic Tag
7760type FloodlightActivityDynamicTag struct {
7761	// Id: ID of this dynamic tag. This is a read-only, auto-generated
7762	// field.
7763	Id int64 `json:"id,omitempty,string"`
7764
7765	// Name: Name of this tag.
7766	Name string `json:"name,omitempty"`
7767
7768	// Tag: Tag code.
7769	Tag string `json:"tag,omitempty"`
7770
7771	// ForceSendFields is a list of field names (e.g. "Id") to
7772	// unconditionally include in API requests. By default, fields with
7773	// empty values are omitted from API requests. However, any non-pointer,
7774	// non-interface field appearing in ForceSendFields will be sent to the
7775	// server regardless of whether the field is empty or not. This may be
7776	// used to include empty fields in Patch requests.
7777	ForceSendFields []string `json:"-"`
7778
7779	// NullFields is a list of field names (e.g. "Id") to include in API
7780	// requests with the JSON null value. By default, fields with empty
7781	// values are omitted from API requests. However, any field with an
7782	// empty value appearing in NullFields will be sent to the server as
7783	// null. It is an error if a field in this list has a non-empty value.
7784	// This may be used to include null fields in Patch requests.
7785	NullFields []string `json:"-"`
7786}
7787
7788func (s *FloodlightActivityDynamicTag) MarshalJSON() ([]byte, error) {
7789	type NoMethod FloodlightActivityDynamicTag
7790	raw := NoMethod(*s)
7791	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7792}
7793
7794// FloodlightActivityGroup: Contains properties of a Floodlight activity
7795// group.
7796type FloodlightActivityGroup struct {
7797	// AccountId: Account ID of this floodlight activity group. This is a
7798	// read-only field that can be left blank.
7799	AccountId int64 `json:"accountId,omitempty,string"`
7800
7801	// AdvertiserId: Advertiser ID of this floodlight activity group. If
7802	// this field is left blank, the value will be copied over either from
7803	// the floodlight configuration's advertiser or from the existing
7804	// activity group's advertiser.
7805	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7806
7807	// AdvertiserIdDimensionValue: Dimension value for the ID of the
7808	// advertiser. This is a read-only, auto-generated field.
7809	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7810
7811	// FloodlightConfigurationId: Floodlight configuration ID of this
7812	// floodlight activity group. This is a required field.
7813	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
7814
7815	// FloodlightConfigurationIdDimensionValue: Dimension value for the ID
7816	// of the floodlight configuration. This is a read-only, auto-generated
7817	// field.
7818	FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
7819
7820	// Id: ID of this floodlight activity group. This is a read-only,
7821	// auto-generated field.
7822	Id int64 `json:"id,omitempty,string"`
7823
7824	// IdDimensionValue: Dimension value for the ID of this floodlight
7825	// activity group. This is a read-only, auto-generated field.
7826	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7827
7828	// Kind: Identifies what kind of resource this is. Value: the fixed
7829	// string "dfareporting#floodlightActivityGroup".
7830	Kind string `json:"kind,omitempty"`
7831
7832	// Name: Name of this floodlight activity group. This is a required
7833	// field. Must be less than 65 characters long and cannot contain
7834	// quotes.
7835	Name string `json:"name,omitempty"`
7836
7837	// SubaccountId: Subaccount ID of this floodlight activity group. This
7838	// is a read-only field that can be left blank.
7839	SubaccountId int64 `json:"subaccountId,omitempty,string"`
7840
7841	// TagString: Value of the type= parameter in the floodlight tag, which
7842	// the ad servers use to identify the activity group that the activity
7843	// belongs to. This is optional: if empty, a new tag string will be
7844	// generated for you. This string must be 1 to 8 characters long, with
7845	// valid characters being [a-z][A-Z][0-9][-][ _ ]. This tag string must
7846	// also be unique among activity groups of the same floodlight
7847	// configuration. This field is read-only after insertion.
7848	TagString string `json:"tagString,omitempty"`
7849
7850	// Type: Type of the floodlight activity group. This is a required field
7851	// that is read-only after insertion.
7852	//
7853	// Possible values:
7854	//   "COUNTER"
7855	//   "SALE"
7856	Type string `json:"type,omitempty"`
7857
7858	// ServerResponse contains the HTTP response code and headers from the
7859	// server.
7860	googleapi.ServerResponse `json:"-"`
7861
7862	// ForceSendFields is a list of field names (e.g. "AccountId") to
7863	// unconditionally include in API requests. By default, fields with
7864	// empty values are omitted from API requests. However, any non-pointer,
7865	// non-interface field appearing in ForceSendFields will be sent to the
7866	// server regardless of whether the field is empty or not. This may be
7867	// used to include empty fields in Patch requests.
7868	ForceSendFields []string `json:"-"`
7869
7870	// NullFields is a list of field names (e.g. "AccountId") to include in
7871	// API requests with the JSON null value. By default, fields with empty
7872	// values are omitted from API requests. However, any field with an
7873	// empty value appearing in NullFields will be sent to the server as
7874	// null. It is an error if a field in this list has a non-empty value.
7875	// This may be used to include null fields in Patch requests.
7876	NullFields []string `json:"-"`
7877}
7878
7879func (s *FloodlightActivityGroup) MarshalJSON() ([]byte, error) {
7880	type NoMethod FloodlightActivityGroup
7881	raw := NoMethod(*s)
7882	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7883}
7884
7885// FloodlightActivityGroupsListResponse: Floodlight Activity Group List
7886// Response
7887type FloodlightActivityGroupsListResponse struct {
7888	// FloodlightActivityGroups: Floodlight activity group collection.
7889	FloodlightActivityGroups []*FloodlightActivityGroup `json:"floodlightActivityGroups,omitempty"`
7890
7891	// Kind: Identifies what kind of resource this is. Value: the fixed
7892	// string "dfareporting#floodlightActivityGroupsListResponse".
7893	Kind string `json:"kind,omitempty"`
7894
7895	// NextPageToken: Pagination token to be used for the next list
7896	// operation.
7897	NextPageToken string `json:"nextPageToken,omitempty"`
7898
7899	// ServerResponse contains the HTTP response code and headers from the
7900	// server.
7901	googleapi.ServerResponse `json:"-"`
7902
7903	// ForceSendFields is a list of field names (e.g.
7904	// "FloodlightActivityGroups") to unconditionally include in API
7905	// requests. By default, fields with empty values are omitted from API
7906	// requests. However, any non-pointer, non-interface field appearing in
7907	// ForceSendFields will be sent to the server regardless of whether the
7908	// field is empty or not. This may be used to include empty fields in
7909	// Patch requests.
7910	ForceSendFields []string `json:"-"`
7911
7912	// NullFields is a list of field names (e.g. "FloodlightActivityGroups")
7913	// to include in API requests with the JSON null value. By default,
7914	// fields with empty values are omitted from API requests. However, any
7915	// field with an empty value appearing in NullFields will be sent to the
7916	// server as null. It is an error if a field in this list has a
7917	// non-empty value. This may be used to include null fields in Patch
7918	// requests.
7919	NullFields []string `json:"-"`
7920}
7921
7922func (s *FloodlightActivityGroupsListResponse) MarshalJSON() ([]byte, error) {
7923	type NoMethod FloodlightActivityGroupsListResponse
7924	raw := NoMethod(*s)
7925	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7926}
7927
7928// FloodlightActivityPublisherDynamicTag: Publisher Dynamic Tag
7929type FloodlightActivityPublisherDynamicTag struct {
7930	// ClickThrough: Whether this tag is applicable only for click-throughs.
7931	ClickThrough bool `json:"clickThrough,omitempty"`
7932
7933	// DirectorySiteId: Directory site ID of this dynamic tag. This is a
7934	// write-only field that can be used as an alternative to the siteId
7935	// field. When this resource is retrieved, only the siteId field will be
7936	// populated.
7937	DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
7938
7939	// DynamicTag: Dynamic floodlight tag.
7940	DynamicTag *FloodlightActivityDynamicTag `json:"dynamicTag,omitempty"`
7941
7942	// SiteId: Site ID of this dynamic tag.
7943	SiteId int64 `json:"siteId,omitempty,string"`
7944
7945	// SiteIdDimensionValue: Dimension value for the ID of the site. This is
7946	// a read-only, auto-generated field.
7947	SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
7948
7949	// ViewThrough: Whether this tag is applicable only for view-throughs.
7950	ViewThrough bool `json:"viewThrough,omitempty"`
7951
7952	// ForceSendFields is a list of field names (e.g. "ClickThrough") to
7953	// unconditionally include in API requests. By default, fields with
7954	// empty values are omitted from API requests. However, any non-pointer,
7955	// non-interface field appearing in ForceSendFields will be sent to the
7956	// server regardless of whether the field is empty or not. This may be
7957	// used to include empty fields in Patch requests.
7958	ForceSendFields []string `json:"-"`
7959
7960	// NullFields is a list of field names (e.g. "ClickThrough") to include
7961	// in API requests with the JSON null value. By default, fields with
7962	// empty values are omitted from API requests. However, any field with
7963	// an empty value appearing in NullFields will be sent to the server as
7964	// null. It is an error if a field in this list has a non-empty value.
7965	// This may be used to include null fields in Patch requests.
7966	NullFields []string `json:"-"`
7967}
7968
7969func (s *FloodlightActivityPublisherDynamicTag) MarshalJSON() ([]byte, error) {
7970	type NoMethod FloodlightActivityPublisherDynamicTag
7971	raw := NoMethod(*s)
7972	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7973}
7974
7975// FloodlightConfiguration: Contains properties of a Floodlight
7976// configuration.
7977type FloodlightConfiguration struct {
7978	// AccountId: Account ID of this floodlight configuration. This is a
7979	// read-only field that can be left blank.
7980	AccountId int64 `json:"accountId,omitempty,string"`
7981
7982	// AdvertiserId: Advertiser ID of the parent advertiser of this
7983	// floodlight configuration.
7984	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7985
7986	// AdvertiserIdDimensionValue: Dimension value for the ID of the
7987	// advertiser. This is a read-only, auto-generated field.
7988	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7989
7990	// AnalyticsDataSharingEnabled: Whether advertiser data is shared with
7991	// Google Analytics.
7992	AnalyticsDataSharingEnabled bool `json:"analyticsDataSharingEnabled,omitempty"`
7993
7994	// ExposureToConversionEnabled: Whether the exposure-to-conversion
7995	// report is enabled. This report shows detailed pathway information on
7996	// up to 10 of the most recent ad exposures seen by a user before
7997	// converting.
7998	ExposureToConversionEnabled bool `json:"exposureToConversionEnabled,omitempty"`
7999
8000	// FirstDayOfWeek: Day that will be counted as the first day of the week
8001	// in reports. This is a required field.
8002	//
8003	// Possible values:
8004	//   "MONDAY"
8005	//   "SUNDAY"
8006	FirstDayOfWeek string `json:"firstDayOfWeek,omitempty"`
8007
8008	// Id: ID of this floodlight configuration. This is a read-only,
8009	// auto-generated field.
8010	Id int64 `json:"id,omitempty,string"`
8011
8012	// IdDimensionValue: Dimension value for the ID of this floodlight
8013	// configuration. This is a read-only, auto-generated field.
8014	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
8015
8016	// InAppAttributionTrackingEnabled: Whether in-app attribution tracking
8017	// is enabled.
8018	InAppAttributionTrackingEnabled bool `json:"inAppAttributionTrackingEnabled,omitempty"`
8019
8020	// Kind: Identifies what kind of resource this is. Value: the fixed
8021	// string "dfareporting#floodlightConfiguration".
8022	Kind string `json:"kind,omitempty"`
8023
8024	// LookbackConfiguration: Lookback window settings for this floodlight
8025	// configuration.
8026	LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
8027
8028	// NaturalSearchConversionAttributionOption: Types of attribution
8029	// options for natural search conversions.
8030	//
8031	// Possible values:
8032	//   "EXCLUDE_NATURAL_SEARCH_CONVERSION_ATTRIBUTION"
8033	//   "INCLUDE_NATURAL_SEARCH_CONVERSION_ATTRIBUTION"
8034	//   "INCLUDE_NATURAL_SEARCH_TIERED_CONVERSION_ATTRIBUTION"
8035	NaturalSearchConversionAttributionOption string `json:"naturalSearchConversionAttributionOption,omitempty"`
8036
8037	// OmnitureSettings: Settings for Campaign Manager Omniture integration.
8038	OmnitureSettings *OmnitureSettings `json:"omnitureSettings,omitempty"`
8039
8040	// SubaccountId: Subaccount ID of this floodlight configuration. This is
8041	// a read-only field that can be left blank.
8042	SubaccountId int64 `json:"subaccountId,omitempty,string"`
8043
8044	// TagSettings: Configuration settings for dynamic and image floodlight
8045	// tags.
8046	TagSettings *TagSettings `json:"tagSettings,omitempty"`
8047
8048	// ThirdPartyAuthenticationTokens: List of third-party authentication
8049	// tokens enabled for this configuration.
8050	ThirdPartyAuthenticationTokens []*ThirdPartyAuthenticationToken `json:"thirdPartyAuthenticationTokens,omitempty"`
8051
8052	// UserDefinedVariableConfigurations: List of user defined variables
8053	// enabled for this configuration.
8054	UserDefinedVariableConfigurations []*UserDefinedVariableConfiguration `json:"userDefinedVariableConfigurations,omitempty"`
8055
8056	// ServerResponse contains the HTTP response code and headers from the
8057	// server.
8058	googleapi.ServerResponse `json:"-"`
8059
8060	// ForceSendFields is a list of field names (e.g. "AccountId") to
8061	// unconditionally include in API requests. By default, fields with
8062	// empty values are omitted from API requests. However, any non-pointer,
8063	// non-interface field appearing in ForceSendFields will be sent to the
8064	// server regardless of whether the field is empty or not. This may be
8065	// used to include empty fields in Patch requests.
8066	ForceSendFields []string `json:"-"`
8067
8068	// NullFields is a list of field names (e.g. "AccountId") to include in
8069	// API requests with the JSON null value. By default, fields with empty
8070	// values are omitted from API requests. However, any field with an
8071	// empty value appearing in NullFields will be sent to the server as
8072	// null. It is an error if a field in this list has a non-empty value.
8073	// This may be used to include null fields in Patch requests.
8074	NullFields []string `json:"-"`
8075}
8076
8077func (s *FloodlightConfiguration) MarshalJSON() ([]byte, error) {
8078	type NoMethod FloodlightConfiguration
8079	raw := NoMethod(*s)
8080	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8081}
8082
8083// FloodlightConfigurationsListResponse: Floodlight Configuration List
8084// Response
8085type FloodlightConfigurationsListResponse struct {
8086	// FloodlightConfigurations: Floodlight configuration collection.
8087	FloodlightConfigurations []*FloodlightConfiguration `json:"floodlightConfigurations,omitempty"`
8088
8089	// Kind: Identifies what kind of resource this is. Value: the fixed
8090	// string "dfareporting#floodlightConfigurationsListResponse".
8091	Kind string `json:"kind,omitempty"`
8092
8093	// ServerResponse contains the HTTP response code and headers from the
8094	// server.
8095	googleapi.ServerResponse `json:"-"`
8096
8097	// ForceSendFields is a list of field names (e.g.
8098	// "FloodlightConfigurations") to unconditionally include in API
8099	// requests. By default, fields with empty values are omitted from API
8100	// requests. However, any non-pointer, non-interface field appearing in
8101	// ForceSendFields will be sent to the server regardless of whether the
8102	// field is empty or not. This may be used to include empty fields in
8103	// Patch requests.
8104	ForceSendFields []string `json:"-"`
8105
8106	// NullFields is a list of field names (e.g. "FloodlightConfigurations")
8107	// to include in API requests with the JSON null value. By default,
8108	// fields with empty values are omitted from API requests. However, any
8109	// field with an empty value appearing in NullFields will be sent to the
8110	// server as null. It is an error if a field in this list has a
8111	// non-empty value. This may be used to include null fields in Patch
8112	// requests.
8113	NullFields []string `json:"-"`
8114}
8115
8116func (s *FloodlightConfigurationsListResponse) MarshalJSON() ([]byte, error) {
8117	type NoMethod FloodlightConfigurationsListResponse
8118	raw := NoMethod(*s)
8119	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8120}
8121
8122// FloodlightReportCompatibleFields: Represents fields that are
8123// compatible to be selected for a report of type "FlOODLIGHT".
8124type FloodlightReportCompatibleFields struct {
8125	// DimensionFilters: Dimensions which are compatible to be selected in
8126	// the "dimensionFilters" section of the report.
8127	DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
8128
8129	// Dimensions: Dimensions which are compatible to be selected in the
8130	// "dimensions" section of the report.
8131	Dimensions []*Dimension `json:"dimensions,omitempty"`
8132
8133	// Kind: The kind of resource this is, in this case
8134	// dfareporting#floodlightReportCompatibleFields.
8135	Kind string `json:"kind,omitempty"`
8136
8137	// Metrics: Metrics which are compatible to be selected in the
8138	// "metricNames" section of the report.
8139	Metrics []*Metric `json:"metrics,omitempty"`
8140
8141	// ForceSendFields is a list of field names (e.g. "DimensionFilters") to
8142	// unconditionally include in API requests. By default, fields with
8143	// empty values are omitted from API requests. However, any non-pointer,
8144	// non-interface field appearing in ForceSendFields will be sent to the
8145	// server regardless of whether the field is empty or not. This may be
8146	// used to include empty fields in Patch requests.
8147	ForceSendFields []string `json:"-"`
8148
8149	// NullFields is a list of field names (e.g. "DimensionFilters") to
8150	// include in API requests with the JSON null value. By default, fields
8151	// with empty values are omitted from API requests. However, any field
8152	// with an empty value appearing in NullFields will be sent to the
8153	// server as null. It is an error if a field in this list has a
8154	// non-empty value. This may be used to include null fields in Patch
8155	// requests.
8156	NullFields []string `json:"-"`
8157}
8158
8159func (s *FloodlightReportCompatibleFields) MarshalJSON() ([]byte, error) {
8160	type NoMethod FloodlightReportCompatibleFields
8161	raw := NoMethod(*s)
8162	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8163}
8164
8165// FrequencyCap: Frequency Cap.
8166type FrequencyCap struct {
8167	// Duration: Duration of time, in seconds, for this frequency cap. The
8168	// maximum duration is 90 days. Acceptable values are 1 to 7776000,
8169	// inclusive.
8170	Duration int64 `json:"duration,omitempty,string"`
8171
8172	// Impressions: Number of times an individual user can be served the ad
8173	// within the specified duration. Acceptable values are 1 to 15,
8174	// inclusive.
8175	Impressions int64 `json:"impressions,omitempty,string"`
8176
8177	// ForceSendFields is a list of field names (e.g. "Duration") to
8178	// unconditionally include in API requests. By default, fields with
8179	// empty values are omitted from API requests. However, any non-pointer,
8180	// non-interface field appearing in ForceSendFields will be sent to the
8181	// server regardless of whether the field is empty or not. This may be
8182	// used to include empty fields in Patch requests.
8183	ForceSendFields []string `json:"-"`
8184
8185	// NullFields is a list of field names (e.g. "Duration") to include in
8186	// API requests with the JSON null value. By default, fields with empty
8187	// values are omitted from API requests. However, any field with an
8188	// empty value appearing in NullFields will be sent to the server as
8189	// null. It is an error if a field in this list has a non-empty value.
8190	// This may be used to include null fields in Patch requests.
8191	NullFields []string `json:"-"`
8192}
8193
8194func (s *FrequencyCap) MarshalJSON() ([]byte, error) {
8195	type NoMethod FrequencyCap
8196	raw := NoMethod(*s)
8197	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8198}
8199
8200// FsCommand: FsCommand.
8201type FsCommand struct {
8202	// Left: Distance from the left of the browser.Applicable when
8203	// positionOption is DISTANCE_FROM_TOP_LEFT_CORNER.
8204	Left int64 `json:"left,omitempty"`
8205
8206	// PositionOption: Position in the browser where the window will open.
8207	//
8208	// Possible values:
8209	//   "CENTERED"
8210	//   "DISTANCE_FROM_TOP_LEFT_CORNER"
8211	PositionOption string `json:"positionOption,omitempty"`
8212
8213	// Top: Distance from the top of the browser. Applicable when
8214	// positionOption is DISTANCE_FROM_TOP_LEFT_CORNER.
8215	Top int64 `json:"top,omitempty"`
8216
8217	// WindowHeight: Height of the window.
8218	WindowHeight int64 `json:"windowHeight,omitempty"`
8219
8220	// WindowWidth: Width of the window.
8221	WindowWidth int64 `json:"windowWidth,omitempty"`
8222
8223	// ForceSendFields is a list of field names (e.g. "Left") to
8224	// unconditionally include in API requests. By default, fields with
8225	// empty values are omitted from API requests. However, any non-pointer,
8226	// non-interface field appearing in ForceSendFields will be sent to the
8227	// server regardless of whether the field is empty or not. This may be
8228	// used to include empty fields in Patch requests.
8229	ForceSendFields []string `json:"-"`
8230
8231	// NullFields is a list of field names (e.g. "Left") to include in API
8232	// requests with the JSON null value. By default, fields with empty
8233	// values are omitted from API requests. However, any field with an
8234	// empty value appearing in NullFields will be sent to the server as
8235	// null. It is an error if a field in this list has a non-empty value.
8236	// This may be used to include null fields in Patch requests.
8237	NullFields []string `json:"-"`
8238}
8239
8240func (s *FsCommand) MarshalJSON() ([]byte, error) {
8241	type NoMethod FsCommand
8242	raw := NoMethod(*s)
8243	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8244}
8245
8246// GeoTargeting: Geographical Targeting.
8247type GeoTargeting struct {
8248	// Cities: Cities to be targeted. For each city only dartId is required.
8249	// The other fields are populated automatically when the ad is inserted
8250	// or updated. If targeting a city, do not target or exclude the country
8251	// of the city, and do not target the metro or region of the city.
8252	Cities []*City `json:"cities,omitempty"`
8253
8254	// Countries: Countries to be targeted or excluded from targeting,
8255	// depending on the setting of the excludeCountries field. For each
8256	// country only dartId is required. The other fields are populated
8257	// automatically when the ad is inserted or updated. If targeting or
8258	// excluding a country, do not target regions, cities, metros, or postal
8259	// codes in the same country.
8260	Countries []*Country `json:"countries,omitempty"`
8261
8262	// ExcludeCountries: Whether or not to exclude the countries in the
8263	// countries field from targeting. If false, the countries field refers
8264	// to countries which will be targeted by the ad.
8265	ExcludeCountries bool `json:"excludeCountries,omitempty"`
8266
8267	// Metros: Metros to be targeted. For each metro only dmaId is required.
8268	// The other fields are populated automatically when the ad is inserted
8269	// or updated. If targeting a metro, do not target or exclude the
8270	// country of the metro.
8271	Metros []*Metro `json:"metros,omitempty"`
8272
8273	// PostalCodes: Postal codes to be targeted. For each postal code only
8274	// id is required. The other fields are populated automatically when the
8275	// ad is inserted or updated. If targeting a postal code, do not target
8276	// or exclude the country of the postal code.
8277	PostalCodes []*PostalCode `json:"postalCodes,omitempty"`
8278
8279	// Regions: Regions to be targeted. For each region only dartId is
8280	// required. The other fields are populated automatically when the ad is
8281	// inserted or updated. If targeting a region, do not target or exclude
8282	// the country of the region.
8283	Regions []*Region `json:"regions,omitempty"`
8284
8285	// ForceSendFields is a list of field names (e.g. "Cities") to
8286	// unconditionally include in API requests. By default, fields with
8287	// empty values are omitted from API requests. However, any non-pointer,
8288	// non-interface field appearing in ForceSendFields will be sent to the
8289	// server regardless of whether the field is empty or not. This may be
8290	// used to include empty fields in Patch requests.
8291	ForceSendFields []string `json:"-"`
8292
8293	// NullFields is a list of field names (e.g. "Cities") to include in API
8294	// requests with the JSON null value. By default, fields with empty
8295	// values are omitted from API requests. However, any field with an
8296	// empty value appearing in NullFields will be sent to the server as
8297	// null. It is an error if a field in this list has a non-empty value.
8298	// This may be used to include null fields in Patch requests.
8299	NullFields []string `json:"-"`
8300}
8301
8302func (s *GeoTargeting) MarshalJSON() ([]byte, error) {
8303	type NoMethod GeoTargeting
8304	raw := NoMethod(*s)
8305	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8306}
8307
8308// InventoryItem: Represents a buy from the Planning inventory store.
8309type InventoryItem struct {
8310	// AccountId: Account ID of this inventory item.
8311	AccountId int64 `json:"accountId,omitempty,string"`
8312
8313	// AdSlots: Ad slots of this inventory item. If this inventory item
8314	// represents a standalone placement, there will be exactly one ad slot.
8315	// If this inventory item represents a placement group, there will be
8316	// more than one ad slot, each representing one child placement in that
8317	// placement group.
8318	AdSlots []*AdSlot `json:"adSlots,omitempty"`
8319
8320	// AdvertiserId: Advertiser ID of this inventory item.
8321	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8322
8323	// ContentCategoryId: Content category ID of this inventory item.
8324	ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
8325
8326	// EstimatedClickThroughRate: Estimated click-through rate of this
8327	// inventory item.
8328	EstimatedClickThroughRate int64 `json:"estimatedClickThroughRate,omitempty,string"`
8329
8330	// EstimatedConversionRate: Estimated conversion rate of this inventory
8331	// item.
8332	EstimatedConversionRate int64 `json:"estimatedConversionRate,omitempty,string"`
8333
8334	// Id: ID of this inventory item.
8335	Id int64 `json:"id,omitempty,string"`
8336
8337	// InPlan: Whether this inventory item is in plan.
8338	InPlan bool `json:"inPlan,omitempty"`
8339
8340	// Kind: Identifies what kind of resource this is. Value: the fixed
8341	// string "dfareporting#inventoryItem".
8342	Kind string `json:"kind,omitempty"`
8343
8344	// LastModifiedInfo: Information about the most recent modification of
8345	// this inventory item.
8346	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
8347
8348	// Name: Name of this inventory item. For standalone inventory items,
8349	// this is the same name as that of its only ad slot. For group
8350	// inventory items, this can differ from the name of any of its ad
8351	// slots.
8352	Name string `json:"name,omitempty"`
8353
8354	// NegotiationChannelId: Negotiation channel ID of this inventory item.
8355	NegotiationChannelId int64 `json:"negotiationChannelId,omitempty,string"`
8356
8357	// OrderId: Order ID of this inventory item.
8358	OrderId int64 `json:"orderId,omitempty,string"`
8359
8360	// PlacementStrategyId: Placement strategy ID of this inventory item.
8361	PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
8362
8363	// Pricing: Pricing of this inventory item.
8364	Pricing *Pricing `json:"pricing,omitempty"`
8365
8366	// ProjectId: Project ID of this inventory item.
8367	ProjectId int64 `json:"projectId,omitempty,string"`
8368
8369	// RfpId: RFP ID of this inventory item.
8370	RfpId int64 `json:"rfpId,omitempty,string"`
8371
8372	// SiteId: ID of the site this inventory item is associated with.
8373	SiteId int64 `json:"siteId,omitempty,string"`
8374
8375	// SubaccountId: Subaccount ID of this inventory item.
8376	SubaccountId int64 `json:"subaccountId,omitempty,string"`
8377
8378	// Type: Type of inventory item.
8379	//
8380	// Possible values:
8381	//   "PLANNING_PLACEMENT_TYPE_CREDIT"
8382	//   "PLANNING_PLACEMENT_TYPE_REGULAR"
8383	Type string `json:"type,omitempty"`
8384
8385	// ServerResponse contains the HTTP response code and headers from the
8386	// server.
8387	googleapi.ServerResponse `json:"-"`
8388
8389	// ForceSendFields is a list of field names (e.g. "AccountId") to
8390	// unconditionally include in API requests. By default, fields with
8391	// empty values are omitted from API requests. However, any non-pointer,
8392	// non-interface field appearing in ForceSendFields will be sent to the
8393	// server regardless of whether the field is empty or not. This may be
8394	// used to include empty fields in Patch requests.
8395	ForceSendFields []string `json:"-"`
8396
8397	// NullFields is a list of field names (e.g. "AccountId") to include in
8398	// API requests with the JSON null value. By default, fields with empty
8399	// values are omitted from API requests. However, any field with an
8400	// empty value appearing in NullFields will be sent to the server as
8401	// null. It is an error if a field in this list has a non-empty value.
8402	// This may be used to include null fields in Patch requests.
8403	NullFields []string `json:"-"`
8404}
8405
8406func (s *InventoryItem) MarshalJSON() ([]byte, error) {
8407	type NoMethod InventoryItem
8408	raw := NoMethod(*s)
8409	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8410}
8411
8412// InventoryItemsListResponse: Inventory item List Response
8413type InventoryItemsListResponse struct {
8414	// InventoryItems: Inventory item collection
8415	InventoryItems []*InventoryItem `json:"inventoryItems,omitempty"`
8416
8417	// Kind: Identifies what kind of resource this is. Value: the fixed
8418	// string "dfareporting#inventoryItemsListResponse".
8419	Kind string `json:"kind,omitempty"`
8420
8421	// NextPageToken: Pagination token to be used for the next list
8422	// operation.
8423	NextPageToken string `json:"nextPageToken,omitempty"`
8424
8425	// ServerResponse contains the HTTP response code and headers from the
8426	// server.
8427	googleapi.ServerResponse `json:"-"`
8428
8429	// ForceSendFields is a list of field names (e.g. "InventoryItems") to
8430	// unconditionally include in API requests. By default, fields with
8431	// empty values are omitted from API requests. However, any non-pointer,
8432	// non-interface field appearing in ForceSendFields will be sent to the
8433	// server regardless of whether the field is empty or not. This may be
8434	// used to include empty fields in Patch requests.
8435	ForceSendFields []string `json:"-"`
8436
8437	// NullFields is a list of field names (e.g. "InventoryItems") to
8438	// include in API requests with the JSON null value. By default, fields
8439	// with empty values are omitted from API requests. However, any field
8440	// with an empty value appearing in NullFields will be sent to the
8441	// server as null. It is an error if a field in this list has a
8442	// non-empty value. This may be used to include null fields in Patch
8443	// requests.
8444	NullFields []string `json:"-"`
8445}
8446
8447func (s *InventoryItemsListResponse) MarshalJSON() ([]byte, error) {
8448	type NoMethod InventoryItemsListResponse
8449	raw := NoMethod(*s)
8450	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8451}
8452
8453// KeyValueTargetingExpression: Key Value Targeting Expression.
8454type KeyValueTargetingExpression struct {
8455	// Expression: Keyword expression being targeted by the ad.
8456	Expression string `json:"expression,omitempty"`
8457
8458	// ForceSendFields is a list of field names (e.g. "Expression") to
8459	// unconditionally include in API requests. By default, fields with
8460	// empty values are omitted from API requests. However, any non-pointer,
8461	// non-interface field appearing in ForceSendFields will be sent to the
8462	// server regardless of whether the field is empty or not. This may be
8463	// used to include empty fields in Patch requests.
8464	ForceSendFields []string `json:"-"`
8465
8466	// NullFields is a list of field names (e.g. "Expression") to include in
8467	// API requests with the JSON null value. By default, fields with empty
8468	// values are omitted from API requests. However, any field with an
8469	// empty value appearing in NullFields will be sent to the server as
8470	// null. It is an error if a field in this list has a non-empty value.
8471	// This may be used to include null fields in Patch requests.
8472	NullFields []string `json:"-"`
8473}
8474
8475func (s *KeyValueTargetingExpression) MarshalJSON() ([]byte, error) {
8476	type NoMethod KeyValueTargetingExpression
8477	raw := NoMethod(*s)
8478	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8479}
8480
8481// LandingPage: Contains information about where a user's browser is
8482// taken after the user clicks an ad.
8483type LandingPage struct {
8484	// AdvertiserId: Advertiser ID of this landing page. This is a required
8485	// field.
8486	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8487
8488	// Archived: Whether this landing page has been archived.
8489	Archived bool `json:"archived,omitempty"`
8490
8491	// DeepLinks: Links that will direct the user to a mobile app, if
8492	// installed.
8493	DeepLinks []*DeepLink `json:"deepLinks,omitempty"`
8494
8495	// Id: ID of this landing page. This is a read-only, auto-generated
8496	// field.
8497	Id int64 `json:"id,omitempty,string"`
8498
8499	// Kind: Identifies what kind of resource this is. Value: the fixed
8500	// string "dfareporting#landingPage".
8501	Kind string `json:"kind,omitempty"`
8502
8503	// Name: Name of this landing page. This is a required field. It must be
8504	// less than 256 characters long.
8505	Name string `json:"name,omitempty"`
8506
8507	// Url: URL of this landing page. This is a required field.
8508	Url string `json:"url,omitempty"`
8509
8510	// ServerResponse contains the HTTP response code and headers from the
8511	// server.
8512	googleapi.ServerResponse `json:"-"`
8513
8514	// ForceSendFields is a list of field names (e.g. "AdvertiserId") to
8515	// unconditionally include in API requests. By default, fields with
8516	// empty values are omitted from API requests. However, any non-pointer,
8517	// non-interface field appearing in ForceSendFields will be sent to the
8518	// server regardless of whether the field is empty or not. This may be
8519	// used to include empty fields in Patch requests.
8520	ForceSendFields []string `json:"-"`
8521
8522	// NullFields is a list of field names (e.g. "AdvertiserId") to include
8523	// in API requests with the JSON null value. By default, fields with
8524	// empty values are omitted from API requests. However, any field with
8525	// an empty value appearing in NullFields will be sent to the server as
8526	// null. It is an error if a field in this list has a non-empty value.
8527	// This may be used to include null fields in Patch requests.
8528	NullFields []string `json:"-"`
8529}
8530
8531func (s *LandingPage) MarshalJSON() ([]byte, error) {
8532	type NoMethod LandingPage
8533	raw := NoMethod(*s)
8534	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8535}
8536
8537// Language: Contains information about a language that can be targeted
8538// by ads.
8539type Language struct {
8540	// Id: Language ID of this language. This is the ID used for targeting
8541	// and generating reports.
8542	Id int64 `json:"id,omitempty,string"`
8543
8544	// Kind: Identifies what kind of resource this is. Value: the fixed
8545	// string "dfareporting#language".
8546	Kind string `json:"kind,omitempty"`
8547
8548	// LanguageCode: Format of language code is an ISO 639 two-letter
8549	// language code optionally followed by an underscore followed by an ISO
8550	// 3166 code. Examples are "en" for English or "zh_CN" for Simplified
8551	// Chinese.
8552	LanguageCode string `json:"languageCode,omitempty"`
8553
8554	// Name: Name of this language.
8555	Name string `json:"name,omitempty"`
8556
8557	// ForceSendFields is a list of field names (e.g. "Id") to
8558	// unconditionally include in API requests. By default, fields with
8559	// empty values are omitted from API requests. However, any non-pointer,
8560	// non-interface field appearing in ForceSendFields will be sent to the
8561	// server regardless of whether the field is empty or not. This may be
8562	// used to include empty fields in Patch requests.
8563	ForceSendFields []string `json:"-"`
8564
8565	// NullFields is a list of field names (e.g. "Id") to include in API
8566	// requests with the JSON null value. By default, fields with empty
8567	// values are omitted from API requests. However, any field with an
8568	// empty value appearing in NullFields will be sent to the server as
8569	// null. It is an error if a field in this list has a non-empty value.
8570	// This may be used to include null fields in Patch requests.
8571	NullFields []string `json:"-"`
8572}
8573
8574func (s *Language) MarshalJSON() ([]byte, error) {
8575	type NoMethod Language
8576	raw := NoMethod(*s)
8577	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8578}
8579
8580// LanguageTargeting: Language Targeting.
8581type LanguageTargeting struct {
8582	// Languages: Languages that this ad targets. For each language only
8583	// languageId is required. The other fields are populated automatically
8584	// when the ad is inserted or updated.
8585	Languages []*Language `json:"languages,omitempty"`
8586
8587	// ForceSendFields is a list of field names (e.g. "Languages") to
8588	// unconditionally include in API requests. By default, fields with
8589	// empty values are omitted from API requests. However, any non-pointer,
8590	// non-interface field appearing in ForceSendFields will be sent to the
8591	// server regardless of whether the field is empty or not. This may be
8592	// used to include empty fields in Patch requests.
8593	ForceSendFields []string `json:"-"`
8594
8595	// NullFields is a list of field names (e.g. "Languages") to include in
8596	// API requests with the JSON null value. By default, fields with empty
8597	// values are omitted from API requests. However, any field with an
8598	// empty value appearing in NullFields will be sent to the server as
8599	// null. It is an error if a field in this list has a non-empty value.
8600	// This may be used to include null fields in Patch requests.
8601	NullFields []string `json:"-"`
8602}
8603
8604func (s *LanguageTargeting) MarshalJSON() ([]byte, error) {
8605	type NoMethod LanguageTargeting
8606	raw := NoMethod(*s)
8607	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8608}
8609
8610// LanguagesListResponse: Language List Response
8611type LanguagesListResponse struct {
8612	// Kind: Identifies what kind of resource this is. Value: the fixed
8613	// string "dfareporting#languagesListResponse".
8614	Kind string `json:"kind,omitempty"`
8615
8616	// Languages: Language collection.
8617	Languages []*Language `json:"languages,omitempty"`
8618
8619	// ServerResponse contains the HTTP response code and headers from the
8620	// server.
8621	googleapi.ServerResponse `json:"-"`
8622
8623	// ForceSendFields is a list of field names (e.g. "Kind") to
8624	// unconditionally include in API requests. By default, fields with
8625	// empty values are omitted from API requests. However, any non-pointer,
8626	// non-interface field appearing in ForceSendFields will be sent to the
8627	// server regardless of whether the field is empty or not. This may be
8628	// used to include empty fields in Patch requests.
8629	ForceSendFields []string `json:"-"`
8630
8631	// NullFields is a list of field names (e.g. "Kind") to include in API
8632	// requests with the JSON null value. By default, fields with empty
8633	// values are omitted from API requests. However, any field with an
8634	// empty value appearing in NullFields will be sent to the server as
8635	// null. It is an error if a field in this list has a non-empty value.
8636	// This may be used to include null fields in Patch requests.
8637	NullFields []string `json:"-"`
8638}
8639
8640func (s *LanguagesListResponse) MarshalJSON() ([]byte, error) {
8641	type NoMethod LanguagesListResponse
8642	raw := NoMethod(*s)
8643	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8644}
8645
8646// LastModifiedInfo: Modification timestamp.
8647type LastModifiedInfo struct {
8648	// Time: Timestamp of the last change in milliseconds since epoch.
8649	Time int64 `json:"time,omitempty,string"`
8650
8651	// ForceSendFields is a list of field names (e.g. "Time") to
8652	// unconditionally include in API requests. By default, fields with
8653	// empty values are omitted from API requests. However, any non-pointer,
8654	// non-interface field appearing in ForceSendFields will be sent to the
8655	// server regardless of whether the field is empty or not. This may be
8656	// used to include empty fields in Patch requests.
8657	ForceSendFields []string `json:"-"`
8658
8659	// NullFields is a list of field names (e.g. "Time") to include in API
8660	// requests with the JSON null value. By default, fields with empty
8661	// values are omitted from API requests. However, any field with an
8662	// empty value appearing in NullFields will be sent to the server as
8663	// null. It is an error if a field in this list has a non-empty value.
8664	// This may be used to include null fields in Patch requests.
8665	NullFields []string `json:"-"`
8666}
8667
8668func (s *LastModifiedInfo) MarshalJSON() ([]byte, error) {
8669	type NoMethod LastModifiedInfo
8670	raw := NoMethod(*s)
8671	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8672}
8673
8674// ListPopulationClause: A group clause made up of list population terms
8675// representing constraints joined by ORs.
8676type ListPopulationClause struct {
8677	// Terms: Terms of this list population clause. Each clause is made up
8678	// of list population terms representing constraints and are joined by
8679	// ORs.
8680	Terms []*ListPopulationTerm `json:"terms,omitempty"`
8681
8682	// ForceSendFields is a list of field names (e.g. "Terms") to
8683	// unconditionally include in API requests. By default, fields with
8684	// empty values are omitted from API requests. However, any non-pointer,
8685	// non-interface field appearing in ForceSendFields will be sent to the
8686	// server regardless of whether the field is empty or not. This may be
8687	// used to include empty fields in Patch requests.
8688	ForceSendFields []string `json:"-"`
8689
8690	// NullFields is a list of field names (e.g. "Terms") to include in API
8691	// requests with the JSON null value. By default, fields with empty
8692	// values are omitted from API requests. However, any field with an
8693	// empty value appearing in NullFields will be sent to the server as
8694	// null. It is an error if a field in this list has a non-empty value.
8695	// This may be used to include null fields in Patch requests.
8696	NullFields []string `json:"-"`
8697}
8698
8699func (s *ListPopulationClause) MarshalJSON() ([]byte, error) {
8700	type NoMethod ListPopulationClause
8701	raw := NoMethod(*s)
8702	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8703}
8704
8705// ListPopulationRule: Remarketing List Population Rule.
8706type ListPopulationRule struct {
8707	// FloodlightActivityId: Floodlight activity ID associated with this
8708	// rule. This field can be left blank.
8709	FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
8710
8711	// FloodlightActivityName: Name of floodlight activity associated with
8712	// this rule. This is a read-only, auto-generated field.
8713	FloodlightActivityName string `json:"floodlightActivityName,omitempty"`
8714
8715	// ListPopulationClauses: Clauses that make up this list population
8716	// rule. Clauses are joined by ANDs, and the clauses themselves are made
8717	// up of list population terms which are joined by ORs.
8718	ListPopulationClauses []*ListPopulationClause `json:"listPopulationClauses,omitempty"`
8719
8720	// ForceSendFields is a list of field names (e.g.
8721	// "FloodlightActivityId") to unconditionally include in API requests.
8722	// By default, fields with empty values are omitted from API requests.
8723	// However, any non-pointer, non-interface field appearing in
8724	// ForceSendFields will be sent to the server regardless of whether the
8725	// field is empty or not. This may be used to include empty fields in
8726	// Patch requests.
8727	ForceSendFields []string `json:"-"`
8728
8729	// NullFields is a list of field names (e.g. "FloodlightActivityId") to
8730	// include in API requests with the JSON null value. By default, fields
8731	// with empty values are omitted from API requests. However, any field
8732	// with an empty value appearing in NullFields will be sent to the
8733	// server as null. It is an error if a field in this list has a
8734	// non-empty value. This may be used to include null fields in Patch
8735	// requests.
8736	NullFields []string `json:"-"`
8737}
8738
8739func (s *ListPopulationRule) MarshalJSON() ([]byte, error) {
8740	type NoMethod ListPopulationRule
8741	raw := NoMethod(*s)
8742	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8743}
8744
8745// ListPopulationTerm: Remarketing List Population Rule Term.
8746type ListPopulationTerm struct {
8747	// Contains: Will be true if the term should check if the user is in the
8748	// list and false if the term should check if the user is not in the
8749	// list. This field is only relevant when type is set to
8750	// LIST_MEMBERSHIP_TERM. False by default.
8751	Contains bool `json:"contains,omitempty"`
8752
8753	// Negation: Whether to negate the comparison result of this term during
8754	// rule evaluation. This field is only relevant when type is left unset
8755	// or set to CUSTOM_VARIABLE_TERM or REFERRER_TERM.
8756	Negation bool `json:"negation,omitempty"`
8757
8758	// Operator: Comparison operator of this term. This field is only
8759	// relevant when type is left unset or set to CUSTOM_VARIABLE_TERM or
8760	// REFERRER_TERM.
8761	//
8762	// Possible values:
8763	//   "NUM_EQUALS"
8764	//   "NUM_GREATER_THAN"
8765	//   "NUM_GREATER_THAN_EQUAL"
8766	//   "NUM_LESS_THAN"
8767	//   "NUM_LESS_THAN_EQUAL"
8768	//   "STRING_CONTAINS"
8769	//   "STRING_EQUALS"
8770	Operator string `json:"operator,omitempty"`
8771
8772	// RemarketingListId: ID of the list in question. This field is only
8773	// relevant when type is set to LIST_MEMBERSHIP_TERM.
8774	RemarketingListId int64 `json:"remarketingListId,omitempty,string"`
8775
8776	// Type: List population term type determines the applicable fields in
8777	// this object. If left unset or set to CUSTOM_VARIABLE_TERM, then
8778	// variableName, variableFriendlyName, operator, value, and negation are
8779	// applicable. If set to LIST_MEMBERSHIP_TERM then remarketingListId and
8780	// contains are applicable. If set to REFERRER_TERM then operator,
8781	// value, and negation are applicable.
8782	//
8783	// Possible values:
8784	//   "CUSTOM_VARIABLE_TERM"
8785	//   "LIST_MEMBERSHIP_TERM"
8786	//   "REFERRER_TERM"
8787	Type string `json:"type,omitempty"`
8788
8789	// Value: Literal to compare the variable to. This field is only
8790	// relevant when type is left unset or set to CUSTOM_VARIABLE_TERM or
8791	// REFERRER_TERM.
8792	Value string `json:"value,omitempty"`
8793
8794	// VariableFriendlyName: Friendly name of this term's variable. This is
8795	// a read-only, auto-generated field. This field is only relevant when
8796	// type is left unset or set to CUSTOM_VARIABLE_TERM.
8797	VariableFriendlyName string `json:"variableFriendlyName,omitempty"`
8798
8799	// VariableName: Name of the variable (U1, U2, etc.) being compared in
8800	// this term. This field is only relevant when type is set to null,
8801	// CUSTOM_VARIABLE_TERM or REFERRER_TERM.
8802	VariableName string `json:"variableName,omitempty"`
8803
8804	// ForceSendFields is a list of field names (e.g. "Contains") to
8805	// unconditionally include in API requests. By default, fields with
8806	// empty values are omitted from API requests. However, any non-pointer,
8807	// non-interface field appearing in ForceSendFields will be sent to the
8808	// server regardless of whether the field is empty or not. This may be
8809	// used to include empty fields in Patch requests.
8810	ForceSendFields []string `json:"-"`
8811
8812	// NullFields is a list of field names (e.g. "Contains") to include in
8813	// API requests with the JSON null value. By default, fields with empty
8814	// values are omitted from API requests. However, any field with an
8815	// empty value appearing in NullFields will be sent to the server as
8816	// null. It is an error if a field in this list has a non-empty value.
8817	// This may be used to include null fields in Patch requests.
8818	NullFields []string `json:"-"`
8819}
8820
8821func (s *ListPopulationTerm) MarshalJSON() ([]byte, error) {
8822	type NoMethod ListPopulationTerm
8823	raw := NoMethod(*s)
8824	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8825}
8826
8827// ListTargetingExpression: Remarketing List Targeting Expression.
8828type ListTargetingExpression struct {
8829	// Expression: Expression describing which lists are being targeted by
8830	// the ad.
8831	Expression string `json:"expression,omitempty"`
8832
8833	// ForceSendFields is a list of field names (e.g. "Expression") to
8834	// unconditionally include in API requests. By default, fields with
8835	// empty values are omitted from API requests. However, any non-pointer,
8836	// non-interface field appearing in ForceSendFields will be sent to the
8837	// server regardless of whether the field is empty or not. This may be
8838	// used to include empty fields in Patch requests.
8839	ForceSendFields []string `json:"-"`
8840
8841	// NullFields is a list of field names (e.g. "Expression") to include in
8842	// API requests with the JSON null value. By default, fields with empty
8843	// values are omitted from API requests. However, any field with an
8844	// empty value appearing in NullFields will be sent to the server as
8845	// null. It is an error if a field in this list has a non-empty value.
8846	// This may be used to include null fields in Patch requests.
8847	NullFields []string `json:"-"`
8848}
8849
8850func (s *ListTargetingExpression) MarshalJSON() ([]byte, error) {
8851	type NoMethod ListTargetingExpression
8852	raw := NoMethod(*s)
8853	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8854}
8855
8856// LookbackConfiguration: Lookback configuration settings.
8857type LookbackConfiguration struct {
8858	// ClickDuration: Lookback window, in days, from the last time a given
8859	// user clicked on one of your ads. If you enter 0, clicks will not be
8860	// considered as triggering events for floodlight tracking. If you leave
8861	// this field blank, the default value for your account will be used.
8862	// Acceptable values are 0 to 90, inclusive.
8863	ClickDuration int64 `json:"clickDuration,omitempty"`
8864
8865	// PostImpressionActivitiesDuration: Lookback window, in days, from the
8866	// last time a given user viewed one of your ads. If you enter 0,
8867	// impressions will not be considered as triggering events for
8868	// floodlight tracking. If you leave this field blank, the default value
8869	// for your account will be used. Acceptable values are 0 to 90,
8870	// inclusive.
8871	PostImpressionActivitiesDuration int64 `json:"postImpressionActivitiesDuration,omitempty"`
8872
8873	// ForceSendFields is a list of field names (e.g. "ClickDuration") to
8874	// unconditionally include in API requests. By default, fields with
8875	// empty values are omitted from API requests. However, any non-pointer,
8876	// non-interface field appearing in ForceSendFields will be sent to the
8877	// server regardless of whether the field is empty or not. This may be
8878	// used to include empty fields in Patch requests.
8879	ForceSendFields []string `json:"-"`
8880
8881	// NullFields is a list of field names (e.g. "ClickDuration") to include
8882	// in API requests with the JSON null value. By default, fields with
8883	// empty values are omitted from API requests. However, any field with
8884	// an empty value appearing in NullFields will be sent to the server as
8885	// null. It is an error if a field in this list has a non-empty value.
8886	// This may be used to include null fields in Patch requests.
8887	NullFields []string `json:"-"`
8888}
8889
8890func (s *LookbackConfiguration) MarshalJSON() ([]byte, error) {
8891	type NoMethod LookbackConfiguration
8892	raw := NoMethod(*s)
8893	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8894}
8895
8896// Metric: Represents a metric.
8897type Metric struct {
8898	// Kind: The kind of resource this is, in this case dfareporting#metric.
8899	Kind string `json:"kind,omitempty"`
8900
8901	// Name: The metric name, e.g. dfa:impressions
8902	Name string `json:"name,omitempty"`
8903
8904	// ForceSendFields is a list of field names (e.g. "Kind") to
8905	// unconditionally include in API requests. By default, fields with
8906	// empty values are omitted from API requests. However, any non-pointer,
8907	// non-interface field appearing in ForceSendFields will be sent to the
8908	// server regardless of whether the field is empty or not. This may be
8909	// used to include empty fields in Patch requests.
8910	ForceSendFields []string `json:"-"`
8911
8912	// NullFields is a list of field names (e.g. "Kind") to include in API
8913	// requests with the JSON null value. By default, fields with empty
8914	// values are omitted from API requests. However, any field with an
8915	// empty value appearing in NullFields will be sent to the server as
8916	// null. It is an error if a field in this list has a non-empty value.
8917	// This may be used to include null fields in Patch requests.
8918	NullFields []string `json:"-"`
8919}
8920
8921func (s *Metric) MarshalJSON() ([]byte, error) {
8922	type NoMethod Metric
8923	raw := NoMethod(*s)
8924	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8925}
8926
8927// Metro: Contains information about a metro region that can be targeted
8928// by ads.
8929type Metro struct {
8930	// CountryCode: Country code of the country to which this metro region
8931	// belongs.
8932	CountryCode string `json:"countryCode,omitempty"`
8933
8934	// CountryDartId: DART ID of the country to which this metro region
8935	// belongs.
8936	CountryDartId int64 `json:"countryDartId,omitempty,string"`
8937
8938	// DartId: DART ID of this metro region.
8939	DartId int64 `json:"dartId,omitempty,string"`
8940
8941	// DmaId: DMA ID of this metro region. This is the ID used for targeting
8942	// and generating reports, and is equivalent to metro_code.
8943	DmaId int64 `json:"dmaId,omitempty,string"`
8944
8945	// Kind: Identifies what kind of resource this is. Value: the fixed
8946	// string "dfareporting#metro".
8947	Kind string `json:"kind,omitempty"`
8948
8949	// MetroCode: Metro code of this metro region. This is equivalent to
8950	// dma_id.
8951	MetroCode string `json:"metroCode,omitempty"`
8952
8953	// Name: Name of this metro region.
8954	Name string `json:"name,omitempty"`
8955
8956	// ForceSendFields is a list of field names (e.g. "CountryCode") to
8957	// unconditionally include in API requests. By default, fields with
8958	// empty values are omitted from API requests. However, any non-pointer,
8959	// non-interface field appearing in ForceSendFields will be sent to the
8960	// server regardless of whether the field is empty or not. This may be
8961	// used to include empty fields in Patch requests.
8962	ForceSendFields []string `json:"-"`
8963
8964	// NullFields is a list of field names (e.g. "CountryCode") to include
8965	// in API requests with the JSON null value. By default, fields with
8966	// empty values are omitted from API requests. However, any field with
8967	// an empty value appearing in NullFields will be sent to the server as
8968	// null. It is an error if a field in this list has a non-empty value.
8969	// This may be used to include null fields in Patch requests.
8970	NullFields []string `json:"-"`
8971}
8972
8973func (s *Metro) MarshalJSON() ([]byte, error) {
8974	type NoMethod Metro
8975	raw := NoMethod(*s)
8976	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8977}
8978
8979// MetrosListResponse: Metro List Response
8980type MetrosListResponse struct {
8981	// Kind: Identifies what kind of resource this is. Value: the fixed
8982	// string "dfareporting#metrosListResponse".
8983	Kind string `json:"kind,omitempty"`
8984
8985	// Metros: Metro collection.
8986	Metros []*Metro `json:"metros,omitempty"`
8987
8988	// ServerResponse contains the HTTP response code and headers from the
8989	// server.
8990	googleapi.ServerResponse `json:"-"`
8991
8992	// ForceSendFields is a list of field names (e.g. "Kind") to
8993	// unconditionally include in API requests. By default, fields with
8994	// empty values are omitted from API requests. However, any non-pointer,
8995	// non-interface field appearing in ForceSendFields will be sent to the
8996	// server regardless of whether the field is empty or not. This may be
8997	// used to include empty fields in Patch requests.
8998	ForceSendFields []string `json:"-"`
8999
9000	// NullFields is a list of field names (e.g. "Kind") to include in API
9001	// requests with the JSON null value. By default, fields with empty
9002	// values are omitted from API requests. However, any field with an
9003	// empty value appearing in NullFields will be sent to the server as
9004	// null. It is an error if a field in this list has a non-empty value.
9005	// This may be used to include null fields in Patch requests.
9006	NullFields []string `json:"-"`
9007}
9008
9009func (s *MetrosListResponse) MarshalJSON() ([]byte, error) {
9010	type NoMethod MetrosListResponse
9011	raw := NoMethod(*s)
9012	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9013}
9014
9015// MobileApp: Contains information about a mobile app. Used as a landing
9016// page deep link.
9017type MobileApp struct {
9018	// Directory: Mobile app directory.
9019	//
9020	// Possible values:
9021	//   "APPLE_APP_STORE"
9022	//   "GOOGLE_PLAY_STORE"
9023	//   "UNKNOWN"
9024	Directory string `json:"directory,omitempty"`
9025
9026	// Id: ID of this mobile app.
9027	Id string `json:"id,omitempty"`
9028
9029	// Kind: Identifies what kind of resource this is. Value: the fixed
9030	// string "dfareporting#mobileApp".
9031	Kind string `json:"kind,omitempty"`
9032
9033	// PublisherName: Publisher name.
9034	PublisherName string `json:"publisherName,omitempty"`
9035
9036	// Title: Title of this mobile app.
9037	Title string `json:"title,omitempty"`
9038
9039	// ServerResponse contains the HTTP response code and headers from the
9040	// server.
9041	googleapi.ServerResponse `json:"-"`
9042
9043	// ForceSendFields is a list of field names (e.g. "Directory") to
9044	// unconditionally include in API requests. By default, fields with
9045	// empty values are omitted from API requests. However, any non-pointer,
9046	// non-interface field appearing in ForceSendFields will be sent to the
9047	// server regardless of whether the field is empty or not. This may be
9048	// used to include empty fields in Patch requests.
9049	ForceSendFields []string `json:"-"`
9050
9051	// NullFields is a list of field names (e.g. "Directory") to include in
9052	// API requests with the JSON null value. By default, fields with empty
9053	// values are omitted from API requests. However, any field with an
9054	// empty value appearing in NullFields will be sent to the server as
9055	// null. It is an error if a field in this list has a non-empty value.
9056	// This may be used to include null fields in Patch requests.
9057	NullFields []string `json:"-"`
9058}
9059
9060func (s *MobileApp) MarshalJSON() ([]byte, error) {
9061	type NoMethod MobileApp
9062	raw := NoMethod(*s)
9063	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9064}
9065
9066// MobileAppsListResponse: Mobile app List Response
9067type MobileAppsListResponse struct {
9068	// Kind: Identifies what kind of resource this is. Value: the fixed
9069	// string "dfareporting#mobileAppsListResponse".
9070	Kind string `json:"kind,omitempty"`
9071
9072	// MobileApps: Mobile apps collection.
9073	MobileApps []*MobileApp `json:"mobileApps,omitempty"`
9074
9075	// NextPageToken: Pagination token to be used for the next list
9076	// operation.
9077	NextPageToken string `json:"nextPageToken,omitempty"`
9078
9079	// ServerResponse contains the HTTP response code and headers from the
9080	// server.
9081	googleapi.ServerResponse `json:"-"`
9082
9083	// ForceSendFields is a list of field names (e.g. "Kind") to
9084	// unconditionally include in API requests. By default, fields with
9085	// empty values are omitted from API requests. However, any non-pointer,
9086	// non-interface field appearing in ForceSendFields will be sent to the
9087	// server regardless of whether the field is empty or not. This may be
9088	// used to include empty fields in Patch requests.
9089	ForceSendFields []string `json:"-"`
9090
9091	// NullFields is a list of field names (e.g. "Kind") to include in API
9092	// requests with the JSON null value. By default, fields with empty
9093	// values are omitted from API requests. However, any field with an
9094	// empty value appearing in NullFields will be sent to the server as
9095	// null. It is an error if a field in this list has a non-empty value.
9096	// This may be used to include null fields in Patch requests.
9097	NullFields []string `json:"-"`
9098}
9099
9100func (s *MobileAppsListResponse) MarshalJSON() ([]byte, error) {
9101	type NoMethod MobileAppsListResponse
9102	raw := NoMethod(*s)
9103	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9104}
9105
9106// MobileCarrier: Contains information about a mobile carrier that can
9107// be targeted by ads.
9108type MobileCarrier struct {
9109	// CountryCode: Country code of the country to which this mobile carrier
9110	// belongs.
9111	CountryCode string `json:"countryCode,omitempty"`
9112
9113	// CountryDartId: DART ID of the country to which this mobile carrier
9114	// belongs.
9115	CountryDartId int64 `json:"countryDartId,omitempty,string"`
9116
9117	// Id: ID of this mobile carrier.
9118	Id int64 `json:"id,omitempty,string"`
9119
9120	// Kind: Identifies what kind of resource this is. Value: the fixed
9121	// string "dfareporting#mobileCarrier".
9122	Kind string `json:"kind,omitempty"`
9123
9124	// Name: Name of this mobile carrier.
9125	Name string `json:"name,omitempty"`
9126
9127	// ServerResponse contains the HTTP response code and headers from the
9128	// server.
9129	googleapi.ServerResponse `json:"-"`
9130
9131	// ForceSendFields is a list of field names (e.g. "CountryCode") to
9132	// unconditionally include in API requests. By default, fields with
9133	// empty values are omitted from API requests. However, any non-pointer,
9134	// non-interface field appearing in ForceSendFields will be sent to the
9135	// server regardless of whether the field is empty or not. This may be
9136	// used to include empty fields in Patch requests.
9137	ForceSendFields []string `json:"-"`
9138
9139	// NullFields is a list of field names (e.g. "CountryCode") to include
9140	// in API requests with the JSON null value. By default, fields with
9141	// empty values are omitted from API requests. However, any field with
9142	// an empty value appearing in NullFields will be sent to the server as
9143	// null. It is an error if a field in this list has a non-empty value.
9144	// This may be used to include null fields in Patch requests.
9145	NullFields []string `json:"-"`
9146}
9147
9148func (s *MobileCarrier) MarshalJSON() ([]byte, error) {
9149	type NoMethod MobileCarrier
9150	raw := NoMethod(*s)
9151	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9152}
9153
9154// MobileCarriersListResponse: Mobile Carrier List Response
9155type MobileCarriersListResponse struct {
9156	// Kind: Identifies what kind of resource this is. Value: the fixed
9157	// string "dfareporting#mobileCarriersListResponse".
9158	Kind string `json:"kind,omitempty"`
9159
9160	// MobileCarriers: Mobile carrier collection.
9161	MobileCarriers []*MobileCarrier `json:"mobileCarriers,omitempty"`
9162
9163	// ServerResponse contains the HTTP response code and headers from the
9164	// server.
9165	googleapi.ServerResponse `json:"-"`
9166
9167	// ForceSendFields is a list of field names (e.g. "Kind") to
9168	// unconditionally include in API requests. By default, fields with
9169	// empty values are omitted from API requests. However, any non-pointer,
9170	// non-interface field appearing in ForceSendFields will be sent to the
9171	// server regardless of whether the field is empty or not. This may be
9172	// used to include empty fields in Patch requests.
9173	ForceSendFields []string `json:"-"`
9174
9175	// NullFields is a list of field names (e.g. "Kind") to include in API
9176	// requests with the JSON null value. By default, fields with empty
9177	// values are omitted from API requests. However, any field with an
9178	// empty value appearing in NullFields will be sent to the server as
9179	// null. It is an error if a field in this list has a non-empty value.
9180	// This may be used to include null fields in Patch requests.
9181	NullFields []string `json:"-"`
9182}
9183
9184func (s *MobileCarriersListResponse) MarshalJSON() ([]byte, error) {
9185	type NoMethod MobileCarriersListResponse
9186	raw := NoMethod(*s)
9187	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9188}
9189
9190// ObjectFilter: Object Filter.
9191type ObjectFilter struct {
9192	// Kind: Identifies what kind of resource this is. Value: the fixed
9193	// string "dfareporting#objectFilter".
9194	Kind string `json:"kind,omitempty"`
9195
9196	// ObjectIds: Applicable when status is ASSIGNED. The user has access to
9197	// objects with these object IDs.
9198	ObjectIds googleapi.Int64s `json:"objectIds,omitempty"`
9199
9200	// Status: Status of the filter. NONE means the user has access to none
9201	// of the objects. ALL means the user has access to all objects.
9202	// ASSIGNED means the user has access to the objects with IDs in the
9203	// objectIds list.
9204	//
9205	// Possible values:
9206	//   "ALL"
9207	//   "ASSIGNED"
9208	//   "NONE"
9209	Status string `json:"status,omitempty"`
9210
9211	// ForceSendFields is a list of field names (e.g. "Kind") to
9212	// unconditionally include in API requests. By default, fields with
9213	// empty values are omitted from API requests. However, any non-pointer,
9214	// non-interface field appearing in ForceSendFields will be sent to the
9215	// server regardless of whether the field is empty or not. This may be
9216	// used to include empty fields in Patch requests.
9217	ForceSendFields []string `json:"-"`
9218
9219	// NullFields is a list of field names (e.g. "Kind") to include in API
9220	// requests with the JSON null value. By default, fields with empty
9221	// values are omitted from API requests. However, any field with an
9222	// empty value appearing in NullFields will be sent to the server as
9223	// null. It is an error if a field in this list has a non-empty value.
9224	// This may be used to include null fields in Patch requests.
9225	NullFields []string `json:"-"`
9226}
9227
9228func (s *ObjectFilter) MarshalJSON() ([]byte, error) {
9229	type NoMethod ObjectFilter
9230	raw := NoMethod(*s)
9231	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9232}
9233
9234// OffsetPosition: Offset Position.
9235type OffsetPosition struct {
9236	// Left: Offset distance from left side of an asset or a window.
9237	Left int64 `json:"left,omitempty"`
9238
9239	// Top: Offset distance from top side of an asset or a window.
9240	Top int64 `json:"top,omitempty"`
9241
9242	// ForceSendFields is a list of field names (e.g. "Left") to
9243	// unconditionally include in API requests. By default, fields with
9244	// empty values are omitted from API requests. However, any non-pointer,
9245	// non-interface field appearing in ForceSendFields will be sent to the
9246	// server regardless of whether the field is empty or not. This may be
9247	// used to include empty fields in Patch requests.
9248	ForceSendFields []string `json:"-"`
9249
9250	// NullFields is a list of field names (e.g. "Left") to include in API
9251	// requests with the JSON null value. By default, fields with empty
9252	// values are omitted from API requests. However, any field with an
9253	// empty value appearing in NullFields will be sent to the server as
9254	// null. It is an error if a field in this list has a non-empty value.
9255	// This may be used to include null fields in Patch requests.
9256	NullFields []string `json:"-"`
9257}
9258
9259func (s *OffsetPosition) MarshalJSON() ([]byte, error) {
9260	type NoMethod OffsetPosition
9261	raw := NoMethod(*s)
9262	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9263}
9264
9265// OmnitureSettings: Omniture Integration Settings.
9266type OmnitureSettings struct {
9267	// OmnitureCostDataEnabled: Whether placement cost data will be sent to
9268	// Omniture. This property can be enabled only if
9269	// omnitureIntegrationEnabled is true.
9270	OmnitureCostDataEnabled bool `json:"omnitureCostDataEnabled,omitempty"`
9271
9272	// OmnitureIntegrationEnabled: Whether Omniture integration is enabled.
9273	// This property can be enabled only when the "Advanced Ad Serving"
9274	// account setting is enabled.
9275	OmnitureIntegrationEnabled bool `json:"omnitureIntegrationEnabled,omitempty"`
9276
9277	// ForceSendFields is a list of field names (e.g.
9278	// "OmnitureCostDataEnabled") to unconditionally include in API
9279	// requests. By default, fields with empty values are omitted from API
9280	// requests. However, any non-pointer, non-interface field appearing in
9281	// ForceSendFields will be sent to the server regardless of whether the
9282	// field is empty or not. This may be used to include empty fields in
9283	// Patch requests.
9284	ForceSendFields []string `json:"-"`
9285
9286	// NullFields is a list of field names (e.g. "OmnitureCostDataEnabled")
9287	// to include in API requests with the JSON null value. By default,
9288	// fields with empty values are omitted from API requests. However, any
9289	// field with an empty value appearing in NullFields will be sent to the
9290	// server as null. It is an error if a field in this list has a
9291	// non-empty value. This may be used to include null fields in Patch
9292	// requests.
9293	NullFields []string `json:"-"`
9294}
9295
9296func (s *OmnitureSettings) MarshalJSON() ([]byte, error) {
9297	type NoMethod OmnitureSettings
9298	raw := NoMethod(*s)
9299	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9300}
9301
9302// OperatingSystem: Contains information about an operating system that
9303// can be targeted by ads.
9304type OperatingSystem struct {
9305	// DartId: DART ID of this operating system. This is the ID used for
9306	// targeting.
9307	DartId int64 `json:"dartId,omitempty,string"`
9308
9309	// Desktop: Whether this operating system is for desktop.
9310	Desktop bool `json:"desktop,omitempty"`
9311
9312	// Kind: Identifies what kind of resource this is. Value: the fixed
9313	// string "dfareporting#operatingSystem".
9314	Kind string `json:"kind,omitempty"`
9315
9316	// Mobile: Whether this operating system is for mobile.
9317	Mobile bool `json:"mobile,omitempty"`
9318
9319	// Name: Name of this operating system.
9320	Name string `json:"name,omitempty"`
9321
9322	// ServerResponse contains the HTTP response code and headers from the
9323	// server.
9324	googleapi.ServerResponse `json:"-"`
9325
9326	// ForceSendFields is a list of field names (e.g. "DartId") to
9327	// unconditionally include in API requests. By default, fields with
9328	// empty values are omitted from API requests. However, any non-pointer,
9329	// non-interface field appearing in ForceSendFields will be sent to the
9330	// server regardless of whether the field is empty or not. This may be
9331	// used to include empty fields in Patch requests.
9332	ForceSendFields []string `json:"-"`
9333
9334	// NullFields is a list of field names (e.g. "DartId") to include in API
9335	// requests with the JSON null value. By default, fields with empty
9336	// values are omitted from API requests. However, any field with an
9337	// empty value appearing in NullFields will be sent to the server as
9338	// null. It is an error if a field in this list has a non-empty value.
9339	// This may be used to include null fields in Patch requests.
9340	NullFields []string `json:"-"`
9341}
9342
9343func (s *OperatingSystem) MarshalJSON() ([]byte, error) {
9344	type NoMethod OperatingSystem
9345	raw := NoMethod(*s)
9346	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9347}
9348
9349// OperatingSystemVersion: Contains information about a particular
9350// version of an operating system that can be targeted by ads.
9351type OperatingSystemVersion struct {
9352	// Id: ID of this operating system version.
9353	Id int64 `json:"id,omitempty,string"`
9354
9355	// Kind: Identifies what kind of resource this is. Value: the fixed
9356	// string "dfareporting#operatingSystemVersion".
9357	Kind string `json:"kind,omitempty"`
9358
9359	// MajorVersion: Major version (leftmost number) of this operating
9360	// system version.
9361	MajorVersion string `json:"majorVersion,omitempty"`
9362
9363	// MinorVersion: Minor version (number after the first dot) of this
9364	// operating system version.
9365	MinorVersion string `json:"minorVersion,omitempty"`
9366
9367	// Name: Name of this operating system version.
9368	Name string `json:"name,omitempty"`
9369
9370	// OperatingSystem: Operating system of this operating system version.
9371	OperatingSystem *OperatingSystem `json:"operatingSystem,omitempty"`
9372
9373	// ServerResponse contains the HTTP response code and headers from the
9374	// server.
9375	googleapi.ServerResponse `json:"-"`
9376
9377	// ForceSendFields is a list of field names (e.g. "Id") to
9378	// unconditionally include in API requests. By default, fields with
9379	// empty values are omitted from API requests. However, any non-pointer,
9380	// non-interface field appearing in ForceSendFields will be sent to the
9381	// server regardless of whether the field is empty or not. This may be
9382	// used to include empty fields in Patch requests.
9383	ForceSendFields []string `json:"-"`
9384
9385	// NullFields is a list of field names (e.g. "Id") to include in API
9386	// requests with the JSON null value. By default, fields with empty
9387	// values are omitted from API requests. However, any field with an
9388	// empty value appearing in NullFields will be sent to the server as
9389	// null. It is an error if a field in this list has a non-empty value.
9390	// This may be used to include null fields in Patch requests.
9391	NullFields []string `json:"-"`
9392}
9393
9394func (s *OperatingSystemVersion) MarshalJSON() ([]byte, error) {
9395	type NoMethod OperatingSystemVersion
9396	raw := NoMethod(*s)
9397	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9398}
9399
9400// OperatingSystemVersionsListResponse: Operating System Version List
9401// Response
9402type OperatingSystemVersionsListResponse struct {
9403	// Kind: Identifies what kind of resource this is. Value: the fixed
9404	// string "dfareporting#operatingSystemVersionsListResponse".
9405	Kind string `json:"kind,omitempty"`
9406
9407	// OperatingSystemVersions: Operating system version collection.
9408	OperatingSystemVersions []*OperatingSystemVersion `json:"operatingSystemVersions,omitempty"`
9409
9410	// ServerResponse contains the HTTP response code and headers from the
9411	// server.
9412	googleapi.ServerResponse `json:"-"`
9413
9414	// ForceSendFields is a list of field names (e.g. "Kind") to
9415	// unconditionally include in API requests. By default, fields with
9416	// empty values are omitted from API requests. However, any non-pointer,
9417	// non-interface field appearing in ForceSendFields will be sent to the
9418	// server regardless of whether the field is empty or not. This may be
9419	// used to include empty fields in Patch requests.
9420	ForceSendFields []string `json:"-"`
9421
9422	// NullFields is a list of field names (e.g. "Kind") to include in API
9423	// requests with the JSON null value. By default, fields with empty
9424	// values are omitted from API requests. However, any field with an
9425	// empty value appearing in NullFields will be sent to the server as
9426	// null. It is an error if a field in this list has a non-empty value.
9427	// This may be used to include null fields in Patch requests.
9428	NullFields []string `json:"-"`
9429}
9430
9431func (s *OperatingSystemVersionsListResponse) MarshalJSON() ([]byte, error) {
9432	type NoMethod OperatingSystemVersionsListResponse
9433	raw := NoMethod(*s)
9434	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9435}
9436
9437// OperatingSystemsListResponse: Operating System List Response
9438type OperatingSystemsListResponse struct {
9439	// Kind: Identifies what kind of resource this is. Value: the fixed
9440	// string "dfareporting#operatingSystemsListResponse".
9441	Kind string `json:"kind,omitempty"`
9442
9443	// OperatingSystems: Operating system collection.
9444	OperatingSystems []*OperatingSystem `json:"operatingSystems,omitempty"`
9445
9446	// ServerResponse contains the HTTP response code and headers from the
9447	// server.
9448	googleapi.ServerResponse `json:"-"`
9449
9450	// ForceSendFields is a list of field names (e.g. "Kind") to
9451	// unconditionally include in API requests. By default, fields with
9452	// empty values are omitted from API requests. However, any non-pointer,
9453	// non-interface field appearing in ForceSendFields will be sent to the
9454	// server regardless of whether the field is empty or not. This may be
9455	// used to include empty fields in Patch requests.
9456	ForceSendFields []string `json:"-"`
9457
9458	// NullFields is a list of field names (e.g. "Kind") to include in API
9459	// requests with the JSON null value. By default, fields with empty
9460	// values are omitted from API requests. However, any field with an
9461	// empty value appearing in NullFields will be sent to the server as
9462	// null. It is an error if a field in this list has a non-empty value.
9463	// This may be used to include null fields in Patch requests.
9464	NullFields []string `json:"-"`
9465}
9466
9467func (s *OperatingSystemsListResponse) MarshalJSON() ([]byte, error) {
9468	type NoMethod OperatingSystemsListResponse
9469	raw := NoMethod(*s)
9470	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9471}
9472
9473// OptimizationActivity: Creative optimization activity.
9474type OptimizationActivity struct {
9475	// FloodlightActivityId: Floodlight activity ID of this optimization
9476	// activity. This is a required field.
9477	FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
9478
9479	// FloodlightActivityIdDimensionValue: Dimension value for the ID of the
9480	// floodlight activity. This is a read-only, auto-generated field.
9481	FloodlightActivityIdDimensionValue *DimensionValue `json:"floodlightActivityIdDimensionValue,omitempty"`
9482
9483	// Weight: Weight associated with this optimization. The weight assigned
9484	// will be understood in proportion to the weights assigned to the other
9485	// optimization activities. Value must be greater than or equal to 1.
9486	Weight int64 `json:"weight,omitempty"`
9487
9488	// ForceSendFields is a list of field names (e.g.
9489	// "FloodlightActivityId") to unconditionally include in API requests.
9490	// By default, fields with empty values are omitted from API requests.
9491	// However, any non-pointer, non-interface field appearing in
9492	// ForceSendFields will be sent to the server regardless of whether the
9493	// field is empty or not. This may be used to include empty fields in
9494	// Patch requests.
9495	ForceSendFields []string `json:"-"`
9496
9497	// NullFields is a list of field names (e.g. "FloodlightActivityId") to
9498	// include in API requests with the JSON null value. By default, fields
9499	// with empty values are omitted from API requests. However, any field
9500	// with an empty value appearing in NullFields will be sent to the
9501	// server as null. It is an error if a field in this list has a
9502	// non-empty value. This may be used to include null fields in Patch
9503	// requests.
9504	NullFields []string `json:"-"`
9505}
9506
9507func (s *OptimizationActivity) MarshalJSON() ([]byte, error) {
9508	type NoMethod OptimizationActivity
9509	raw := NoMethod(*s)
9510	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9511}
9512
9513// Order: Describes properties of a Planning order.
9514type Order struct {
9515	// AccountId: Account ID of this order.
9516	AccountId int64 `json:"accountId,omitempty,string"`
9517
9518	// AdvertiserId: Advertiser ID of this order.
9519	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9520
9521	// ApproverUserProfileIds: IDs for users that have to approve documents
9522	// created for this order.
9523	ApproverUserProfileIds googleapi.Int64s `json:"approverUserProfileIds,omitempty"`
9524
9525	// BuyerInvoiceId: Buyer invoice ID associated with this order.
9526	BuyerInvoiceId string `json:"buyerInvoiceId,omitempty"`
9527
9528	// BuyerOrganizationName: Name of the buyer organization.
9529	BuyerOrganizationName string `json:"buyerOrganizationName,omitempty"`
9530
9531	// Comments: Comments in this order.
9532	Comments string `json:"comments,omitempty"`
9533
9534	// Contacts: Contacts for this order.
9535	Contacts []*OrderContact `json:"contacts,omitempty"`
9536
9537	// Id: ID of this order. This is a read-only, auto-generated field.
9538	Id int64 `json:"id,omitempty,string"`
9539
9540	// Kind: Identifies what kind of resource this is. Value: the fixed
9541	// string "dfareporting#order".
9542	Kind string `json:"kind,omitempty"`
9543
9544	// LastModifiedInfo: Information about the most recent modification of
9545	// this order.
9546	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
9547
9548	// Name: Name of this order.
9549	Name string `json:"name,omitempty"`
9550
9551	// Notes: Notes of this order.
9552	Notes string `json:"notes,omitempty"`
9553
9554	// PlanningTermId: ID of the terms and conditions template used in this
9555	// order.
9556	PlanningTermId int64 `json:"planningTermId,omitempty,string"`
9557
9558	// ProjectId: Project ID of this order.
9559	ProjectId int64 `json:"projectId,omitempty,string"`
9560
9561	// SellerOrderId: Seller order ID associated with this order.
9562	SellerOrderId string `json:"sellerOrderId,omitempty"`
9563
9564	// SellerOrganizationName: Name of the seller organization.
9565	SellerOrganizationName string `json:"sellerOrganizationName,omitempty"`
9566
9567	// SiteId: Site IDs this order is associated with.
9568	SiteId googleapi.Int64s `json:"siteId,omitempty"`
9569
9570	// SiteNames: Free-form site names this order is associated with.
9571	SiteNames []string `json:"siteNames,omitempty"`
9572
9573	// SubaccountId: Subaccount ID of this order.
9574	SubaccountId int64 `json:"subaccountId,omitempty,string"`
9575
9576	// TermsAndConditions: Terms and conditions of this order.
9577	TermsAndConditions string `json:"termsAndConditions,omitempty"`
9578
9579	// ServerResponse contains the HTTP response code and headers from the
9580	// server.
9581	googleapi.ServerResponse `json:"-"`
9582
9583	// ForceSendFields is a list of field names (e.g. "AccountId") to
9584	// unconditionally include in API requests. By default, fields with
9585	// empty values are omitted from API requests. However, any non-pointer,
9586	// non-interface field appearing in ForceSendFields will be sent to the
9587	// server regardless of whether the field is empty or not. This may be
9588	// used to include empty fields in Patch requests.
9589	ForceSendFields []string `json:"-"`
9590
9591	// NullFields is a list of field names (e.g. "AccountId") to include in
9592	// API requests with the JSON null value. By default, fields with empty
9593	// values are omitted from API requests. However, any field with an
9594	// empty value appearing in NullFields will be sent to the server as
9595	// null. It is an error if a field in this list has a non-empty value.
9596	// This may be used to include null fields in Patch requests.
9597	NullFields []string `json:"-"`
9598}
9599
9600func (s *Order) MarshalJSON() ([]byte, error) {
9601	type NoMethod Order
9602	raw := NoMethod(*s)
9603	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9604}
9605
9606// OrderContact: Contact of an order.
9607type OrderContact struct {
9608	// ContactInfo: Free-form information about this contact. It could be
9609	// any information related to this contact in addition to type, title,
9610	// name, and signature user profile ID.
9611	ContactInfo string `json:"contactInfo,omitempty"`
9612
9613	// ContactName: Name of this contact.
9614	ContactName string `json:"contactName,omitempty"`
9615
9616	// ContactTitle: Title of this contact.
9617	ContactTitle string `json:"contactTitle,omitempty"`
9618
9619	// ContactType: Type of this contact.
9620	//
9621	// Possible values:
9622	//   "PLANNING_ORDER_CONTACT_BUYER_BILLING_CONTACT"
9623	//   "PLANNING_ORDER_CONTACT_BUYER_CONTACT"
9624	//   "PLANNING_ORDER_CONTACT_SELLER_CONTACT"
9625	ContactType string `json:"contactType,omitempty"`
9626
9627	// SignatureUserProfileId: ID of the user profile containing the
9628	// signature that will be embedded into order documents.
9629	SignatureUserProfileId int64 `json:"signatureUserProfileId,omitempty,string"`
9630
9631	// ForceSendFields is a list of field names (e.g. "ContactInfo") to
9632	// unconditionally include in API requests. By default, fields with
9633	// empty values are omitted from API requests. However, any non-pointer,
9634	// non-interface field appearing in ForceSendFields will be sent to the
9635	// server regardless of whether the field is empty or not. This may be
9636	// used to include empty fields in Patch requests.
9637	ForceSendFields []string `json:"-"`
9638
9639	// NullFields is a list of field names (e.g. "ContactInfo") to include
9640	// in API requests with the JSON null value. By default, fields with
9641	// empty values are omitted from API requests. However, any field with
9642	// an empty value appearing in NullFields will be sent to the server as
9643	// null. It is an error if a field in this list has a non-empty value.
9644	// This may be used to include null fields in Patch requests.
9645	NullFields []string `json:"-"`
9646}
9647
9648func (s *OrderContact) MarshalJSON() ([]byte, error) {
9649	type NoMethod OrderContact
9650	raw := NoMethod(*s)
9651	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9652}
9653
9654// OrderDocument: Contains properties of a Planning order document.
9655type OrderDocument struct {
9656	// AccountId: Account ID of this order document.
9657	AccountId int64 `json:"accountId,omitempty,string"`
9658
9659	// AdvertiserId: Advertiser ID of this order document.
9660	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9661
9662	// AmendedOrderDocumentId: The amended order document ID of this order
9663	// document. An order document can be created by optionally amending
9664	// another order document so that the change history can be preserved.
9665	AmendedOrderDocumentId int64 `json:"amendedOrderDocumentId,omitempty,string"`
9666
9667	// ApprovedByUserProfileIds: IDs of users who have approved this order
9668	// document.
9669	ApprovedByUserProfileIds googleapi.Int64s `json:"approvedByUserProfileIds,omitempty"`
9670
9671	// Cancelled: Whether this order document is cancelled.
9672	Cancelled bool `json:"cancelled,omitempty"`
9673
9674	// CreatedInfo: Information about the creation of this order document.
9675	CreatedInfo *LastModifiedInfo `json:"createdInfo,omitempty"`
9676
9677	// EffectiveDate: Effective date of this order document.
9678	EffectiveDate string `json:"effectiveDate,omitempty"`
9679
9680	// Id: ID of this order document.
9681	Id int64 `json:"id,omitempty,string"`
9682
9683	// Kind: Identifies what kind of resource this is. Value: the fixed
9684	// string "dfareporting#orderDocument".
9685	Kind string `json:"kind,omitempty"`
9686
9687	// LastSentRecipients: List of email addresses that received the last
9688	// sent document.
9689	LastSentRecipients []string `json:"lastSentRecipients,omitempty"`
9690
9691	// LastSentTime: Timestamp of the last email sent with this order
9692	// document.
9693	LastSentTime string `json:"lastSentTime,omitempty"`
9694
9695	// OrderId: ID of the order from which this order document is created.
9696	OrderId int64 `json:"orderId,omitempty,string"`
9697
9698	// ProjectId: Project ID of this order document.
9699	ProjectId int64 `json:"projectId,omitempty,string"`
9700
9701	// Signed: Whether this order document has been signed.
9702	Signed bool `json:"signed,omitempty"`
9703
9704	// SubaccountId: Subaccount ID of this order document.
9705	SubaccountId int64 `json:"subaccountId,omitempty,string"`
9706
9707	// Title: Title of this order document.
9708	Title string `json:"title,omitempty"`
9709
9710	// Type: Type of this order document
9711	//
9712	// Possible values:
9713	//   "PLANNING_ORDER_TYPE_CHANGE_ORDER"
9714	//   "PLANNING_ORDER_TYPE_INSERTION_ORDER"
9715	Type string `json:"type,omitempty"`
9716
9717	// ServerResponse contains the HTTP response code and headers from the
9718	// server.
9719	googleapi.ServerResponse `json:"-"`
9720
9721	// ForceSendFields is a list of field names (e.g. "AccountId") to
9722	// unconditionally include in API requests. By default, fields with
9723	// empty values are omitted from API requests. However, any non-pointer,
9724	// non-interface field appearing in ForceSendFields will be sent to the
9725	// server regardless of whether the field is empty or not. This may be
9726	// used to include empty fields in Patch requests.
9727	ForceSendFields []string `json:"-"`
9728
9729	// NullFields is a list of field names (e.g. "AccountId") to include in
9730	// API requests with the JSON null value. By default, fields with empty
9731	// values are omitted from API requests. However, any field with an
9732	// empty value appearing in NullFields will be sent to the server as
9733	// null. It is an error if a field in this list has a non-empty value.
9734	// This may be used to include null fields in Patch requests.
9735	NullFields []string `json:"-"`
9736}
9737
9738func (s *OrderDocument) MarshalJSON() ([]byte, error) {
9739	type NoMethod OrderDocument
9740	raw := NoMethod(*s)
9741	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9742}
9743
9744// OrderDocumentsListResponse: Order document List Response
9745type OrderDocumentsListResponse struct {
9746	// Kind: Identifies what kind of resource this is. Value: the fixed
9747	// string "dfareporting#orderDocumentsListResponse".
9748	Kind string `json:"kind,omitempty"`
9749
9750	// NextPageToken: Pagination token to be used for the next list
9751	// operation.
9752	NextPageToken string `json:"nextPageToken,omitempty"`
9753
9754	// OrderDocuments: Order document collection
9755	OrderDocuments []*OrderDocument `json:"orderDocuments,omitempty"`
9756
9757	// ServerResponse contains the HTTP response code and headers from the
9758	// server.
9759	googleapi.ServerResponse `json:"-"`
9760
9761	// ForceSendFields is a list of field names (e.g. "Kind") to
9762	// unconditionally include in API requests. By default, fields with
9763	// empty values are omitted from API requests. However, any non-pointer,
9764	// non-interface field appearing in ForceSendFields will be sent to the
9765	// server regardless of whether the field is empty or not. This may be
9766	// used to include empty fields in Patch requests.
9767	ForceSendFields []string `json:"-"`
9768
9769	// NullFields is a list of field names (e.g. "Kind") to include in API
9770	// requests with the JSON null value. By default, fields with empty
9771	// values are omitted from API requests. However, any field with an
9772	// empty value appearing in NullFields will be sent to the server as
9773	// null. It is an error if a field in this list has a non-empty value.
9774	// This may be used to include null fields in Patch requests.
9775	NullFields []string `json:"-"`
9776}
9777
9778func (s *OrderDocumentsListResponse) MarshalJSON() ([]byte, error) {
9779	type NoMethod OrderDocumentsListResponse
9780	raw := NoMethod(*s)
9781	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9782}
9783
9784// OrdersListResponse: Order List Response
9785type OrdersListResponse struct {
9786	// Kind: Identifies what kind of resource this is. Value: the fixed
9787	// string "dfareporting#ordersListResponse".
9788	Kind string `json:"kind,omitempty"`
9789
9790	// NextPageToken: Pagination token to be used for the next list
9791	// operation.
9792	NextPageToken string `json:"nextPageToken,omitempty"`
9793
9794	// Orders: Order collection.
9795	Orders []*Order `json:"orders,omitempty"`
9796
9797	// ServerResponse contains the HTTP response code and headers from the
9798	// server.
9799	googleapi.ServerResponse `json:"-"`
9800
9801	// ForceSendFields is a list of field names (e.g. "Kind") to
9802	// unconditionally include in API requests. By default, fields with
9803	// empty values are omitted from API requests. However, any non-pointer,
9804	// non-interface field appearing in ForceSendFields will be sent to the
9805	// server regardless of whether the field is empty or not. This may be
9806	// used to include empty fields in Patch requests.
9807	ForceSendFields []string `json:"-"`
9808
9809	// NullFields is a list of field names (e.g. "Kind") to include in API
9810	// requests with the JSON null value. By default, fields with empty
9811	// values are omitted from API requests. However, any field with an
9812	// empty value appearing in NullFields will be sent to the server as
9813	// null. It is an error if a field in this list has a non-empty value.
9814	// This may be used to include null fields in Patch requests.
9815	NullFields []string `json:"-"`
9816}
9817
9818func (s *OrdersListResponse) MarshalJSON() ([]byte, error) {
9819	type NoMethod OrdersListResponse
9820	raw := NoMethod(*s)
9821	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9822}
9823
9824// PathToConversionReportCompatibleFields: Represents fields that are
9825// compatible to be selected for a report of type "PATH_TO_CONVERSION".
9826type PathToConversionReportCompatibleFields struct {
9827	// ConversionDimensions: Conversion dimensions which are compatible to
9828	// be selected in the "conversionDimensions" section of the report.
9829	ConversionDimensions []*Dimension `json:"conversionDimensions,omitempty"`
9830
9831	// CustomFloodlightVariables: Custom floodlight variables which are
9832	// compatible to be selected in the "customFloodlightVariables" section
9833	// of the report.
9834	CustomFloodlightVariables []*Dimension `json:"customFloodlightVariables,omitempty"`
9835
9836	// Kind: The kind of resource this is, in this case
9837	// dfareporting#pathToConversionReportCompatibleFields.
9838	Kind string `json:"kind,omitempty"`
9839
9840	// Metrics: Metrics which are compatible to be selected in the
9841	// "metricNames" section of the report.
9842	Metrics []*Metric `json:"metrics,omitempty"`
9843
9844	// PerInteractionDimensions: Per-interaction dimensions which are
9845	// compatible to be selected in the "perInteractionDimensions" section
9846	// of the report.
9847	PerInteractionDimensions []*Dimension `json:"perInteractionDimensions,omitempty"`
9848
9849	// ForceSendFields is a list of field names (e.g.
9850	// "ConversionDimensions") to unconditionally include in API requests.
9851	// By default, fields with empty values are omitted from API requests.
9852	// However, any non-pointer, non-interface field appearing in
9853	// ForceSendFields will be sent to the server regardless of whether the
9854	// field is empty or not. This may be used to include empty fields in
9855	// Patch requests.
9856	ForceSendFields []string `json:"-"`
9857
9858	// NullFields is a list of field names (e.g. "ConversionDimensions") to
9859	// include in API requests with the JSON null value. By default, fields
9860	// with empty values are omitted from API requests. However, any field
9861	// with an empty value appearing in NullFields will be sent to the
9862	// server as null. It is an error if a field in this list has a
9863	// non-empty value. This may be used to include null fields in Patch
9864	// requests.
9865	NullFields []string `json:"-"`
9866}
9867
9868func (s *PathToConversionReportCompatibleFields) MarshalJSON() ([]byte, error) {
9869	type NoMethod PathToConversionReportCompatibleFields
9870	raw := NoMethod(*s)
9871	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9872}
9873
9874// Placement: Contains properties of a placement.
9875type Placement struct {
9876	// AccountId: Account ID of this placement. This field can be left
9877	// blank.
9878	AccountId int64 `json:"accountId,omitempty,string"`
9879
9880	// AdBlockingOptOut: Whether this placement opts out of ad blocking.
9881	// When true, ad blocking is disabled for this placement. When false,
9882	// the campaign and site settings take effect.
9883	AdBlockingOptOut bool `json:"adBlockingOptOut,omitempty"`
9884
9885	// AdvertiserId: Advertiser ID of this placement. This field can be left
9886	// blank.
9887	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9888
9889	// AdvertiserIdDimensionValue: Dimension value for the ID of the
9890	// advertiser. This is a read-only, auto-generated field.
9891	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
9892
9893	// Archived: Whether this placement is archived.
9894	Archived bool `json:"archived,omitempty"`
9895
9896	// CampaignId: Campaign ID of this placement. This field is a required
9897	// field on insertion.
9898	CampaignId int64 `json:"campaignId,omitempty,string"`
9899
9900	// CampaignIdDimensionValue: Dimension value for the ID of the campaign.
9901	// This is a read-only, auto-generated field.
9902	CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
9903
9904	// Comment: Comments for this placement.
9905	Comment string `json:"comment,omitempty"`
9906
9907	// Compatibility: Placement compatibility. DISPLAY and
9908	// DISPLAY_INTERSTITIAL refer to rendering on desktop, on mobile devices
9909	// or in mobile apps for regular or interstitial ads respectively. APP
9910	// and APP_INTERSTITIAL are no longer allowed for new placement
9911	// insertions. Instead, use DISPLAY or DISPLAY_INTERSTITIAL.
9912	// IN_STREAM_VIDEO refers to rendering in in-stream video ads developed
9913	// with the VAST standard. This field is required on insertion.
9914	//
9915	// Possible values:
9916	//   "APP"
9917	//   "APP_INTERSTITIAL"
9918	//   "DISPLAY"
9919	//   "DISPLAY_INTERSTITIAL"
9920	//   "IN_STREAM_AUDIO"
9921	//   "IN_STREAM_VIDEO"
9922	Compatibility string `json:"compatibility,omitempty"`
9923
9924	// ContentCategoryId: ID of the content category assigned to this
9925	// placement.
9926	ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
9927
9928	// CreateInfo: Information about the creation of this placement. This is
9929	// a read-only field.
9930	CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
9931
9932	// DirectorySiteId: Directory site ID of this placement. On insert, you
9933	// must set either this field or the siteId field to specify the site
9934	// associated with this placement. This is a required field that is
9935	// read-only after insertion.
9936	DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
9937
9938	// DirectorySiteIdDimensionValue: Dimension value for the ID of the
9939	// directory site. This is a read-only, auto-generated field.
9940	DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
9941
9942	// ExternalId: External ID for this placement.
9943	ExternalId string `json:"externalId,omitempty"`
9944
9945	// Id: ID of this placement. This is a read-only, auto-generated field.
9946	Id int64 `json:"id,omitempty,string"`
9947
9948	// IdDimensionValue: Dimension value for the ID of this placement. This
9949	// is a read-only, auto-generated field.
9950	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
9951
9952	// KeyName: Key name of this placement. This is a read-only,
9953	// auto-generated field.
9954	KeyName string `json:"keyName,omitempty"`
9955
9956	// Kind: Identifies what kind of resource this is. Value: the fixed
9957	// string "dfareporting#placement".
9958	Kind string `json:"kind,omitempty"`
9959
9960	// LastModifiedInfo: Information about the most recent modification of
9961	// this placement. This is a read-only field.
9962	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
9963
9964	// LookbackConfiguration: Lookback window settings for this placement.
9965	LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
9966
9967	// Name: Name of this placement.This is a required field and must be
9968	// less than 256 characters long.
9969	Name string `json:"name,omitempty"`
9970
9971	// PaymentApproved: Whether payment was approved for this placement.
9972	// This is a read-only field relevant only to publisher-paid placements.
9973	PaymentApproved bool `json:"paymentApproved,omitempty"`
9974
9975	// PaymentSource: Payment source for this placement. This is a required
9976	// field that is read-only after insertion.
9977	//
9978	// Possible values:
9979	//   "PLACEMENT_AGENCY_PAID"
9980	//   "PLACEMENT_PUBLISHER_PAID"
9981	PaymentSource string `json:"paymentSource,omitempty"`
9982
9983	// PlacementGroupId: ID of this placement's group, if applicable.
9984	PlacementGroupId int64 `json:"placementGroupId,omitempty,string"`
9985
9986	// PlacementGroupIdDimensionValue: Dimension value for the ID of the
9987	// placement group. This is a read-only, auto-generated field.
9988	PlacementGroupIdDimensionValue *DimensionValue `json:"placementGroupIdDimensionValue,omitempty"`
9989
9990	// PlacementStrategyId: ID of the placement strategy assigned to this
9991	// placement.
9992	PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
9993
9994	// PricingSchedule: Pricing schedule of this placement. This field is
9995	// required on insertion, specifically subfields startDate, endDate and
9996	// pricingType.
9997	PricingSchedule *PricingSchedule `json:"pricingSchedule,omitempty"`
9998
9999	// Primary: Whether this placement is the primary placement of a
10000	// roadblock (placement group). You cannot change this field from true
10001	// to false. Setting this field to true will automatically set the
10002	// primary field on the original primary placement of the roadblock to
10003	// false, and it will automatically set the roadblock's
10004	// primaryPlacementId field to the ID of this placement.
10005	Primary bool `json:"primary,omitempty"`
10006
10007	// PublisherUpdateInfo: Information about the last publisher update.
10008	// This is a read-only field.
10009	PublisherUpdateInfo *LastModifiedInfo `json:"publisherUpdateInfo,omitempty"`
10010
10011	// SiteId: Site ID associated with this placement. On insert, you must
10012	// set either this field or the directorySiteId field to specify the
10013	// site associated with this placement. This is a required field that is
10014	// read-only after insertion.
10015	SiteId int64 `json:"siteId,omitempty,string"`
10016
10017	// SiteIdDimensionValue: Dimension value for the ID of the site. This is
10018	// a read-only, auto-generated field.
10019	SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
10020
10021	// Size: Size associated with this placement. When inserting or updating
10022	// a placement, only the size ID field is used. This field is required
10023	// on insertion.
10024	Size *Size `json:"size,omitempty"`
10025
10026	// SslRequired: Whether creatives assigned to this placement must be
10027	// SSL-compliant.
10028	SslRequired bool `json:"sslRequired,omitempty"`
10029
10030	// Status: Third-party placement status.
10031	//
10032	// Possible values:
10033	//   "ACKNOWLEDGE_ACCEPTANCE"
10034	//   "ACKNOWLEDGE_REJECTION"
10035	//   "DRAFT"
10036	//   "PAYMENT_ACCEPTED"
10037	//   "PAYMENT_REJECTED"
10038	//   "PENDING_REVIEW"
10039	Status string `json:"status,omitempty"`
10040
10041	// SubaccountId: Subaccount ID of this placement. This field can be left
10042	// blank.
10043	SubaccountId int64 `json:"subaccountId,omitempty,string"`
10044
10045	// TagFormats: Tag formats to generate for this placement. This field is
10046	// required on insertion.
10047	// Acceptable values are:
10048	// - "PLACEMENT_TAG_STANDARD"
10049	// - "PLACEMENT_TAG_IFRAME_JAVASCRIPT"
10050	// - "PLACEMENT_TAG_IFRAME_ILAYER"
10051	// - "PLACEMENT_TAG_INTERNAL_REDIRECT"
10052	// - "PLACEMENT_TAG_JAVASCRIPT"
10053	// - "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT"
10054	// - "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT"
10055	// - "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT"
10056	// - "PLACEMENT_TAG_CLICK_COMMANDS"
10057	// - "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH"
10058	// - "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3"
10059	// - "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4"
10060	// - "PLACEMENT_TAG_TRACKING"
10061	// - "PLACEMENT_TAG_TRACKING_IFRAME"
10062	// - "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
10063	//
10064	// Possible values:
10065	//   "PLACEMENT_TAG_CLICK_COMMANDS"
10066	//   "PLACEMENT_TAG_IFRAME_ILAYER"
10067	//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT"
10068	//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY"
10069	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH"
10070	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3"
10071	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4"
10072	//   "PLACEMENT_TAG_INTERNAL_REDIRECT"
10073	//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT"
10074	//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY"
10075	//   "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT"
10076	//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT"
10077	//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY"
10078	//   "PLACEMENT_TAG_JAVASCRIPT"
10079	//   "PLACEMENT_TAG_JAVASCRIPT_LEGACY"
10080	//   "PLACEMENT_TAG_STANDARD"
10081	//   "PLACEMENT_TAG_TRACKING"
10082	//   "PLACEMENT_TAG_TRACKING_IFRAME"
10083	//   "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
10084	TagFormats []string `json:"tagFormats,omitempty"`
10085
10086	// TagSetting: Tag settings for this placement.
10087	TagSetting *TagSetting `json:"tagSetting,omitempty"`
10088
10089	// VideoActiveViewOptOut: Whether Verification and ActiveView are
10090	// disabled for in-stream video creatives for this placement. The same
10091	// setting videoActiveViewOptOut exists on the site level -- the opt out
10092	// occurs if either of these settings are true. These settings are
10093	// distinct from DirectorySites.settings.activeViewOptOut or
10094	// Sites.siteSettings.activeViewOptOut which only apply to display ads.
10095	// However, Accounts.activeViewOptOut opts out both video traffic, as
10096	// well as display ads, from Verification and ActiveView.
10097	VideoActiveViewOptOut bool `json:"videoActiveViewOptOut,omitempty"`
10098
10099	// VideoSettings: A collection of settings which affect video creatives
10100	// served through this placement. Applicable to placements with
10101	// IN_STREAM_VIDEO compatibility.
10102	VideoSettings *VideoSettings `json:"videoSettings,omitempty"`
10103
10104	// VpaidAdapterChoice: VPAID adapter setting for this placement.
10105	// Controls which VPAID format the measurement adapter will use for
10106	// in-stream video creatives assigned to this placement.
10107	//
10108	// Note: Flash is no longer supported. This field now defaults to HTML5
10109	// when the following values are provided: FLASH, BOTH.
10110	//
10111	// Possible values:
10112	//   "BOTH"
10113	//   "DEFAULT"
10114	//   "FLASH"
10115	//   "HTML5"
10116	VpaidAdapterChoice string `json:"vpaidAdapterChoice,omitempty"`
10117
10118	// ServerResponse contains the HTTP response code and headers from the
10119	// server.
10120	googleapi.ServerResponse `json:"-"`
10121
10122	// ForceSendFields is a list of field names (e.g. "AccountId") to
10123	// unconditionally include in API requests. By default, fields with
10124	// empty values are omitted from API requests. However, any non-pointer,
10125	// non-interface field appearing in ForceSendFields will be sent to the
10126	// server regardless of whether the field is empty or not. This may be
10127	// used to include empty fields in Patch requests.
10128	ForceSendFields []string `json:"-"`
10129
10130	// NullFields is a list of field names (e.g. "AccountId") to include in
10131	// API requests with the JSON null value. By default, fields with empty
10132	// values are omitted from API requests. However, any field with an
10133	// empty value appearing in NullFields will be sent to the server as
10134	// null. It is an error if a field in this list has a non-empty value.
10135	// This may be used to include null fields in Patch requests.
10136	NullFields []string `json:"-"`
10137}
10138
10139func (s *Placement) MarshalJSON() ([]byte, error) {
10140	type NoMethod Placement
10141	raw := NoMethod(*s)
10142	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10143}
10144
10145// PlacementAssignment: Placement Assignment.
10146type PlacementAssignment struct {
10147	// Active: Whether this placement assignment is active. When true, the
10148	// placement will be included in the ad's rotation.
10149	Active bool `json:"active,omitempty"`
10150
10151	// PlacementId: ID of the placement to be assigned. This is a required
10152	// field.
10153	PlacementId int64 `json:"placementId,omitempty,string"`
10154
10155	// PlacementIdDimensionValue: Dimension value for the ID of the
10156	// placement. This is a read-only, auto-generated field.
10157	PlacementIdDimensionValue *DimensionValue `json:"placementIdDimensionValue,omitempty"`
10158
10159	// SslRequired: Whether the placement to be assigned requires SSL. This
10160	// is a read-only field that is auto-generated when the ad is inserted
10161	// or updated.
10162	SslRequired bool `json:"sslRequired,omitempty"`
10163
10164	// ForceSendFields is a list of field names (e.g. "Active") to
10165	// unconditionally include in API requests. By default, fields with
10166	// empty values are omitted from API requests. However, any non-pointer,
10167	// non-interface field appearing in ForceSendFields will be sent to the
10168	// server regardless of whether the field is empty or not. This may be
10169	// used to include empty fields in Patch requests.
10170	ForceSendFields []string `json:"-"`
10171
10172	// NullFields is a list of field names (e.g. "Active") to include in API
10173	// requests with the JSON null value. By default, fields with empty
10174	// values are omitted from API requests. However, any field with an
10175	// empty value appearing in NullFields will be sent to the server as
10176	// null. It is an error if a field in this list has a non-empty value.
10177	// This may be used to include null fields in Patch requests.
10178	NullFields []string `json:"-"`
10179}
10180
10181func (s *PlacementAssignment) MarshalJSON() ([]byte, error) {
10182	type NoMethod PlacementAssignment
10183	raw := NoMethod(*s)
10184	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10185}
10186
10187// PlacementGroup: Contains properties of a package or roadblock.
10188type PlacementGroup struct {
10189	// AccountId: Account ID of this placement group. This is a read-only
10190	// field that can be left blank.
10191	AccountId int64 `json:"accountId,omitempty,string"`
10192
10193	// AdvertiserId: Advertiser ID of this placement group. This is a
10194	// required field on insertion.
10195	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
10196
10197	// AdvertiserIdDimensionValue: Dimension value for the ID of the
10198	// advertiser. This is a read-only, auto-generated field.
10199	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
10200
10201	// Archived: Whether this placement group is archived.
10202	Archived bool `json:"archived,omitempty"`
10203
10204	// CampaignId: Campaign ID of this placement group. This field is
10205	// required on insertion.
10206	CampaignId int64 `json:"campaignId,omitempty,string"`
10207
10208	// CampaignIdDimensionValue: Dimension value for the ID of the campaign.
10209	// This is a read-only, auto-generated field.
10210	CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
10211
10212	// ChildPlacementIds: IDs of placements which are assigned to this
10213	// placement group. This is a read-only, auto-generated field.
10214	ChildPlacementIds googleapi.Int64s `json:"childPlacementIds,omitempty"`
10215
10216	// Comment: Comments for this placement group.
10217	Comment string `json:"comment,omitempty"`
10218
10219	// ContentCategoryId: ID of the content category assigned to this
10220	// placement group.
10221	ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
10222
10223	// CreateInfo: Information about the creation of this placement group.
10224	// This is a read-only field.
10225	CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
10226
10227	// DirectorySiteId: Directory site ID associated with this placement
10228	// group. On insert, you must set either this field or the site_id field
10229	// to specify the site associated with this placement group. This is a
10230	// required field that is read-only after insertion.
10231	DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
10232
10233	// DirectorySiteIdDimensionValue: Dimension value for the ID of the
10234	// directory site. This is a read-only, auto-generated field.
10235	DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
10236
10237	// ExternalId: External ID for this placement.
10238	ExternalId string `json:"externalId,omitempty"`
10239
10240	// Id: ID of this placement group. This is a read-only, auto-generated
10241	// field.
10242	Id int64 `json:"id,omitempty,string"`
10243
10244	// IdDimensionValue: Dimension value for the ID of this placement group.
10245	// This is a read-only, auto-generated field.
10246	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
10247
10248	// Kind: Identifies what kind of resource this is. Value: the fixed
10249	// string "dfareporting#placementGroup".
10250	Kind string `json:"kind,omitempty"`
10251
10252	// LastModifiedInfo: Information about the most recent modification of
10253	// this placement group. This is a read-only field.
10254	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
10255
10256	// Name: Name of this placement group. This is a required field and must
10257	// be less than 256 characters long.
10258	Name string `json:"name,omitempty"`
10259
10260	// PlacementGroupType: Type of this placement group. A package is a
10261	// simple group of placements that acts as a single pricing point for a
10262	// group of tags. A roadblock is a group of placements that not only
10263	// acts as a single pricing point, but also assumes that all the tags in
10264	// it will be served at the same time. A roadblock requires one of its
10265	// assigned placements to be marked as primary for reporting. This field
10266	// is required on insertion.
10267	//
10268	// Possible values:
10269	//   "PLACEMENT_PACKAGE"
10270	//   "PLACEMENT_ROADBLOCK"
10271	PlacementGroupType string `json:"placementGroupType,omitempty"`
10272
10273	// PlacementStrategyId: ID of the placement strategy assigned to this
10274	// placement group.
10275	PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
10276
10277	// PricingSchedule: Pricing schedule of this placement group. This field
10278	// is required on insertion.
10279	PricingSchedule *PricingSchedule `json:"pricingSchedule,omitempty"`
10280
10281	// PrimaryPlacementId: ID of the primary placement, used to calculate
10282	// the media cost of a roadblock (placement group). Modifying this field
10283	// will automatically modify the primary field on all affected roadblock
10284	// child placements.
10285	PrimaryPlacementId int64 `json:"primaryPlacementId,omitempty,string"`
10286
10287	// PrimaryPlacementIdDimensionValue: Dimension value for the ID of the
10288	// primary placement. This is a read-only, auto-generated field.
10289	PrimaryPlacementIdDimensionValue *DimensionValue `json:"primaryPlacementIdDimensionValue,omitempty"`
10290
10291	// SiteId: Site ID associated with this placement group. On insert, you
10292	// must set either this field or the directorySiteId field to specify
10293	// the site associated with this placement group. This is a required
10294	// field that is read-only after insertion.
10295	SiteId int64 `json:"siteId,omitempty,string"`
10296
10297	// SiteIdDimensionValue: Dimension value for the ID of the site. This is
10298	// a read-only, auto-generated field.
10299	SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
10300
10301	// SubaccountId: Subaccount ID of this placement group. This is a
10302	// read-only field that can be left blank.
10303	SubaccountId int64 `json:"subaccountId,omitempty,string"`
10304
10305	// ServerResponse contains the HTTP response code and headers from the
10306	// server.
10307	googleapi.ServerResponse `json:"-"`
10308
10309	// ForceSendFields is a list of field names (e.g. "AccountId") to
10310	// unconditionally include in API requests. By default, fields with
10311	// empty values are omitted from API requests. However, any non-pointer,
10312	// non-interface field appearing in ForceSendFields will be sent to the
10313	// server regardless of whether the field is empty or not. This may be
10314	// used to include empty fields in Patch requests.
10315	ForceSendFields []string `json:"-"`
10316
10317	// NullFields is a list of field names (e.g. "AccountId") to include in
10318	// API requests with the JSON null value. By default, fields with empty
10319	// values are omitted from API requests. However, any field with an
10320	// empty value appearing in NullFields will be sent to the server as
10321	// null. It is an error if a field in this list has a non-empty value.
10322	// This may be used to include null fields in Patch requests.
10323	NullFields []string `json:"-"`
10324}
10325
10326func (s *PlacementGroup) MarshalJSON() ([]byte, error) {
10327	type NoMethod PlacementGroup
10328	raw := NoMethod(*s)
10329	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10330}
10331
10332// PlacementGroupsListResponse: Placement Group List Response
10333type PlacementGroupsListResponse struct {
10334	// Kind: Identifies what kind of resource this is. Value: the fixed
10335	// string "dfareporting#placementGroupsListResponse".
10336	Kind string `json:"kind,omitempty"`
10337
10338	// NextPageToken: Pagination token to be used for the next list
10339	// operation.
10340	NextPageToken string `json:"nextPageToken,omitempty"`
10341
10342	// PlacementGroups: Placement group collection.
10343	PlacementGroups []*PlacementGroup `json:"placementGroups,omitempty"`
10344
10345	// ServerResponse contains the HTTP response code and headers from the
10346	// server.
10347	googleapi.ServerResponse `json:"-"`
10348
10349	// ForceSendFields is a list of field names (e.g. "Kind") to
10350	// unconditionally include in API requests. By default, fields with
10351	// empty values are omitted from API requests. However, any non-pointer,
10352	// non-interface field appearing in ForceSendFields will be sent to the
10353	// server regardless of whether the field is empty or not. This may be
10354	// used to include empty fields in Patch requests.
10355	ForceSendFields []string `json:"-"`
10356
10357	// NullFields is a list of field names (e.g. "Kind") to include in API
10358	// requests with the JSON null value. By default, fields with empty
10359	// values are omitted from API requests. However, any field with an
10360	// empty value appearing in NullFields will be sent to the server as
10361	// null. It is an error if a field in this list has a non-empty value.
10362	// This may be used to include null fields in Patch requests.
10363	NullFields []string `json:"-"`
10364}
10365
10366func (s *PlacementGroupsListResponse) MarshalJSON() ([]byte, error) {
10367	type NoMethod PlacementGroupsListResponse
10368	raw := NoMethod(*s)
10369	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10370}
10371
10372// PlacementStrategiesListResponse: Placement Strategy List Response
10373type PlacementStrategiesListResponse struct {
10374	// Kind: Identifies what kind of resource this is. Value: the fixed
10375	// string "dfareporting#placementStrategiesListResponse".
10376	Kind string `json:"kind,omitempty"`
10377
10378	// NextPageToken: Pagination token to be used for the next list
10379	// operation.
10380	NextPageToken string `json:"nextPageToken,omitempty"`
10381
10382	// PlacementStrategies: Placement strategy collection.
10383	PlacementStrategies []*PlacementStrategy `json:"placementStrategies,omitempty"`
10384
10385	// ServerResponse contains the HTTP response code and headers from the
10386	// server.
10387	googleapi.ServerResponse `json:"-"`
10388
10389	// ForceSendFields is a list of field names (e.g. "Kind") to
10390	// unconditionally include in API requests. By default, fields with
10391	// empty values are omitted from API requests. However, any non-pointer,
10392	// non-interface field appearing in ForceSendFields will be sent to the
10393	// server regardless of whether the field is empty or not. This may be
10394	// used to include empty fields in Patch requests.
10395	ForceSendFields []string `json:"-"`
10396
10397	// NullFields is a list of field names (e.g. "Kind") to include in API
10398	// requests with the JSON null value. By default, fields with empty
10399	// values are omitted from API requests. However, any field with an
10400	// empty value appearing in NullFields will be sent to the server as
10401	// null. It is an error if a field in this list has a non-empty value.
10402	// This may be used to include null fields in Patch requests.
10403	NullFields []string `json:"-"`
10404}
10405
10406func (s *PlacementStrategiesListResponse) MarshalJSON() ([]byte, error) {
10407	type NoMethod PlacementStrategiesListResponse
10408	raw := NoMethod(*s)
10409	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10410}
10411
10412// PlacementStrategy: Contains properties of a placement strategy.
10413type PlacementStrategy struct {
10414	// AccountId: Account ID of this placement strategy.This is a read-only
10415	// field that can be left blank.
10416	AccountId int64 `json:"accountId,omitempty,string"`
10417
10418	// Id: ID of this placement strategy. This is a read-only,
10419	// auto-generated field.
10420	Id int64 `json:"id,omitempty,string"`
10421
10422	// Kind: Identifies what kind of resource this is. Value: the fixed
10423	// string "dfareporting#placementStrategy".
10424	Kind string `json:"kind,omitempty"`
10425
10426	// Name: Name of this placement strategy. This is a required field. It
10427	// must be less than 256 characters long and unique among placement
10428	// strategies of the same account.
10429	Name string `json:"name,omitempty"`
10430
10431	// ServerResponse contains the HTTP response code and headers from the
10432	// server.
10433	googleapi.ServerResponse `json:"-"`
10434
10435	// ForceSendFields is a list of field names (e.g. "AccountId") to
10436	// unconditionally include in API requests. By default, fields with
10437	// empty values are omitted from API requests. However, any non-pointer,
10438	// non-interface field appearing in ForceSendFields will be sent to the
10439	// server regardless of whether the field is empty or not. This may be
10440	// used to include empty fields in Patch requests.
10441	ForceSendFields []string `json:"-"`
10442
10443	// NullFields is a list of field names (e.g. "AccountId") to include in
10444	// API requests with the JSON null value. By default, fields with empty
10445	// values are omitted from API requests. However, any field with an
10446	// empty value appearing in NullFields will be sent to the server as
10447	// null. It is an error if a field in this list has a non-empty value.
10448	// This may be used to include null fields in Patch requests.
10449	NullFields []string `json:"-"`
10450}
10451
10452func (s *PlacementStrategy) MarshalJSON() ([]byte, error) {
10453	type NoMethod PlacementStrategy
10454	raw := NoMethod(*s)
10455	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10456}
10457
10458// PlacementTag: Placement Tag
10459type PlacementTag struct {
10460	// PlacementId: Placement ID
10461	PlacementId int64 `json:"placementId,omitempty,string"`
10462
10463	// TagDatas: Tags generated for this placement.
10464	TagDatas []*TagData `json:"tagDatas,omitempty"`
10465
10466	// ForceSendFields is a list of field names (e.g. "PlacementId") to
10467	// unconditionally include in API requests. By default, fields with
10468	// empty values are omitted from API requests. However, any non-pointer,
10469	// non-interface field appearing in ForceSendFields will be sent to the
10470	// server regardless of whether the field is empty or not. This may be
10471	// used to include empty fields in Patch requests.
10472	ForceSendFields []string `json:"-"`
10473
10474	// NullFields is a list of field names (e.g. "PlacementId") to include
10475	// in API requests with the JSON null value. By default, fields with
10476	// empty values are omitted from API requests. However, any field with
10477	// an empty value appearing in NullFields will be sent to the server as
10478	// null. It is an error if a field in this list has a non-empty value.
10479	// This may be used to include null fields in Patch requests.
10480	NullFields []string `json:"-"`
10481}
10482
10483func (s *PlacementTag) MarshalJSON() ([]byte, error) {
10484	type NoMethod PlacementTag
10485	raw := NoMethod(*s)
10486	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10487}
10488
10489// PlacementsGenerateTagsResponse: Placement GenerateTags Response
10490type PlacementsGenerateTagsResponse struct {
10491	// Kind: Identifies what kind of resource this is. Value: the fixed
10492	// string "dfareporting#placementsGenerateTagsResponse".
10493	Kind string `json:"kind,omitempty"`
10494
10495	// PlacementTags: Set of generated tags for the specified placements.
10496	PlacementTags []*PlacementTag `json:"placementTags,omitempty"`
10497
10498	// ServerResponse contains the HTTP response code and headers from the
10499	// server.
10500	googleapi.ServerResponse `json:"-"`
10501
10502	// ForceSendFields is a list of field names (e.g. "Kind") to
10503	// unconditionally include in API requests. By default, fields with
10504	// empty values are omitted from API requests. However, any non-pointer,
10505	// non-interface field appearing in ForceSendFields will be sent to the
10506	// server regardless of whether the field is empty or not. This may be
10507	// used to include empty fields in Patch requests.
10508	ForceSendFields []string `json:"-"`
10509
10510	// NullFields is a list of field names (e.g. "Kind") to include in API
10511	// requests with the JSON null value. By default, fields with empty
10512	// values are omitted from API requests. However, any field with an
10513	// empty value appearing in NullFields will be sent to the server as
10514	// null. It is an error if a field in this list has a non-empty value.
10515	// This may be used to include null fields in Patch requests.
10516	NullFields []string `json:"-"`
10517}
10518
10519func (s *PlacementsGenerateTagsResponse) MarshalJSON() ([]byte, error) {
10520	type NoMethod PlacementsGenerateTagsResponse
10521	raw := NoMethod(*s)
10522	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10523}
10524
10525// PlacementsListResponse: Placement List Response
10526type PlacementsListResponse struct {
10527	// Kind: Identifies what kind of resource this is. Value: the fixed
10528	// string "dfareporting#placementsListResponse".
10529	Kind string `json:"kind,omitempty"`
10530
10531	// NextPageToken: Pagination token to be used for the next list
10532	// operation.
10533	NextPageToken string `json:"nextPageToken,omitempty"`
10534
10535	// Placements: Placement collection.
10536	Placements []*Placement `json:"placements,omitempty"`
10537
10538	// ServerResponse contains the HTTP response code and headers from the
10539	// server.
10540	googleapi.ServerResponse `json:"-"`
10541
10542	// ForceSendFields is a list of field names (e.g. "Kind") to
10543	// unconditionally include in API requests. By default, fields with
10544	// empty values are omitted from API requests. However, any non-pointer,
10545	// non-interface field appearing in ForceSendFields will be sent to the
10546	// server regardless of whether the field is empty or not. This may be
10547	// used to include empty fields in Patch requests.
10548	ForceSendFields []string `json:"-"`
10549
10550	// NullFields is a list of field names (e.g. "Kind") to include in API
10551	// requests with the JSON null value. By default, fields with empty
10552	// values are omitted from API requests. However, any field with an
10553	// empty value appearing in NullFields will be sent to the server as
10554	// null. It is an error if a field in this list has a non-empty value.
10555	// This may be used to include null fields in Patch requests.
10556	NullFields []string `json:"-"`
10557}
10558
10559func (s *PlacementsListResponse) MarshalJSON() ([]byte, error) {
10560	type NoMethod PlacementsListResponse
10561	raw := NoMethod(*s)
10562	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10563}
10564
10565// PlatformType: Contains information about a platform type that can be
10566// targeted by ads.
10567type PlatformType struct {
10568	// Id: ID of this platform type.
10569	Id int64 `json:"id,omitempty,string"`
10570
10571	// Kind: Identifies what kind of resource this is. Value: the fixed
10572	// string "dfareporting#platformType".
10573	Kind string `json:"kind,omitempty"`
10574
10575	// Name: Name of this platform type.
10576	Name string `json:"name,omitempty"`
10577
10578	// ServerResponse contains the HTTP response code and headers from the
10579	// server.
10580	googleapi.ServerResponse `json:"-"`
10581
10582	// ForceSendFields is a list of field names (e.g. "Id") to
10583	// unconditionally include in API requests. By default, fields with
10584	// empty values are omitted from API requests. However, any non-pointer,
10585	// non-interface field appearing in ForceSendFields will be sent to the
10586	// server regardless of whether the field is empty or not. This may be
10587	// used to include empty fields in Patch requests.
10588	ForceSendFields []string `json:"-"`
10589
10590	// NullFields is a list of field names (e.g. "Id") to include in API
10591	// requests with the JSON null value. By default, fields with empty
10592	// values are omitted from API requests. However, any field with an
10593	// empty value appearing in NullFields will be sent to the server as
10594	// null. It is an error if a field in this list has a non-empty value.
10595	// This may be used to include null fields in Patch requests.
10596	NullFields []string `json:"-"`
10597}
10598
10599func (s *PlatformType) MarshalJSON() ([]byte, error) {
10600	type NoMethod PlatformType
10601	raw := NoMethod(*s)
10602	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10603}
10604
10605// PlatformTypesListResponse: Platform Type List Response
10606type PlatformTypesListResponse struct {
10607	// Kind: Identifies what kind of resource this is. Value: the fixed
10608	// string "dfareporting#platformTypesListResponse".
10609	Kind string `json:"kind,omitempty"`
10610
10611	// PlatformTypes: Platform type collection.
10612	PlatformTypes []*PlatformType `json:"platformTypes,omitempty"`
10613
10614	// ServerResponse contains the HTTP response code and headers from the
10615	// server.
10616	googleapi.ServerResponse `json:"-"`
10617
10618	// ForceSendFields is a list of field names (e.g. "Kind") to
10619	// unconditionally include in API requests. By default, fields with
10620	// empty values are omitted from API requests. However, any non-pointer,
10621	// non-interface field appearing in ForceSendFields will be sent to the
10622	// server regardless of whether the field is empty or not. This may be
10623	// used to include empty fields in Patch requests.
10624	ForceSendFields []string `json:"-"`
10625
10626	// NullFields is a list of field names (e.g. "Kind") to include in API
10627	// requests with the JSON null value. By default, fields with empty
10628	// values are omitted from API requests. However, any field with an
10629	// empty value appearing in NullFields will be sent to the server as
10630	// null. It is an error if a field in this list has a non-empty value.
10631	// This may be used to include null fields in Patch requests.
10632	NullFields []string `json:"-"`
10633}
10634
10635func (s *PlatformTypesListResponse) MarshalJSON() ([]byte, error) {
10636	type NoMethod PlatformTypesListResponse
10637	raw := NoMethod(*s)
10638	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10639}
10640
10641// PopupWindowProperties: Popup Window Properties.
10642type PopupWindowProperties struct {
10643	// Dimension: Popup dimension for a creative. This is a read-only field.
10644	// Applicable to the following creative types: all RICH_MEDIA and all
10645	// VPAID
10646	Dimension *Size `json:"dimension,omitempty"`
10647
10648	// Offset: Upper-left corner coordinates of the popup window. Applicable
10649	// if positionType is COORDINATES.
10650	Offset *OffsetPosition `json:"offset,omitempty"`
10651
10652	// PositionType: Popup window position either centered or at specific
10653	// coordinate.
10654	//
10655	// Possible values:
10656	//   "CENTER"
10657	//   "COORDINATES"
10658	PositionType string `json:"positionType,omitempty"`
10659
10660	// ShowAddressBar: Whether to display the browser address bar.
10661	ShowAddressBar bool `json:"showAddressBar,omitempty"`
10662
10663	// ShowMenuBar: Whether to display the browser menu bar.
10664	ShowMenuBar bool `json:"showMenuBar,omitempty"`
10665
10666	// ShowScrollBar: Whether to display the browser scroll bar.
10667	ShowScrollBar bool `json:"showScrollBar,omitempty"`
10668
10669	// ShowStatusBar: Whether to display the browser status bar.
10670	ShowStatusBar bool `json:"showStatusBar,omitempty"`
10671
10672	// ShowToolBar: Whether to display the browser tool bar.
10673	ShowToolBar bool `json:"showToolBar,omitempty"`
10674
10675	// Title: Title of popup window.
10676	Title string `json:"title,omitempty"`
10677
10678	// ForceSendFields is a list of field names (e.g. "Dimension") to
10679	// unconditionally include in API requests. By default, fields with
10680	// empty values are omitted from API requests. However, any non-pointer,
10681	// non-interface field appearing in ForceSendFields will be sent to the
10682	// server regardless of whether the field is empty or not. This may be
10683	// used to include empty fields in Patch requests.
10684	ForceSendFields []string `json:"-"`
10685
10686	// NullFields is a list of field names (e.g. "Dimension") to include in
10687	// API requests with the JSON null value. By default, fields with empty
10688	// values are omitted from API requests. However, any field with an
10689	// empty value appearing in NullFields will be sent to the server as
10690	// null. It is an error if a field in this list has a non-empty value.
10691	// This may be used to include null fields in Patch requests.
10692	NullFields []string `json:"-"`
10693}
10694
10695func (s *PopupWindowProperties) MarshalJSON() ([]byte, error) {
10696	type NoMethod PopupWindowProperties
10697	raw := NoMethod(*s)
10698	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10699}
10700
10701// PostalCode: Contains information about a postal code that can be
10702// targeted by ads.
10703type PostalCode struct {
10704	// Code: Postal code. This is equivalent to the id field.
10705	Code string `json:"code,omitempty"`
10706
10707	// CountryCode: Country code of the country to which this postal code
10708	// belongs.
10709	CountryCode string `json:"countryCode,omitempty"`
10710
10711	// CountryDartId: DART ID of the country to which this postal code
10712	// belongs.
10713	CountryDartId int64 `json:"countryDartId,omitempty,string"`
10714
10715	// Id: ID of this postal code.
10716	Id string `json:"id,omitempty"`
10717
10718	// Kind: Identifies what kind of resource this is. Value: the fixed
10719	// string "dfareporting#postalCode".
10720	Kind string `json:"kind,omitempty"`
10721
10722	// ServerResponse contains the HTTP response code and headers from the
10723	// server.
10724	googleapi.ServerResponse `json:"-"`
10725
10726	// ForceSendFields is a list of field names (e.g. "Code") to
10727	// unconditionally include in API requests. By default, fields with
10728	// empty values are omitted from API requests. However, any non-pointer,
10729	// non-interface field appearing in ForceSendFields will be sent to the
10730	// server regardless of whether the field is empty or not. This may be
10731	// used to include empty fields in Patch requests.
10732	ForceSendFields []string `json:"-"`
10733
10734	// NullFields is a list of field names (e.g. "Code") to include in API
10735	// requests with the JSON null value. By default, fields with empty
10736	// values are omitted from API requests. However, any field with an
10737	// empty value appearing in NullFields will be sent to the server as
10738	// null. It is an error if a field in this list has a non-empty value.
10739	// This may be used to include null fields in Patch requests.
10740	NullFields []string `json:"-"`
10741}
10742
10743func (s *PostalCode) MarshalJSON() ([]byte, error) {
10744	type NoMethod PostalCode
10745	raw := NoMethod(*s)
10746	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10747}
10748
10749// PostalCodesListResponse: Postal Code List Response
10750type PostalCodesListResponse struct {
10751	// Kind: Identifies what kind of resource this is. Value: the fixed
10752	// string "dfareporting#postalCodesListResponse".
10753	Kind string `json:"kind,omitempty"`
10754
10755	// PostalCodes: Postal code collection.
10756	PostalCodes []*PostalCode `json:"postalCodes,omitempty"`
10757
10758	// ServerResponse contains the HTTP response code and headers from the
10759	// server.
10760	googleapi.ServerResponse `json:"-"`
10761
10762	// ForceSendFields is a list of field names (e.g. "Kind") to
10763	// unconditionally include in API requests. By default, fields with
10764	// empty values are omitted from API requests. However, any non-pointer,
10765	// non-interface field appearing in ForceSendFields will be sent to the
10766	// server regardless of whether the field is empty or not. This may be
10767	// used to include empty fields in Patch requests.
10768	ForceSendFields []string `json:"-"`
10769
10770	// NullFields is a list of field names (e.g. "Kind") to include in API
10771	// requests with the JSON null value. By default, fields with empty
10772	// values are omitted from API requests. However, any field with an
10773	// empty value appearing in NullFields will be sent to the server as
10774	// null. It is an error if a field in this list has a non-empty value.
10775	// This may be used to include null fields in Patch requests.
10776	NullFields []string `json:"-"`
10777}
10778
10779func (s *PostalCodesListResponse) MarshalJSON() ([]byte, error) {
10780	type NoMethod PostalCodesListResponse
10781	raw := NoMethod(*s)
10782	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10783}
10784
10785// Pricing: Pricing Information
10786type Pricing struct {
10787	// CapCostType: Cap cost type of this inventory item.
10788	//
10789	// Possible values:
10790	//   "PLANNING_PLACEMENT_CAP_COST_TYPE_CUMULATIVE"
10791	//   "PLANNING_PLACEMENT_CAP_COST_TYPE_MONTHLY"
10792	//   "PLANNING_PLACEMENT_CAP_COST_TYPE_NONE"
10793	CapCostType string `json:"capCostType,omitempty"`
10794
10795	// EndDate: End date of this inventory item.
10796	EndDate string `json:"endDate,omitempty"`
10797
10798	// Flights: Flights of this inventory item. A flight (a.k.a. pricing
10799	// period) represents the inventory item pricing information for a
10800	// specific period of time.
10801	Flights []*Flight `json:"flights,omitempty"`
10802
10803	// GroupType: Group type of this inventory item if it represents a
10804	// placement group. Is null otherwise. There are two type of placement
10805	// groups: PLANNING_PLACEMENT_GROUP_TYPE_PACKAGE is a simple group of
10806	// inventory items that acts as a single pricing point for a group of
10807	// tags. PLANNING_PLACEMENT_GROUP_TYPE_ROADBLOCK is a group of inventory
10808	// items that not only acts as a single pricing point, but also assumes
10809	// that all the tags in it will be served at the same time. A roadblock
10810	// requires one of its assigned inventory items to be marked as primary.
10811	//
10812	// Possible values:
10813	//   "PLANNING_PLACEMENT_GROUP_TYPE_PACKAGE"
10814	//   "PLANNING_PLACEMENT_GROUP_TYPE_ROADBLOCK"
10815	GroupType string `json:"groupType,omitempty"`
10816
10817	// PricingType: Pricing type of this inventory item.
10818	//
10819	// Possible values:
10820	//   "PLANNING_PLACEMENT_PRICING_TYPE_CLICKS"
10821	//   "PLANNING_PLACEMENT_PRICING_TYPE_CPA"
10822	//   "PLANNING_PLACEMENT_PRICING_TYPE_CPC"
10823	//   "PLANNING_PLACEMENT_PRICING_TYPE_CPM"
10824	//   "PLANNING_PLACEMENT_PRICING_TYPE_CPM_ACTIVEVIEW"
10825	//   "PLANNING_PLACEMENT_PRICING_TYPE_FLAT_RATE_CLICKS"
10826	//   "PLANNING_PLACEMENT_PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
10827	//   "PLANNING_PLACEMENT_PRICING_TYPE_IMPRESSIONS"
10828	PricingType string `json:"pricingType,omitempty"`
10829
10830	// StartDate: Start date of this inventory item.
10831	StartDate string `json:"startDate,omitempty"`
10832
10833	// ForceSendFields is a list of field names (e.g. "CapCostType") to
10834	// unconditionally include in API requests. By default, fields with
10835	// empty values are omitted from API requests. However, any non-pointer,
10836	// non-interface field appearing in ForceSendFields will be sent to the
10837	// server regardless of whether the field is empty or not. This may be
10838	// used to include empty fields in Patch requests.
10839	ForceSendFields []string `json:"-"`
10840
10841	// NullFields is a list of field names (e.g. "CapCostType") to include
10842	// in API requests with the JSON null value. By default, fields with
10843	// empty values are omitted from API requests. However, any field with
10844	// an empty value appearing in NullFields will be sent to the server as
10845	// null. It is an error if a field in this list has a non-empty value.
10846	// This may be used to include null fields in Patch requests.
10847	NullFields []string `json:"-"`
10848}
10849
10850func (s *Pricing) MarshalJSON() ([]byte, error) {
10851	type NoMethod Pricing
10852	raw := NoMethod(*s)
10853	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10854}
10855
10856// PricingSchedule: Pricing Schedule
10857type PricingSchedule struct {
10858	// CapCostOption: Placement cap cost option.
10859	//
10860	// Possible values:
10861	//   "CAP_COST_CUMULATIVE"
10862	//   "CAP_COST_MONTHLY"
10863	//   "CAP_COST_NONE"
10864	CapCostOption string `json:"capCostOption,omitempty"`
10865
10866	// DisregardOverdelivery: Whether cap costs are ignored by ad serving.
10867	DisregardOverdelivery bool `json:"disregardOverdelivery,omitempty"`
10868
10869	// EndDate: Placement end date. This date must be later than, or the
10870	// same day as, the placement start date, but not later than the
10871	// campaign end date. If, for example, you set 6/25/2015 as both the
10872	// start and end dates, the effective placement date is just that day
10873	// only, 6/25/2015. The hours, minutes, and seconds of the end date
10874	// should not be set, as doing so will result in an error. This field is
10875	// required on insertion.
10876	EndDate string `json:"endDate,omitempty"`
10877
10878	// Flighted: Whether this placement is flighted. If true, pricing
10879	// periods will be computed automatically.
10880	Flighted bool `json:"flighted,omitempty"`
10881
10882	// FloodlightActivityId: Floodlight activity ID associated with this
10883	// placement. This field should be set when placement pricing type is
10884	// set to PRICING_TYPE_CPA.
10885	FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
10886
10887	// PricingPeriods: Pricing periods for this placement.
10888	PricingPeriods []*PricingSchedulePricingPeriod `json:"pricingPeriods,omitempty"`
10889
10890	// PricingType: Placement pricing type. This field is required on
10891	// insertion.
10892	//
10893	// Possible values:
10894	//   "PRICING_TYPE_CPA"
10895	//   "PRICING_TYPE_CPC"
10896	//   "PRICING_TYPE_CPM"
10897	//   "PRICING_TYPE_CPM_ACTIVEVIEW"
10898	//   "PRICING_TYPE_FLAT_RATE_CLICKS"
10899	//   "PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
10900	PricingType string `json:"pricingType,omitempty"`
10901
10902	// StartDate: Placement start date. This date must be later than, or the
10903	// same day as, the campaign start date. The hours, minutes, and seconds
10904	// of the start date should not be set, as doing so will result in an
10905	// error. This field is required on insertion.
10906	StartDate string `json:"startDate,omitempty"`
10907
10908	// TestingStartDate: Testing start date of this placement. The hours,
10909	// minutes, and seconds of the start date should not be set, as doing so
10910	// will result in an error.
10911	TestingStartDate string `json:"testingStartDate,omitempty"`
10912
10913	// ForceSendFields is a list of field names (e.g. "CapCostOption") to
10914	// unconditionally include in API requests. By default, fields with
10915	// empty values are omitted from API requests. However, any non-pointer,
10916	// non-interface field appearing in ForceSendFields will be sent to the
10917	// server regardless of whether the field is empty or not. This may be
10918	// used to include empty fields in Patch requests.
10919	ForceSendFields []string `json:"-"`
10920
10921	// NullFields is a list of field names (e.g. "CapCostOption") to include
10922	// in API requests with the JSON null value. By default, fields with
10923	// empty values are omitted from API requests. However, any field with
10924	// an empty value appearing in NullFields will be sent to the server as
10925	// null. It is an error if a field in this list has a non-empty value.
10926	// This may be used to include null fields in Patch requests.
10927	NullFields []string `json:"-"`
10928}
10929
10930func (s *PricingSchedule) MarshalJSON() ([]byte, error) {
10931	type NoMethod PricingSchedule
10932	raw := NoMethod(*s)
10933	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10934}
10935
10936// PricingSchedulePricingPeriod: Pricing Period
10937type PricingSchedulePricingPeriod struct {
10938	// EndDate: Pricing period end date. This date must be later than, or
10939	// the same day as, the pricing period start date, but not later than
10940	// the placement end date. The period end date can be the same date as
10941	// the period start date. If, for example, you set 6/25/2015 as both the
10942	// start and end dates, the effective pricing period date is just that
10943	// day only, 6/25/2015. The hours, minutes, and seconds of the end date
10944	// should not be set, as doing so will result in an error.
10945	EndDate string `json:"endDate,omitempty"`
10946
10947	// PricingComment: Comments for this pricing period.
10948	PricingComment string `json:"pricingComment,omitempty"`
10949
10950	// RateOrCostNanos: Rate or cost of this pricing period in nanos (i.e.,
10951	// multipled by 1000000000). Acceptable values are 0 to
10952	// 1000000000000000000, inclusive.
10953	RateOrCostNanos int64 `json:"rateOrCostNanos,omitempty,string"`
10954
10955	// StartDate: Pricing period start date. This date must be later than,
10956	// or the same day as, the placement start date. The hours, minutes, and
10957	// seconds of the start date should not be set, as doing so will result
10958	// in an error.
10959	StartDate string `json:"startDate,omitempty"`
10960
10961	// Units: Units of this pricing period. Acceptable values are 0 to
10962	// 10000000000, inclusive.
10963	Units int64 `json:"units,omitempty,string"`
10964
10965	// ForceSendFields is a list of field names (e.g. "EndDate") to
10966	// unconditionally include in API requests. By default, fields with
10967	// empty values are omitted from API requests. However, any non-pointer,
10968	// non-interface field appearing in ForceSendFields will be sent to the
10969	// server regardless of whether the field is empty or not. This may be
10970	// used to include empty fields in Patch requests.
10971	ForceSendFields []string `json:"-"`
10972
10973	// NullFields is a list of field names (e.g. "EndDate") to include in
10974	// API requests with the JSON null value. By default, fields with empty
10975	// values are omitted from API requests. However, any field with an
10976	// empty value appearing in NullFields will be sent to the server as
10977	// null. It is an error if a field in this list has a non-empty value.
10978	// This may be used to include null fields in Patch requests.
10979	NullFields []string `json:"-"`
10980}
10981
10982func (s *PricingSchedulePricingPeriod) MarshalJSON() ([]byte, error) {
10983	type NoMethod PricingSchedulePricingPeriod
10984	raw := NoMethod(*s)
10985	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10986}
10987
10988// Project: Contains properties of a Planning project.
10989type Project struct {
10990	// AccountId: Account ID of this project.
10991	AccountId int64 `json:"accountId,omitempty,string"`
10992
10993	// AdvertiserId: Advertiser ID of this project.
10994	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
10995
10996	// AudienceAgeGroup: Audience age group of this project.
10997	//
10998	// Possible values:
10999	//   "PLANNING_AUDIENCE_AGE_18_24"
11000	//   "PLANNING_AUDIENCE_AGE_25_34"
11001	//   "PLANNING_AUDIENCE_AGE_35_44"
11002	//   "PLANNING_AUDIENCE_AGE_45_54"
11003	//   "PLANNING_AUDIENCE_AGE_55_64"
11004	//   "PLANNING_AUDIENCE_AGE_65_OR_MORE"
11005	//   "PLANNING_AUDIENCE_AGE_UNKNOWN"
11006	AudienceAgeGroup string `json:"audienceAgeGroup,omitempty"`
11007
11008	// AudienceGender: Audience gender of this project.
11009	//
11010	// Possible values:
11011	//   "PLANNING_AUDIENCE_GENDER_FEMALE"
11012	//   "PLANNING_AUDIENCE_GENDER_MALE"
11013	AudienceGender string `json:"audienceGender,omitempty"`
11014
11015	// Budget: Budget of this project in the currency specified by the
11016	// current account. The value stored in this field represents only the
11017	// non-fractional amount. For example, for USD, the smallest value that
11018	// can be represented by this field is 1 US dollar.
11019	Budget int64 `json:"budget,omitempty,string"`
11020
11021	// ClientBillingCode: Client billing code of this project.
11022	ClientBillingCode string `json:"clientBillingCode,omitempty"`
11023
11024	// ClientName: Name of the project client.
11025	ClientName string `json:"clientName,omitempty"`
11026
11027	// EndDate: End date of the project.
11028	EndDate string `json:"endDate,omitempty"`
11029
11030	// Id: ID of this project. This is a read-only, auto-generated field.
11031	Id int64 `json:"id,omitempty,string"`
11032
11033	// Kind: Identifies what kind of resource this is. Value: the fixed
11034	// string "dfareporting#project".
11035	Kind string `json:"kind,omitempty"`
11036
11037	// LastModifiedInfo: Information about the most recent modification of
11038	// this project.
11039	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
11040
11041	// Name: Name of this project.
11042	Name string `json:"name,omitempty"`
11043
11044	// Overview: Overview of this project.
11045	Overview string `json:"overview,omitempty"`
11046
11047	// StartDate: Start date of the project.
11048	StartDate string `json:"startDate,omitempty"`
11049
11050	// SubaccountId: Subaccount ID of this project.
11051	SubaccountId int64 `json:"subaccountId,omitempty,string"`
11052
11053	// TargetClicks: Number of clicks that the advertiser is targeting.
11054	TargetClicks int64 `json:"targetClicks,omitempty,string"`
11055
11056	// TargetConversions: Number of conversions that the advertiser is
11057	// targeting.
11058	TargetConversions int64 `json:"targetConversions,omitempty,string"`
11059
11060	// TargetCpaNanos: CPA that the advertiser is targeting.
11061	TargetCpaNanos int64 `json:"targetCpaNanos,omitempty,string"`
11062
11063	// TargetCpcNanos: CPC that the advertiser is targeting.
11064	TargetCpcNanos int64 `json:"targetCpcNanos,omitempty,string"`
11065
11066	// TargetCpmActiveViewNanos: vCPM from Active View that the advertiser
11067	// is targeting.
11068	TargetCpmActiveViewNanos int64 `json:"targetCpmActiveViewNanos,omitempty,string"`
11069
11070	// TargetCpmNanos: CPM that the advertiser is targeting.
11071	TargetCpmNanos int64 `json:"targetCpmNanos,omitempty,string"`
11072
11073	// TargetImpressions: Number of impressions that the advertiser is
11074	// targeting.
11075	TargetImpressions int64 `json:"targetImpressions,omitempty,string"`
11076
11077	// ServerResponse contains the HTTP response code and headers from the
11078	// server.
11079	googleapi.ServerResponse `json:"-"`
11080
11081	// ForceSendFields is a list of field names (e.g. "AccountId") to
11082	// unconditionally include in API requests. By default, fields with
11083	// empty values are omitted from API requests. However, any non-pointer,
11084	// non-interface field appearing in ForceSendFields will be sent to the
11085	// server regardless of whether the field is empty or not. This may be
11086	// used to include empty fields in Patch requests.
11087	ForceSendFields []string `json:"-"`
11088
11089	// NullFields is a list of field names (e.g. "AccountId") to include in
11090	// API requests with the JSON null value. By default, fields with empty
11091	// values are omitted from API requests. However, any field with an
11092	// empty value appearing in NullFields will be sent to the server as
11093	// null. It is an error if a field in this list has a non-empty value.
11094	// This may be used to include null fields in Patch requests.
11095	NullFields []string `json:"-"`
11096}
11097
11098func (s *Project) MarshalJSON() ([]byte, error) {
11099	type NoMethod Project
11100	raw := NoMethod(*s)
11101	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11102}
11103
11104// ProjectsListResponse: Project List Response
11105type ProjectsListResponse struct {
11106	// Kind: Identifies what kind of resource this is. Value: the fixed
11107	// string "dfareporting#projectsListResponse".
11108	Kind string `json:"kind,omitempty"`
11109
11110	// NextPageToken: Pagination token to be used for the next list
11111	// operation.
11112	NextPageToken string `json:"nextPageToken,omitempty"`
11113
11114	// Projects: Project collection.
11115	Projects []*Project `json:"projects,omitempty"`
11116
11117	// ServerResponse contains the HTTP response code and headers from the
11118	// server.
11119	googleapi.ServerResponse `json:"-"`
11120
11121	// ForceSendFields is a list of field names (e.g. "Kind") to
11122	// unconditionally include in API requests. By default, fields with
11123	// empty values are omitted from API requests. However, any non-pointer,
11124	// non-interface field appearing in ForceSendFields will be sent to the
11125	// server regardless of whether the field is empty or not. This may be
11126	// used to include empty fields in Patch requests.
11127	ForceSendFields []string `json:"-"`
11128
11129	// NullFields is a list of field names (e.g. "Kind") to include in API
11130	// requests with the JSON null value. By default, fields with empty
11131	// values are omitted from API requests. However, any field with an
11132	// empty value appearing in NullFields will be sent to the server as
11133	// null. It is an error if a field in this list has a non-empty value.
11134	// This may be used to include null fields in Patch requests.
11135	NullFields []string `json:"-"`
11136}
11137
11138func (s *ProjectsListResponse) MarshalJSON() ([]byte, error) {
11139	type NoMethod ProjectsListResponse
11140	raw := NoMethod(*s)
11141	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11142}
11143
11144// ReachReportCompatibleFields: Represents fields that are compatible to
11145// be selected for a report of type "REACH".
11146type ReachReportCompatibleFields struct {
11147	// DimensionFilters: Dimensions which are compatible to be selected in
11148	// the "dimensionFilters" section of the report.
11149	DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
11150
11151	// Dimensions: Dimensions which are compatible to be selected in the
11152	// "dimensions" section of the report.
11153	Dimensions []*Dimension `json:"dimensions,omitempty"`
11154
11155	// Kind: The kind of resource this is, in this case
11156	// dfareporting#reachReportCompatibleFields.
11157	Kind string `json:"kind,omitempty"`
11158
11159	// Metrics: Metrics which are compatible to be selected in the
11160	// "metricNames" section of the report.
11161	Metrics []*Metric `json:"metrics,omitempty"`
11162
11163	// PivotedActivityMetrics: Metrics which are compatible to be selected
11164	// as activity metrics to pivot on in the "activities" section of the
11165	// report.
11166	PivotedActivityMetrics []*Metric `json:"pivotedActivityMetrics,omitempty"`
11167
11168	// ReachByFrequencyMetrics: Metrics which are compatible to be selected
11169	// in the "reachByFrequencyMetricNames" section of the report.
11170	ReachByFrequencyMetrics []*Metric `json:"reachByFrequencyMetrics,omitempty"`
11171
11172	// ForceSendFields is a list of field names (e.g. "DimensionFilters") to
11173	// unconditionally include in API requests. By default, fields with
11174	// empty values are omitted from API requests. However, any non-pointer,
11175	// non-interface field appearing in ForceSendFields will be sent to the
11176	// server regardless of whether the field is empty or not. This may be
11177	// used to include empty fields in Patch requests.
11178	ForceSendFields []string `json:"-"`
11179
11180	// NullFields is a list of field names (e.g. "DimensionFilters") to
11181	// include in API requests with the JSON null value. By default, fields
11182	// with empty values are omitted from API requests. However, any field
11183	// with an empty value appearing in NullFields will be sent to the
11184	// server as null. It is an error if a field in this list has a
11185	// non-empty value. This may be used to include null fields in Patch
11186	// requests.
11187	NullFields []string `json:"-"`
11188}
11189
11190func (s *ReachReportCompatibleFields) MarshalJSON() ([]byte, error) {
11191	type NoMethod ReachReportCompatibleFields
11192	raw := NoMethod(*s)
11193	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11194}
11195
11196// Recipient: Represents a recipient.
11197type Recipient struct {
11198	// DeliveryType: The delivery type for the recipient.
11199	//
11200	// Possible values:
11201	//   "ATTACHMENT"
11202	//   "LINK"
11203	DeliveryType string `json:"deliveryType,omitempty"`
11204
11205	// Email: The email address of the recipient.
11206	Email string `json:"email,omitempty"`
11207
11208	// Kind: The kind of resource this is, in this case
11209	// dfareporting#recipient.
11210	Kind string `json:"kind,omitempty"`
11211
11212	// ForceSendFields is a list of field names (e.g. "DeliveryType") to
11213	// unconditionally include in API requests. By default, fields with
11214	// empty values are omitted from API requests. However, any non-pointer,
11215	// non-interface field appearing in ForceSendFields will be sent to the
11216	// server regardless of whether the field is empty or not. This may be
11217	// used to include empty fields in Patch requests.
11218	ForceSendFields []string `json:"-"`
11219
11220	// NullFields is a list of field names (e.g. "DeliveryType") to include
11221	// in API requests with the JSON null value. By default, fields with
11222	// empty values are omitted from API requests. However, any field with
11223	// an empty value appearing in NullFields will be sent to the server as
11224	// null. It is an error if a field in this list has a non-empty value.
11225	// This may be used to include null fields in Patch requests.
11226	NullFields []string `json:"-"`
11227}
11228
11229func (s *Recipient) MarshalJSON() ([]byte, error) {
11230	type NoMethod Recipient
11231	raw := NoMethod(*s)
11232	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11233}
11234
11235// Region: Contains information about a region that can be targeted by
11236// ads.
11237type Region struct {
11238	// CountryCode: Country code of the country to which this region
11239	// belongs.
11240	CountryCode string `json:"countryCode,omitempty"`
11241
11242	// CountryDartId: DART ID of the country to which this region belongs.
11243	CountryDartId int64 `json:"countryDartId,omitempty,string"`
11244
11245	// DartId: DART ID of this region.
11246	DartId int64 `json:"dartId,omitempty,string"`
11247
11248	// Kind: Identifies what kind of resource this is. Value: the fixed
11249	// string "dfareporting#region".
11250	Kind string `json:"kind,omitempty"`
11251
11252	// Name: Name of this region.
11253	Name string `json:"name,omitempty"`
11254
11255	// RegionCode: Region code.
11256	RegionCode string `json:"regionCode,omitempty"`
11257
11258	// ForceSendFields is a list of field names (e.g. "CountryCode") to
11259	// unconditionally include in API requests. By default, fields with
11260	// empty values are omitted from API requests. However, any non-pointer,
11261	// non-interface field appearing in ForceSendFields will be sent to the
11262	// server regardless of whether the field is empty or not. This may be
11263	// used to include empty fields in Patch requests.
11264	ForceSendFields []string `json:"-"`
11265
11266	// NullFields is a list of field names (e.g. "CountryCode") to include
11267	// in API requests with the JSON null value. By default, fields with
11268	// empty values are omitted from API requests. However, any field with
11269	// an empty value appearing in NullFields will be sent to the server as
11270	// null. It is an error if a field in this list has a non-empty value.
11271	// This may be used to include null fields in Patch requests.
11272	NullFields []string `json:"-"`
11273}
11274
11275func (s *Region) MarshalJSON() ([]byte, error) {
11276	type NoMethod Region
11277	raw := NoMethod(*s)
11278	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11279}
11280
11281// RegionsListResponse: Region List Response
11282type RegionsListResponse struct {
11283	// Kind: Identifies what kind of resource this is. Value: the fixed
11284	// string "dfareporting#regionsListResponse".
11285	Kind string `json:"kind,omitempty"`
11286
11287	// Regions: Region collection.
11288	Regions []*Region `json:"regions,omitempty"`
11289
11290	// ServerResponse contains the HTTP response code and headers from the
11291	// server.
11292	googleapi.ServerResponse `json:"-"`
11293
11294	// ForceSendFields is a list of field names (e.g. "Kind") to
11295	// unconditionally include in API requests. By default, fields with
11296	// empty values are omitted from API requests. However, any non-pointer,
11297	// non-interface field appearing in ForceSendFields will be sent to the
11298	// server regardless of whether the field is empty or not. This may be
11299	// used to include empty fields in Patch requests.
11300	ForceSendFields []string `json:"-"`
11301
11302	// NullFields is a list of field names (e.g. "Kind") to include in API
11303	// requests with the JSON null value. By default, fields with empty
11304	// values are omitted from API requests. However, any field with an
11305	// empty value appearing in NullFields will be sent to the server as
11306	// null. It is an error if a field in this list has a non-empty value.
11307	// This may be used to include null fields in Patch requests.
11308	NullFields []string `json:"-"`
11309}
11310
11311func (s *RegionsListResponse) MarshalJSON() ([]byte, error) {
11312	type NoMethod RegionsListResponse
11313	raw := NoMethod(*s)
11314	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11315}
11316
11317// RemarketingList: Contains properties of a remarketing list.
11318// Remarketing enables you to create lists of users who have performed
11319// specific actions on a site, then target ads to members of those
11320// lists. This resource can be used to manage remarketing lists that are
11321// owned by your advertisers. To see all remarketing lists that are
11322// visible to your advertisers, including those that are shared to your
11323// advertiser or account, use the TargetableRemarketingLists resource.
11324type RemarketingList struct {
11325	// AccountId: Account ID of this remarketing list. This is a read-only,
11326	// auto-generated field that is only returned in GET requests.
11327	AccountId int64 `json:"accountId,omitempty,string"`
11328
11329	// Active: Whether this remarketing list is active.
11330	Active bool `json:"active,omitempty"`
11331
11332	// AdvertiserId: Dimension value for the advertiser ID that owns this
11333	// remarketing list. This is a required field.
11334	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
11335
11336	// AdvertiserIdDimensionValue: Dimension value for the ID of the
11337	// advertiser. This is a read-only, auto-generated field.
11338	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
11339
11340	// Description: Remarketing list description.
11341	Description string `json:"description,omitempty"`
11342
11343	// Id: Remarketing list ID. This is a read-only, auto-generated field.
11344	Id int64 `json:"id,omitempty,string"`
11345
11346	// Kind: Identifies what kind of resource this is. Value: the fixed
11347	// string "dfareporting#remarketingList".
11348	Kind string `json:"kind,omitempty"`
11349
11350	// LifeSpan: Number of days that a user should remain in the remarketing
11351	// list without an impression. Acceptable values are 1 to 540,
11352	// inclusive.
11353	LifeSpan int64 `json:"lifeSpan,omitempty,string"`
11354
11355	// ListPopulationRule: Rule used to populate the remarketing list with
11356	// users.
11357	ListPopulationRule *ListPopulationRule `json:"listPopulationRule,omitempty"`
11358
11359	// ListSize: Number of users currently in the list. This is a read-only
11360	// field.
11361	ListSize int64 `json:"listSize,omitempty,string"`
11362
11363	// ListSource: Product from which this remarketing list was originated.
11364	//
11365	// Possible values:
11366	//   "REMARKETING_LIST_SOURCE_ADX"
11367	//   "REMARKETING_LIST_SOURCE_DBM"
11368	//   "REMARKETING_LIST_SOURCE_DFA"
11369	//   "REMARKETING_LIST_SOURCE_DFP"
11370	//   "REMARKETING_LIST_SOURCE_DMP"
11371	//   "REMARKETING_LIST_SOURCE_GA"
11372	//   "REMARKETING_LIST_SOURCE_GPLUS"
11373	//   "REMARKETING_LIST_SOURCE_OTHER"
11374	//   "REMARKETING_LIST_SOURCE_PLAY_STORE"
11375	//   "REMARKETING_LIST_SOURCE_XFP"
11376	//   "REMARKETING_LIST_SOURCE_YOUTUBE"
11377	ListSource string `json:"listSource,omitempty"`
11378
11379	// Name: Name of the remarketing list. This is a required field. Must be
11380	// no greater than 128 characters long.
11381	Name string `json:"name,omitempty"`
11382
11383	// SubaccountId: Subaccount ID of this remarketing list. This is a
11384	// read-only, auto-generated field that is only returned in GET
11385	// requests.
11386	SubaccountId int64 `json:"subaccountId,omitempty,string"`
11387
11388	// ServerResponse contains the HTTP response code and headers from the
11389	// server.
11390	googleapi.ServerResponse `json:"-"`
11391
11392	// ForceSendFields is a list of field names (e.g. "AccountId") to
11393	// unconditionally include in API requests. By default, fields with
11394	// empty values are omitted from API requests. However, any non-pointer,
11395	// non-interface field appearing in ForceSendFields will be sent to the
11396	// server regardless of whether the field is empty or not. This may be
11397	// used to include empty fields in Patch requests.
11398	ForceSendFields []string `json:"-"`
11399
11400	// NullFields is a list of field names (e.g. "AccountId") to include in
11401	// API requests with the JSON null value. By default, fields with empty
11402	// values are omitted from API requests. However, any field with an
11403	// empty value appearing in NullFields will be sent to the server as
11404	// null. It is an error if a field in this list has a non-empty value.
11405	// This may be used to include null fields in Patch requests.
11406	NullFields []string `json:"-"`
11407}
11408
11409func (s *RemarketingList) MarshalJSON() ([]byte, error) {
11410	type NoMethod RemarketingList
11411	raw := NoMethod(*s)
11412	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11413}
11414
11415// RemarketingListShare: Contains properties of a remarketing list's
11416// sharing information. Sharing allows other accounts or advertisers to
11417// target to your remarketing lists. This resource can be used to manage
11418// remarketing list sharing to other accounts and advertisers.
11419type RemarketingListShare struct {
11420	// Kind: Identifies what kind of resource this is. Value: the fixed
11421	// string "dfareporting#remarketingListShare".
11422	Kind string `json:"kind,omitempty"`
11423
11424	// RemarketingListId: Remarketing list ID. This is a read-only,
11425	// auto-generated field.
11426	RemarketingListId int64 `json:"remarketingListId,omitempty,string"`
11427
11428	// SharedAccountIds: Accounts that the remarketing list is shared with.
11429	SharedAccountIds googleapi.Int64s `json:"sharedAccountIds,omitempty"`
11430
11431	// SharedAdvertiserIds: Advertisers that the remarketing list is shared
11432	// with.
11433	SharedAdvertiserIds googleapi.Int64s `json:"sharedAdvertiserIds,omitempty"`
11434
11435	// ServerResponse contains the HTTP response code and headers from the
11436	// server.
11437	googleapi.ServerResponse `json:"-"`
11438
11439	// ForceSendFields is a list of field names (e.g. "Kind") to
11440	// unconditionally include in API requests. By default, fields with
11441	// empty values are omitted from API requests. However, any non-pointer,
11442	// non-interface field appearing in ForceSendFields will be sent to the
11443	// server regardless of whether the field is empty or not. This may be
11444	// used to include empty fields in Patch requests.
11445	ForceSendFields []string `json:"-"`
11446
11447	// NullFields is a list of field names (e.g. "Kind") to include in API
11448	// requests with the JSON null value. By default, fields with empty
11449	// values are omitted from API requests. However, any field with an
11450	// empty value appearing in NullFields will be sent to the server as
11451	// null. It is an error if a field in this list has a non-empty value.
11452	// This may be used to include null fields in Patch requests.
11453	NullFields []string `json:"-"`
11454}
11455
11456func (s *RemarketingListShare) MarshalJSON() ([]byte, error) {
11457	type NoMethod RemarketingListShare
11458	raw := NoMethod(*s)
11459	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11460}
11461
11462// RemarketingListsListResponse: Remarketing list response
11463type RemarketingListsListResponse struct {
11464	// Kind: Identifies what kind of resource this is. Value: the fixed
11465	// string "dfareporting#remarketingListsListResponse".
11466	Kind string `json:"kind,omitempty"`
11467
11468	// NextPageToken: Pagination token to be used for the next list
11469	// operation.
11470	NextPageToken string `json:"nextPageToken,omitempty"`
11471
11472	// RemarketingLists: Remarketing list collection.
11473	RemarketingLists []*RemarketingList `json:"remarketingLists,omitempty"`
11474
11475	// ServerResponse contains the HTTP response code and headers from the
11476	// server.
11477	googleapi.ServerResponse `json:"-"`
11478
11479	// ForceSendFields is a list of field names (e.g. "Kind") to
11480	// unconditionally include in API requests. By default, fields with
11481	// empty values are omitted from API requests. However, any non-pointer,
11482	// non-interface field appearing in ForceSendFields will be sent to the
11483	// server regardless of whether the field is empty or not. This may be
11484	// used to include empty fields in Patch requests.
11485	ForceSendFields []string `json:"-"`
11486
11487	// NullFields is a list of field names (e.g. "Kind") to include in API
11488	// requests with the JSON null value. By default, fields with empty
11489	// values are omitted from API requests. However, any field with an
11490	// empty value appearing in NullFields will be sent to the server as
11491	// null. It is an error if a field in this list has a non-empty value.
11492	// This may be used to include null fields in Patch requests.
11493	NullFields []string `json:"-"`
11494}
11495
11496func (s *RemarketingListsListResponse) MarshalJSON() ([]byte, error) {
11497	type NoMethod RemarketingListsListResponse
11498	raw := NoMethod(*s)
11499	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11500}
11501
11502// Report: Represents a Report resource.
11503type Report struct {
11504	// AccountId: The account ID to which this report belongs.
11505	AccountId int64 `json:"accountId,omitempty,string"`
11506
11507	// Criteria: The report criteria for a report of type "STANDARD".
11508	Criteria *ReportCriteria `json:"criteria,omitempty"`
11509
11510	// CrossDimensionReachCriteria: The report criteria for a report of type
11511	// "CROSS_DIMENSION_REACH".
11512	CrossDimensionReachCriteria *ReportCrossDimensionReachCriteria `json:"crossDimensionReachCriteria,omitempty"`
11513
11514	// Delivery: The report's email delivery settings.
11515	Delivery *ReportDelivery `json:"delivery,omitempty"`
11516
11517	// Etag: The eTag of this response for caching purposes.
11518	Etag string `json:"etag,omitempty"`
11519
11520	// FileName: The filename used when generating report files for this
11521	// report.
11522	FileName string `json:"fileName,omitempty"`
11523
11524	// FloodlightCriteria: The report criteria for a report of type
11525	// "FLOODLIGHT".
11526	FloodlightCriteria *ReportFloodlightCriteria `json:"floodlightCriteria,omitempty"`
11527
11528	// Format: The output format of the report. If not specified, default
11529	// format is "CSV". Note that the actual format in the completed report
11530	// file might differ if for instance the report's size exceeds the
11531	// format's capabilities. "CSV" will then be the fallback format.
11532	//
11533	// Possible values:
11534	//   "CSV"
11535	//   "EXCEL"
11536	Format string `json:"format,omitempty"`
11537
11538	// Id: The unique ID identifying this report resource.
11539	Id int64 `json:"id,omitempty,string"`
11540
11541	// Kind: The kind of resource this is, in this case dfareporting#report.
11542	Kind string `json:"kind,omitempty"`
11543
11544	// LastModifiedTime: The timestamp (in milliseconds since epoch) of when
11545	// this report was last modified.
11546	LastModifiedTime uint64 `json:"lastModifiedTime,omitempty,string"`
11547
11548	// Name: The name of the report.
11549	Name string `json:"name,omitempty"`
11550
11551	// OwnerProfileId: The user profile id of the owner of this report.
11552	OwnerProfileId int64 `json:"ownerProfileId,omitempty,string"`
11553
11554	// PathToConversionCriteria: The report criteria for a report of type
11555	// "PATH_TO_CONVERSION".
11556	PathToConversionCriteria *ReportPathToConversionCriteria `json:"pathToConversionCriteria,omitempty"`
11557
11558	// ReachCriteria: The report criteria for a report of type "REACH".
11559	ReachCriteria *ReportReachCriteria `json:"reachCriteria,omitempty"`
11560
11561	// Schedule: The report's schedule. Can only be set if the report's
11562	// 'dateRange' is a relative date range and the relative date range is
11563	// not "TODAY".
11564	Schedule *ReportSchedule `json:"schedule,omitempty"`
11565
11566	// SubAccountId: The subaccount ID to which this report belongs if
11567	// applicable.
11568	SubAccountId int64 `json:"subAccountId,omitempty,string"`
11569
11570	// Type: The type of the report.
11571	//
11572	// Possible values:
11573	//   "CROSS_DIMENSION_REACH"
11574	//   "FLOODLIGHT"
11575	//   "PATH_TO_CONVERSION"
11576	//   "REACH"
11577	//   "STANDARD"
11578	Type string `json:"type,omitempty"`
11579
11580	// ServerResponse contains the HTTP response code and headers from the
11581	// server.
11582	googleapi.ServerResponse `json:"-"`
11583
11584	// ForceSendFields is a list of field names (e.g. "AccountId") to
11585	// unconditionally include in API requests. By default, fields with
11586	// empty values are omitted from API requests. However, any non-pointer,
11587	// non-interface field appearing in ForceSendFields will be sent to the
11588	// server regardless of whether the field is empty or not. This may be
11589	// used to include empty fields in Patch requests.
11590	ForceSendFields []string `json:"-"`
11591
11592	// NullFields is a list of field names (e.g. "AccountId") to include in
11593	// API requests with the JSON null value. By default, fields with empty
11594	// values are omitted from API requests. However, any field with an
11595	// empty value appearing in NullFields will be sent to the server as
11596	// null. It is an error if a field in this list has a non-empty value.
11597	// This may be used to include null fields in Patch requests.
11598	NullFields []string `json:"-"`
11599}
11600
11601func (s *Report) MarshalJSON() ([]byte, error) {
11602	type NoMethod Report
11603	raw := NoMethod(*s)
11604	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11605}
11606
11607// ReportCriteria: The report criteria for a report of type "STANDARD".
11608type ReportCriteria struct {
11609	// Activities: Activity group.
11610	Activities *Activities `json:"activities,omitempty"`
11611
11612	// CustomRichMediaEvents: Custom Rich Media Events group.
11613	CustomRichMediaEvents *CustomRichMediaEvents `json:"customRichMediaEvents,omitempty"`
11614
11615	// DateRange: The date range for which this report should be run.
11616	DateRange *DateRange `json:"dateRange,omitempty"`
11617
11618	// DimensionFilters: The list of filters on which dimensions are
11619	// filtered.
11620	// Filters for different dimensions are ANDed, filters for the same
11621	// dimension are grouped together and ORed.
11622	DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11623
11624	// Dimensions: The list of standard dimensions the report should
11625	// include.
11626	Dimensions []*SortedDimension `json:"dimensions,omitempty"`
11627
11628	// MetricNames: The list of names of metrics the report should include.
11629	MetricNames []string `json:"metricNames,omitempty"`
11630
11631	// ForceSendFields is a list of field names (e.g. "Activities") to
11632	// unconditionally include in API requests. By default, fields with
11633	// empty values are omitted from API requests. However, any non-pointer,
11634	// non-interface field appearing in ForceSendFields will be sent to the
11635	// server regardless of whether the field is empty or not. This may be
11636	// used to include empty fields in Patch requests.
11637	ForceSendFields []string `json:"-"`
11638
11639	// NullFields is a list of field names (e.g. "Activities") to include in
11640	// API requests with the JSON null value. By default, fields with empty
11641	// values are omitted from API requests. However, any field with an
11642	// empty value appearing in NullFields will be sent to the server as
11643	// null. It is an error if a field in this list has a non-empty value.
11644	// This may be used to include null fields in Patch requests.
11645	NullFields []string `json:"-"`
11646}
11647
11648func (s *ReportCriteria) MarshalJSON() ([]byte, error) {
11649	type NoMethod ReportCriteria
11650	raw := NoMethod(*s)
11651	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11652}
11653
11654// ReportCrossDimensionReachCriteria: The report criteria for a report
11655// of type "CROSS_DIMENSION_REACH".
11656type ReportCrossDimensionReachCriteria struct {
11657	// Breakdown: The list of dimensions the report should include.
11658	Breakdown []*SortedDimension `json:"breakdown,omitempty"`
11659
11660	// DateRange: The date range this report should be run for.
11661	DateRange *DateRange `json:"dateRange,omitempty"`
11662
11663	// Dimension: The dimension option.
11664	//
11665	// Possible values:
11666	//   "ADVERTISER"
11667	//   "CAMPAIGN"
11668	//   "SITE_BY_ADVERTISER"
11669	//   "SITE_BY_CAMPAIGN"
11670	Dimension string `json:"dimension,omitempty"`
11671
11672	// DimensionFilters: The list of filters on which dimensions are
11673	// filtered.
11674	DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11675
11676	// MetricNames: The list of names of metrics the report should include.
11677	MetricNames []string `json:"metricNames,omitempty"`
11678
11679	// OverlapMetricNames: The list of names of overlap metrics the report
11680	// should include.
11681	OverlapMetricNames []string `json:"overlapMetricNames,omitempty"`
11682
11683	// Pivoted: Whether the report is pivoted or not. Defaults to true.
11684	Pivoted bool `json:"pivoted,omitempty"`
11685
11686	// ForceSendFields is a list of field names (e.g. "Breakdown") to
11687	// unconditionally include in API requests. By default, fields with
11688	// empty values are omitted from API requests. However, any non-pointer,
11689	// non-interface field appearing in ForceSendFields will be sent to the
11690	// server regardless of whether the field is empty or not. This may be
11691	// used to include empty fields in Patch requests.
11692	ForceSendFields []string `json:"-"`
11693
11694	// NullFields is a list of field names (e.g. "Breakdown") to include in
11695	// API requests with the JSON null value. By default, fields with empty
11696	// values are omitted from API requests. However, any field with an
11697	// empty value appearing in NullFields will be sent to the server as
11698	// null. It is an error if a field in this list has a non-empty value.
11699	// This may be used to include null fields in Patch requests.
11700	NullFields []string `json:"-"`
11701}
11702
11703func (s *ReportCrossDimensionReachCriteria) MarshalJSON() ([]byte, error) {
11704	type NoMethod ReportCrossDimensionReachCriteria
11705	raw := NoMethod(*s)
11706	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11707}
11708
11709// ReportDelivery: The report's email delivery settings.
11710type ReportDelivery struct {
11711	// EmailOwner: Whether the report should be emailed to the report owner.
11712	EmailOwner bool `json:"emailOwner,omitempty"`
11713
11714	// EmailOwnerDeliveryType: The type of delivery for the owner to
11715	// receive, if enabled.
11716	//
11717	// Possible values:
11718	//   "ATTACHMENT"
11719	//   "LINK"
11720	EmailOwnerDeliveryType string `json:"emailOwnerDeliveryType,omitempty"`
11721
11722	// Message: The message to be sent with each email.
11723	Message string `json:"message,omitempty"`
11724
11725	// Recipients: The list of recipients to which to email the report.
11726	Recipients []*Recipient `json:"recipients,omitempty"`
11727
11728	// ForceSendFields is a list of field names (e.g. "EmailOwner") to
11729	// unconditionally include in API requests. By default, fields with
11730	// empty values are omitted from API requests. However, any non-pointer,
11731	// non-interface field appearing in ForceSendFields will be sent to the
11732	// server regardless of whether the field is empty or not. This may be
11733	// used to include empty fields in Patch requests.
11734	ForceSendFields []string `json:"-"`
11735
11736	// NullFields is a list of field names (e.g. "EmailOwner") to include in
11737	// API requests with the JSON null value. By default, fields with empty
11738	// values are omitted from API requests. However, any field with an
11739	// empty value appearing in NullFields will be sent to the server as
11740	// null. It is an error if a field in this list has a non-empty value.
11741	// This may be used to include null fields in Patch requests.
11742	NullFields []string `json:"-"`
11743}
11744
11745func (s *ReportDelivery) MarshalJSON() ([]byte, error) {
11746	type NoMethod ReportDelivery
11747	raw := NoMethod(*s)
11748	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11749}
11750
11751// ReportFloodlightCriteria: The report criteria for a report of type
11752// "FLOODLIGHT".
11753type ReportFloodlightCriteria struct {
11754	// CustomRichMediaEvents: The list of custom rich media events to
11755	// include.
11756	CustomRichMediaEvents []*DimensionValue `json:"customRichMediaEvents,omitempty"`
11757
11758	// DateRange: The date range this report should be run for.
11759	DateRange *DateRange `json:"dateRange,omitempty"`
11760
11761	// DimensionFilters: The list of filters on which dimensions are
11762	// filtered.
11763	// Filters for different dimensions are ANDed, filters for the same
11764	// dimension are grouped together and ORed.
11765	DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11766
11767	// Dimensions: The list of dimensions the report should include.
11768	Dimensions []*SortedDimension `json:"dimensions,omitempty"`
11769
11770	// FloodlightConfigId: The floodlight ID for which to show data in this
11771	// report. All advertisers associated with that ID will automatically be
11772	// added. The dimension of the value needs to be
11773	// 'dfa:floodlightConfigId'.
11774	FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
11775
11776	// MetricNames: The list of names of metrics the report should include.
11777	MetricNames []string `json:"metricNames,omitempty"`
11778
11779	// ReportProperties: The properties of the report.
11780	ReportProperties *ReportFloodlightCriteriaReportProperties `json:"reportProperties,omitempty"`
11781
11782	// ForceSendFields is a list of field names (e.g.
11783	// "CustomRichMediaEvents") to unconditionally include in API requests.
11784	// By default, fields with empty values are omitted from API requests.
11785	// However, any non-pointer, non-interface field appearing in
11786	// ForceSendFields will be sent to the server regardless of whether the
11787	// field is empty or not. This may be used to include empty fields in
11788	// Patch requests.
11789	ForceSendFields []string `json:"-"`
11790
11791	// NullFields is a list of field names (e.g. "CustomRichMediaEvents") to
11792	// include in API requests with the JSON null value. By default, fields
11793	// with empty values are omitted from API requests. However, any field
11794	// with an empty value appearing in NullFields will be sent to the
11795	// server as null. It is an error if a field in this list has a
11796	// non-empty value. This may be used to include null fields in Patch
11797	// requests.
11798	NullFields []string `json:"-"`
11799}
11800
11801func (s *ReportFloodlightCriteria) MarshalJSON() ([]byte, error) {
11802	type NoMethod ReportFloodlightCriteria
11803	raw := NoMethod(*s)
11804	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11805}
11806
11807// ReportFloodlightCriteriaReportProperties: The properties of the
11808// report.
11809type ReportFloodlightCriteriaReportProperties struct {
11810	// IncludeAttributedIPConversions: Include conversions that have no
11811	// cookie, but do have an exposure path.
11812	IncludeAttributedIPConversions bool `json:"includeAttributedIPConversions,omitempty"`
11813
11814	// IncludeUnattributedCookieConversions: Include conversions of users
11815	// with a DoubleClick cookie but without an exposure. That means the
11816	// user did not click or see an ad from the advertiser within the
11817	// Floodlight group, or that the interaction happened outside the
11818	// lookback window.
11819	IncludeUnattributedCookieConversions bool `json:"includeUnattributedCookieConversions,omitempty"`
11820
11821	// IncludeUnattributedIPConversions: Include conversions that have no
11822	// associated cookies and no exposures. It’s therefore impossible to
11823	// know how the user was exposed to your ads during the lookback window
11824	// prior to a conversion.
11825	IncludeUnattributedIPConversions bool `json:"includeUnattributedIPConversions,omitempty"`
11826
11827	// ForceSendFields is a list of field names (e.g.
11828	// "IncludeAttributedIPConversions") to unconditionally include in API
11829	// requests. By default, fields with empty values are omitted from API
11830	// requests. However, any non-pointer, non-interface field appearing in
11831	// ForceSendFields will be sent to the server regardless of whether the
11832	// field is empty or not. This may be used to include empty fields in
11833	// Patch requests.
11834	ForceSendFields []string `json:"-"`
11835
11836	// NullFields is a list of field names (e.g.
11837	// "IncludeAttributedIPConversions") to include in API requests with the
11838	// JSON null value. By default, fields with empty values are omitted
11839	// from API requests. However, any field with an empty value appearing
11840	// in NullFields will be sent to the server as null. It is an error if a
11841	// field in this list has a non-empty value. This may be used to include
11842	// null fields in Patch requests.
11843	NullFields []string `json:"-"`
11844}
11845
11846func (s *ReportFloodlightCriteriaReportProperties) MarshalJSON() ([]byte, error) {
11847	type NoMethod ReportFloodlightCriteriaReportProperties
11848	raw := NoMethod(*s)
11849	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11850}
11851
11852// ReportPathToConversionCriteria: The report criteria for a report of
11853// type "PATH_TO_CONVERSION".
11854type ReportPathToConversionCriteria struct {
11855	// ActivityFilters: The list of 'dfa:activity' values to filter on.
11856	ActivityFilters []*DimensionValue `json:"activityFilters,omitempty"`
11857
11858	// ConversionDimensions: The list of conversion dimensions the report
11859	// should include.
11860	ConversionDimensions []*SortedDimension `json:"conversionDimensions,omitempty"`
11861
11862	// CustomFloodlightVariables: The list of custom floodlight variables
11863	// the report should include.
11864	CustomFloodlightVariables []*SortedDimension `json:"customFloodlightVariables,omitempty"`
11865
11866	// CustomRichMediaEvents: The list of custom rich media events to
11867	// include.
11868	CustomRichMediaEvents []*DimensionValue `json:"customRichMediaEvents,omitempty"`
11869
11870	// DateRange: The date range this report should be run for.
11871	DateRange *DateRange `json:"dateRange,omitempty"`
11872
11873	// FloodlightConfigId: The floodlight ID for which to show data in this
11874	// report. All advertisers associated with that ID will automatically be
11875	// added. The dimension of the value needs to be
11876	// 'dfa:floodlightConfigId'.
11877	FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
11878
11879	// MetricNames: The list of names of metrics the report should include.
11880	MetricNames []string `json:"metricNames,omitempty"`
11881
11882	// PerInteractionDimensions: The list of per interaction dimensions the
11883	// report should include.
11884	PerInteractionDimensions []*SortedDimension `json:"perInteractionDimensions,omitempty"`
11885
11886	// ReportProperties: The properties of the report.
11887	ReportProperties *ReportPathToConversionCriteriaReportProperties `json:"reportProperties,omitempty"`
11888
11889	// ForceSendFields is a list of field names (e.g. "ActivityFilters") to
11890	// unconditionally include in API requests. By default, fields with
11891	// empty values are omitted from API requests. However, any non-pointer,
11892	// non-interface field appearing in ForceSendFields will be sent to the
11893	// server regardless of whether the field is empty or not. This may be
11894	// used to include empty fields in Patch requests.
11895	ForceSendFields []string `json:"-"`
11896
11897	// NullFields is a list of field names (e.g. "ActivityFilters") to
11898	// include in API requests with the JSON null value. By default, fields
11899	// with empty values are omitted from API requests. However, any field
11900	// with an empty value appearing in NullFields will be sent to the
11901	// server as null. It is an error if a field in this list has a
11902	// non-empty value. This may be used to include null fields in Patch
11903	// requests.
11904	NullFields []string `json:"-"`
11905}
11906
11907func (s *ReportPathToConversionCriteria) MarshalJSON() ([]byte, error) {
11908	type NoMethod ReportPathToConversionCriteria
11909	raw := NoMethod(*s)
11910	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11911}
11912
11913// ReportPathToConversionCriteriaReportProperties: The properties of the
11914// report.
11915type ReportPathToConversionCriteriaReportProperties struct {
11916	// ClicksLookbackWindow: DFA checks to see if a click interaction
11917	// occurred within the specified period of time before a conversion. By
11918	// default the value is pulled from Floodlight or you can manually enter
11919	// a custom value. Valid values: 1-90.
11920	ClicksLookbackWindow int64 `json:"clicksLookbackWindow,omitempty"`
11921
11922	// ImpressionsLookbackWindow: DFA checks to see if an impression
11923	// interaction occurred within the specified period of time before a
11924	// conversion. By default the value is pulled from Floodlight or you can
11925	// manually enter a custom value. Valid values: 1-90.
11926	ImpressionsLookbackWindow int64 `json:"impressionsLookbackWindow,omitempty"`
11927
11928	// IncludeAttributedIPConversions: Deprecated: has no effect.
11929	IncludeAttributedIPConversions bool `json:"includeAttributedIPConversions,omitempty"`
11930
11931	// IncludeUnattributedCookieConversions: Include conversions of users
11932	// with a DoubleClick cookie but without an exposure. That means the
11933	// user did not click or see an ad from the advertiser within the
11934	// Floodlight group, or that the interaction happened outside the
11935	// lookback window.
11936	IncludeUnattributedCookieConversions bool `json:"includeUnattributedCookieConversions,omitempty"`
11937
11938	// IncludeUnattributedIPConversions: Include conversions that have no
11939	// associated cookies and no exposures. It’s therefore impossible to
11940	// know how the user was exposed to your ads during the lookback window
11941	// prior to a conversion.
11942	IncludeUnattributedIPConversions bool `json:"includeUnattributedIPConversions,omitempty"`
11943
11944	// MaximumClickInteractions: The maximum number of click interactions to
11945	// include in the report. Advertisers currently paying for E2C reports
11946	// get up to 200 (100 clicks, 100 impressions). If another advertiser in
11947	// your network is paying for E2C, you can have up to 5 total exposures
11948	// per report.
11949	MaximumClickInteractions int64 `json:"maximumClickInteractions,omitempty"`
11950
11951	// MaximumImpressionInteractions: The maximum number of click
11952	// interactions to include in the report. Advertisers currently paying
11953	// for E2C reports get up to 200 (100 clicks, 100 impressions). If
11954	// another advertiser in your network is paying for E2C, you can have up
11955	// to 5 total exposures per report.
11956	MaximumImpressionInteractions int64 `json:"maximumImpressionInteractions,omitempty"`
11957
11958	// MaximumInteractionGap: The maximum amount of time that can take place
11959	// between interactions (clicks or impressions) by the same user. Valid
11960	// values: 1-90.
11961	MaximumInteractionGap int64 `json:"maximumInteractionGap,omitempty"`
11962
11963	// PivotOnInteractionPath: Enable pivoting on interaction path.
11964	PivotOnInteractionPath bool `json:"pivotOnInteractionPath,omitempty"`
11965
11966	// ForceSendFields is a list of field names (e.g.
11967	// "ClicksLookbackWindow") to unconditionally include in API requests.
11968	// By default, fields with empty values are omitted from API requests.
11969	// However, any non-pointer, non-interface field appearing in
11970	// ForceSendFields will be sent to the server regardless of whether the
11971	// field is empty or not. This may be used to include empty fields in
11972	// Patch requests.
11973	ForceSendFields []string `json:"-"`
11974
11975	// NullFields is a list of field names (e.g. "ClicksLookbackWindow") to
11976	// include in API requests with the JSON null value. By default, fields
11977	// with empty values are omitted from API requests. However, any field
11978	// with an empty value appearing in NullFields will be sent to the
11979	// server as null. It is an error if a field in this list has a
11980	// non-empty value. This may be used to include null fields in Patch
11981	// requests.
11982	NullFields []string `json:"-"`
11983}
11984
11985func (s *ReportPathToConversionCriteriaReportProperties) MarshalJSON() ([]byte, error) {
11986	type NoMethod ReportPathToConversionCriteriaReportProperties
11987	raw := NoMethod(*s)
11988	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11989}
11990
11991// ReportReachCriteria: The report criteria for a report of type
11992// "REACH".
11993type ReportReachCriteria struct {
11994	// Activities: Activity group.
11995	Activities *Activities `json:"activities,omitempty"`
11996
11997	// CustomRichMediaEvents: Custom Rich Media Events group.
11998	CustomRichMediaEvents *CustomRichMediaEvents `json:"customRichMediaEvents,omitempty"`
11999
12000	// DateRange: The date range this report should be run for.
12001	DateRange *DateRange `json:"dateRange,omitempty"`
12002
12003	// DimensionFilters: The list of filters on which dimensions are
12004	// filtered.
12005	// Filters for different dimensions are ANDed, filters for the same
12006	// dimension are grouped together and ORed.
12007	DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
12008
12009	// Dimensions: The list of dimensions the report should include.
12010	Dimensions []*SortedDimension `json:"dimensions,omitempty"`
12011
12012	// EnableAllDimensionCombinations: Whether to enable all reach dimension
12013	// combinations in the report. Defaults to false. If enabled, the date
12014	// range of the report should be within the last 42 days.
12015	EnableAllDimensionCombinations bool `json:"enableAllDimensionCombinations,omitempty"`
12016
12017	// MetricNames: The list of names of metrics the report should include.
12018	MetricNames []string `json:"metricNames,omitempty"`
12019
12020	// ReachByFrequencyMetricNames: The list of names of  Reach By Frequency
12021	// metrics the report should include.
12022	ReachByFrequencyMetricNames []string `json:"reachByFrequencyMetricNames,omitempty"`
12023
12024	// ForceSendFields is a list of field names (e.g. "Activities") to
12025	// unconditionally include in API requests. By default, fields with
12026	// empty values are omitted from API requests. However, any non-pointer,
12027	// non-interface field appearing in ForceSendFields will be sent to the
12028	// server regardless of whether the field is empty or not. This may be
12029	// used to include empty fields in Patch requests.
12030	ForceSendFields []string `json:"-"`
12031
12032	// NullFields is a list of field names (e.g. "Activities") to include in
12033	// API requests with the JSON null value. By default, fields with empty
12034	// values are omitted from API requests. However, any field with an
12035	// empty value appearing in NullFields will be sent to the server as
12036	// null. It is an error if a field in this list has a non-empty value.
12037	// This may be used to include null fields in Patch requests.
12038	NullFields []string `json:"-"`
12039}
12040
12041func (s *ReportReachCriteria) MarshalJSON() ([]byte, error) {
12042	type NoMethod ReportReachCriteria
12043	raw := NoMethod(*s)
12044	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12045}
12046
12047// ReportSchedule: The report's schedule. Can only be set if the
12048// report's 'dateRange' is a relative date range and the relative date
12049// range is not "TODAY".
12050type ReportSchedule struct {
12051	// Active: Whether the schedule is active or not. Must be set to either
12052	// true or false.
12053	Active bool `json:"active,omitempty"`
12054
12055	// Every: Defines every how many days, weeks or months the report should
12056	// be run. Needs to be set when "repeats" is either "DAILY", "WEEKLY" or
12057	// "MONTHLY".
12058	Every int64 `json:"every,omitempty"`
12059
12060	// ExpirationDate: The expiration date when the scheduled report stops
12061	// running.
12062	ExpirationDate string `json:"expirationDate,omitempty"`
12063
12064	// Repeats: The interval for which the report is repeated. Note:
12065	// - "DAILY" also requires field "every" to be set.
12066	// - "WEEKLY" also requires fields "every" and "repeatsOnWeekDays" to be
12067	// set.
12068	// - "MONTHLY" also requires fields "every" and "runsOnDayOfMonth" to be
12069	// set.
12070	Repeats string `json:"repeats,omitempty"`
12071
12072	// RepeatsOnWeekDays: List of week days "WEEKLY" on which scheduled
12073	// reports should run.
12074	//
12075	// Possible values:
12076	//   "FRIDAY"
12077	//   "MONDAY"
12078	//   "SATURDAY"
12079	//   "SUNDAY"
12080	//   "THURSDAY"
12081	//   "TUESDAY"
12082	//   "WEDNESDAY"
12083	RepeatsOnWeekDays []string `json:"repeatsOnWeekDays,omitempty"`
12084
12085	// RunsOnDayOfMonth: Enum to define for "MONTHLY" scheduled reports
12086	// whether reports should be repeated on the same day of the month as
12087	// "startDate" or the same day of the week of the month.
12088	// Example: If 'startDate' is Monday, April 2nd 2012 (2012-04-02),
12089	// "DAY_OF_MONTH" would run subsequent reports on the 2nd of every
12090	// Month, and "WEEK_OF_MONTH" would run subsequent reports on the first
12091	// Monday of the month.
12092	//
12093	// Possible values:
12094	//   "DAY_OF_MONTH"
12095	//   "WEEK_OF_MONTH"
12096	RunsOnDayOfMonth string `json:"runsOnDayOfMonth,omitempty"`
12097
12098	// StartDate: Start date of date range for which scheduled reports
12099	// should be run.
12100	StartDate string `json:"startDate,omitempty"`
12101
12102	// ForceSendFields is a list of field names (e.g. "Active") to
12103	// unconditionally include in API requests. By default, fields with
12104	// empty values are omitted from API requests. However, any non-pointer,
12105	// non-interface field appearing in ForceSendFields will be sent to the
12106	// server regardless of whether the field is empty or not. This may be
12107	// used to include empty fields in Patch requests.
12108	ForceSendFields []string `json:"-"`
12109
12110	// NullFields is a list of field names (e.g. "Active") to include in API
12111	// requests with the JSON null value. By default, fields with empty
12112	// values are omitted from API requests. However, any field with an
12113	// empty value appearing in NullFields will be sent to the server as
12114	// null. It is an error if a field in this list has a non-empty value.
12115	// This may be used to include null fields in Patch requests.
12116	NullFields []string `json:"-"`
12117}
12118
12119func (s *ReportSchedule) MarshalJSON() ([]byte, error) {
12120	type NoMethod ReportSchedule
12121	raw := NoMethod(*s)
12122	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12123}
12124
12125// ReportCompatibleFields: Represents fields that are compatible to be
12126// selected for a report of type "STANDARD".
12127type ReportCompatibleFields struct {
12128	// DimensionFilters: Dimensions which are compatible to be selected in
12129	// the "dimensionFilters" section of the report.
12130	DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
12131
12132	// Dimensions: Dimensions which are compatible to be selected in the
12133	// "dimensions" section of the report.
12134	Dimensions []*Dimension `json:"dimensions,omitempty"`
12135
12136	// Kind: The kind of resource this is, in this case
12137	// dfareporting#reportCompatibleFields.
12138	Kind string `json:"kind,omitempty"`
12139
12140	// Metrics: Metrics which are compatible to be selected in the
12141	// "metricNames" section of the report.
12142	Metrics []*Metric `json:"metrics,omitempty"`
12143
12144	// PivotedActivityMetrics: Metrics which are compatible to be selected
12145	// as activity metrics to pivot on in the "activities" section of the
12146	// report.
12147	PivotedActivityMetrics []*Metric `json:"pivotedActivityMetrics,omitempty"`
12148
12149	// ForceSendFields is a list of field names (e.g. "DimensionFilters") to
12150	// unconditionally include in API requests. By default, fields with
12151	// empty values are omitted from API requests. However, any non-pointer,
12152	// non-interface field appearing in ForceSendFields will be sent to the
12153	// server regardless of whether the field is empty or not. This may be
12154	// used to include empty fields in Patch requests.
12155	ForceSendFields []string `json:"-"`
12156
12157	// NullFields is a list of field names (e.g. "DimensionFilters") to
12158	// include in API requests with the JSON null value. By default, fields
12159	// with empty values are omitted from API requests. However, any field
12160	// with an empty value appearing in NullFields will be sent to the
12161	// server as null. It is an error if a field in this list has a
12162	// non-empty value. This may be used to include null fields in Patch
12163	// requests.
12164	NullFields []string `json:"-"`
12165}
12166
12167func (s *ReportCompatibleFields) MarshalJSON() ([]byte, error) {
12168	type NoMethod ReportCompatibleFields
12169	raw := NoMethod(*s)
12170	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12171}
12172
12173// ReportList: Represents the list of reports.
12174type ReportList struct {
12175	// Etag: The eTag of this response for caching purposes.
12176	Etag string `json:"etag,omitempty"`
12177
12178	// Items: The reports returned in this response.
12179	Items []*Report `json:"items,omitempty"`
12180
12181	// Kind: The kind of list this is, in this case dfareporting#reportList.
12182	Kind string `json:"kind,omitempty"`
12183
12184	// NextPageToken: Continuation token used to page through reports. To
12185	// retrieve the next page of results, set the next request's "pageToken"
12186	// to the value of this field. The page token is only valid for a
12187	// limited amount of time and should not be persisted.
12188	NextPageToken string `json:"nextPageToken,omitempty"`
12189
12190	// ServerResponse contains the HTTP response code and headers from the
12191	// server.
12192	googleapi.ServerResponse `json:"-"`
12193
12194	// ForceSendFields is a list of field names (e.g. "Etag") to
12195	// unconditionally include in API requests. By default, fields with
12196	// empty values are omitted from API requests. However, any non-pointer,
12197	// non-interface field appearing in ForceSendFields will be sent to the
12198	// server regardless of whether the field is empty or not. This may be
12199	// used to include empty fields in Patch requests.
12200	ForceSendFields []string `json:"-"`
12201
12202	// NullFields is a list of field names (e.g. "Etag") to include in API
12203	// requests with the JSON null value. By default, fields with empty
12204	// values are omitted from API requests. However, any field with an
12205	// empty value appearing in NullFields will be sent to the server as
12206	// null. It is an error if a field in this list has a non-empty value.
12207	// This may be used to include null fields in Patch requests.
12208	NullFields []string `json:"-"`
12209}
12210
12211func (s *ReportList) MarshalJSON() ([]byte, error) {
12212	type NoMethod ReportList
12213	raw := NoMethod(*s)
12214	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12215}
12216
12217// ReportsConfiguration: Reporting Configuration
12218type ReportsConfiguration struct {
12219	// ExposureToConversionEnabled: Whether the exposure to conversion
12220	// report is enabled. This report shows detailed pathway information on
12221	// up to 10 of the most recent ad exposures seen by a user before
12222	// converting.
12223	ExposureToConversionEnabled bool `json:"exposureToConversionEnabled,omitempty"`
12224
12225	// LookbackConfiguration: Default lookback windows for new advertisers
12226	// in this account.
12227	LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
12228
12229	// ReportGenerationTimeZoneId: Report generation time zone ID of this
12230	// account. This is a required field that can only be changed by a
12231	// superuser.
12232	// Acceptable values are:
12233	//
12234	// - "1" for "America/New_York"
12235	// - "2" for "Europe/London"
12236	// - "3" for "Europe/Paris"
12237	// - "4" for "Africa/Johannesburg"
12238	// - "5" for "Asia/Jerusalem"
12239	// - "6" for "Asia/Shanghai"
12240	// - "7" for "Asia/Hong_Kong"
12241	// - "8" for "Asia/Tokyo"
12242	// - "9" for "Australia/Sydney"
12243	// - "10" for "Asia/Dubai"
12244	// - "11" for "America/Los_Angeles"
12245	// - "12" for "Pacific/Auckland"
12246	// - "13" for "America/Sao_Paulo"
12247	ReportGenerationTimeZoneId int64 `json:"reportGenerationTimeZoneId,omitempty,string"`
12248
12249	// ForceSendFields is a list of field names (e.g.
12250	// "ExposureToConversionEnabled") to unconditionally include in API
12251	// requests. By default, fields with empty values are omitted from API
12252	// requests. However, any non-pointer, non-interface field appearing in
12253	// ForceSendFields will be sent to the server regardless of whether the
12254	// field is empty or not. This may be used to include empty fields in
12255	// Patch requests.
12256	ForceSendFields []string `json:"-"`
12257
12258	// NullFields is a list of field names (e.g.
12259	// "ExposureToConversionEnabled") to include in API requests with the
12260	// JSON null value. By default, fields with empty values are omitted
12261	// from API requests. However, any field with an empty value appearing
12262	// in NullFields will be sent to the server as null. It is an error if a
12263	// field in this list has a non-empty value. This may be used to include
12264	// null fields in Patch requests.
12265	NullFields []string `json:"-"`
12266}
12267
12268func (s *ReportsConfiguration) MarshalJSON() ([]byte, error) {
12269	type NoMethod ReportsConfiguration
12270	raw := NoMethod(*s)
12271	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12272}
12273
12274// RichMediaExitOverride: Rich Media Exit Override.
12275type RichMediaExitOverride struct {
12276	// ClickThroughUrl: Click-through URL of this rich media exit override.
12277	// Applicable if the enabled field is set to true.
12278	ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
12279
12280	// Enabled: Whether to use the clickThroughUrl. If false, the
12281	// creative-level exit will be used.
12282	Enabled bool `json:"enabled,omitempty"`
12283
12284	// ExitId: ID for the override to refer to a specific exit in the
12285	// creative.
12286	ExitId int64 `json:"exitId,omitempty,string"`
12287
12288	// ForceSendFields is a list of field names (e.g. "ClickThroughUrl") to
12289	// unconditionally include in API requests. By default, fields with
12290	// empty values are omitted from API requests. However, any non-pointer,
12291	// non-interface field appearing in ForceSendFields will be sent to the
12292	// server regardless of whether the field is empty or not. This may be
12293	// used to include empty fields in Patch requests.
12294	ForceSendFields []string `json:"-"`
12295
12296	// NullFields is a list of field names (e.g. "ClickThroughUrl") to
12297	// include in API requests with the JSON null value. By default, fields
12298	// with empty values are omitted from API requests. However, any field
12299	// with an empty value appearing in NullFields will be sent to the
12300	// server as null. It is an error if a field in this list has a
12301	// non-empty value. This may be used to include null fields in Patch
12302	// requests.
12303	NullFields []string `json:"-"`
12304}
12305
12306func (s *RichMediaExitOverride) MarshalJSON() ([]byte, error) {
12307	type NoMethod RichMediaExitOverride
12308	raw := NoMethod(*s)
12309	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12310}
12311
12312// Rule: A rule associates an asset with a targeting template for
12313// asset-level targeting. Applicable to INSTREAM_VIDEO creatives.
12314type Rule struct {
12315	// AssetId: A creativeAssets[].id. This should refer to one of the
12316	// parent assets in this creative. This is a required field.
12317	AssetId int64 `json:"assetId,omitempty,string"`
12318
12319	// Name: A user-friendly name for this rule. This is a required field.
12320	Name string `json:"name,omitempty"`
12321
12322	// TargetingTemplateId: A targeting template ID. The targeting from the
12323	// targeting template will be used to determine whether this asset
12324	// should be served. This is a required field.
12325	TargetingTemplateId int64 `json:"targetingTemplateId,omitempty,string"`
12326
12327	// ForceSendFields is a list of field names (e.g. "AssetId") to
12328	// unconditionally include in API requests. By default, fields with
12329	// empty values are omitted from API requests. However, any non-pointer,
12330	// non-interface field appearing in ForceSendFields will be sent to the
12331	// server regardless of whether the field is empty or not. This may be
12332	// used to include empty fields in Patch requests.
12333	ForceSendFields []string `json:"-"`
12334
12335	// NullFields is a list of field names (e.g. "AssetId") to include in
12336	// API requests with the JSON null value. By default, fields with empty
12337	// values are omitted from API requests. However, any field with an
12338	// empty value appearing in NullFields will be sent to the server as
12339	// null. It is an error if a field in this list has a non-empty value.
12340	// This may be used to include null fields in Patch requests.
12341	NullFields []string `json:"-"`
12342}
12343
12344func (s *Rule) MarshalJSON() ([]byte, error) {
12345	type NoMethod Rule
12346	raw := NoMethod(*s)
12347	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12348}
12349
12350// Site: Contains properties of a site.
12351type Site struct {
12352	// AccountId: Account ID of this site. This is a read-only field that
12353	// can be left blank.
12354	AccountId int64 `json:"accountId,omitempty,string"`
12355
12356	// Approved: Whether this site is approved.
12357	Approved bool `json:"approved,omitempty"`
12358
12359	// DirectorySiteId: Directory site associated with this site. This is a
12360	// required field that is read-only after insertion.
12361	DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
12362
12363	// DirectorySiteIdDimensionValue: Dimension value for the ID of the
12364	// directory site. This is a read-only, auto-generated field.
12365	DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
12366
12367	// Id: ID of this site. This is a read-only, auto-generated field.
12368	Id int64 `json:"id,omitempty,string"`
12369
12370	// IdDimensionValue: Dimension value for the ID of this site. This is a
12371	// read-only, auto-generated field.
12372	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
12373
12374	// KeyName: Key name of this site. This is a read-only, auto-generated
12375	// field.
12376	KeyName string `json:"keyName,omitempty"`
12377
12378	// Kind: Identifies what kind of resource this is. Value: the fixed
12379	// string "dfareporting#site".
12380	Kind string `json:"kind,omitempty"`
12381
12382	// Name: Name of this site.This is a required field. Must be less than
12383	// 128 characters long. If this site is under a subaccount, the name
12384	// must be unique among sites of the same subaccount. Otherwise, this
12385	// site is a top-level site, and the name must be unique among top-level
12386	// sites of the same account.
12387	Name string `json:"name,omitempty"`
12388
12389	// SiteContacts: Site contacts.
12390	SiteContacts []*SiteContact `json:"siteContacts,omitempty"`
12391
12392	// SiteSettings: Site-wide settings.
12393	SiteSettings *SiteSettings `json:"siteSettings,omitempty"`
12394
12395	// SubaccountId: Subaccount ID of this site. This is a read-only field
12396	// that can be left blank.
12397	SubaccountId int64 `json:"subaccountId,omitempty,string"`
12398
12399	// ServerResponse contains the HTTP response code and headers from the
12400	// server.
12401	googleapi.ServerResponse `json:"-"`
12402
12403	// ForceSendFields is a list of field names (e.g. "AccountId") to
12404	// unconditionally include in API requests. By default, fields with
12405	// empty values are omitted from API requests. However, any non-pointer,
12406	// non-interface field appearing in ForceSendFields will be sent to the
12407	// server regardless of whether the field is empty or not. This may be
12408	// used to include empty fields in Patch requests.
12409	ForceSendFields []string `json:"-"`
12410
12411	// NullFields is a list of field names (e.g. "AccountId") to include in
12412	// API requests with the JSON null value. By default, fields with empty
12413	// values are omitted from API requests. However, any field with an
12414	// empty value appearing in NullFields will be sent to the server as
12415	// null. It is an error if a field in this list has a non-empty value.
12416	// This may be used to include null fields in Patch requests.
12417	NullFields []string `json:"-"`
12418}
12419
12420func (s *Site) MarshalJSON() ([]byte, error) {
12421	type NoMethod Site
12422	raw := NoMethod(*s)
12423	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12424}
12425
12426// SiteContact: Site Contact
12427type SiteContact struct {
12428	// Address: Address of this site contact.
12429	Address string `json:"address,omitempty"`
12430
12431	// ContactType: Site contact type.
12432	//
12433	// Possible values:
12434	//   "SALES_PERSON"
12435	//   "TRAFFICKER"
12436	ContactType string `json:"contactType,omitempty"`
12437
12438	// Email: Email address of this site contact. This is a required field.
12439	Email string `json:"email,omitempty"`
12440
12441	// FirstName: First name of this site contact.
12442	FirstName string `json:"firstName,omitempty"`
12443
12444	// Id: ID of this site contact. This is a read-only, auto-generated
12445	// field.
12446	Id int64 `json:"id,omitempty,string"`
12447
12448	// LastName: Last name of this site contact.
12449	LastName string `json:"lastName,omitempty"`
12450
12451	// Phone: Primary phone number of this site contact.
12452	Phone string `json:"phone,omitempty"`
12453
12454	// Title: Title or designation of this site contact.
12455	Title string `json:"title,omitempty"`
12456
12457	// ForceSendFields is a list of field names (e.g. "Address") to
12458	// unconditionally include in API requests. By default, fields with
12459	// empty values are omitted from API requests. However, any non-pointer,
12460	// non-interface field appearing in ForceSendFields will be sent to the
12461	// server regardless of whether the field is empty or not. This may be
12462	// used to include empty fields in Patch requests.
12463	ForceSendFields []string `json:"-"`
12464
12465	// NullFields is a list of field names (e.g. "Address") to include in
12466	// API requests with the JSON null value. By default, fields with empty
12467	// values are omitted from API requests. However, any field with an
12468	// empty value appearing in NullFields will be sent to the server as
12469	// null. It is an error if a field in this list has a non-empty value.
12470	// This may be used to include null fields in Patch requests.
12471	NullFields []string `json:"-"`
12472}
12473
12474func (s *SiteContact) MarshalJSON() ([]byte, error) {
12475	type NoMethod SiteContact
12476	raw := NoMethod(*s)
12477	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12478}
12479
12480// SiteSettings: Site Settings
12481type SiteSettings struct {
12482	// ActiveViewOptOut: Whether active view creatives are disabled for this
12483	// site.
12484	ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
12485
12486	// AdBlockingOptOut: Whether this site opts out of ad blocking. When
12487	// true, ad blocking is disabled for all placements under the site,
12488	// regardless of the individual placement settings. When false, the
12489	// campaign and placement settings take effect.
12490	AdBlockingOptOut bool `json:"adBlockingOptOut,omitempty"`
12491
12492	// CreativeSettings: Site-wide creative settings.
12493	CreativeSettings *CreativeSettings `json:"creativeSettings,omitempty"`
12494
12495	// DisableNewCookie: Whether new cookies are disabled for this site.
12496	DisableNewCookie bool `json:"disableNewCookie,omitempty"`
12497
12498	// LookbackConfiguration: Lookback window settings for this site.
12499	LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
12500
12501	// TagSetting: Configuration settings for dynamic and image floodlight
12502	// tags.
12503	TagSetting *TagSetting `json:"tagSetting,omitempty"`
12504
12505	// VideoActiveViewOptOutTemplate: Whether Verification and ActiveView
12506	// for in-stream video creatives are disabled by default for new
12507	// placements created under this site. This value will be used to
12508	// populate the placement.videoActiveViewOptOut field, when no value is
12509	// specified for the new placement.
12510	VideoActiveViewOptOutTemplate bool `json:"videoActiveViewOptOutTemplate,omitempty"`
12511
12512	// VpaidAdapterChoiceTemplate: Default VPAID adapter setting for new
12513	// placements created under this site. This value will be used to
12514	// populate the placements.vpaidAdapterChoice field, when no value is
12515	// specified for the new placement. Controls which VPAID format the
12516	// measurement adapter will use for in-stream video creatives assigned
12517	// to the placement. The publisher's specifications will typically
12518	// determine this setting. For VPAID creatives, the adapter format will
12519	// match the VPAID format (HTML5 VPAID creatives use the HTML5
12520	// adapter).
12521	//
12522	// Note: Flash is no longer supported. This field now defaults to HTML5
12523	// when the following values are provided: FLASH, BOTH.
12524	//
12525	// Possible values:
12526	//   "BOTH"
12527	//   "DEFAULT"
12528	//   "FLASH"
12529	//   "HTML5"
12530	VpaidAdapterChoiceTemplate string `json:"vpaidAdapterChoiceTemplate,omitempty"`
12531
12532	// ForceSendFields is a list of field names (e.g. "ActiveViewOptOut") to
12533	// unconditionally include in API requests. By default, fields with
12534	// empty values are omitted from API requests. However, any non-pointer,
12535	// non-interface field appearing in ForceSendFields will be sent to the
12536	// server regardless of whether the field is empty or not. This may be
12537	// used to include empty fields in Patch requests.
12538	ForceSendFields []string `json:"-"`
12539
12540	// NullFields is a list of field names (e.g. "ActiveViewOptOut") to
12541	// include in API requests with the JSON null value. By default, fields
12542	// with empty values are omitted from API requests. However, any field
12543	// with an empty value appearing in NullFields will be sent to the
12544	// server as null. It is an error if a field in this list has a
12545	// non-empty value. This may be used to include null fields in Patch
12546	// requests.
12547	NullFields []string `json:"-"`
12548}
12549
12550func (s *SiteSettings) MarshalJSON() ([]byte, error) {
12551	type NoMethod SiteSettings
12552	raw := NoMethod(*s)
12553	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12554}
12555
12556// SitesListResponse: Site List Response
12557type SitesListResponse struct {
12558	// Kind: Identifies what kind of resource this is. Value: the fixed
12559	// string "dfareporting#sitesListResponse".
12560	Kind string `json:"kind,omitempty"`
12561
12562	// NextPageToken: Pagination token to be used for the next list
12563	// operation.
12564	NextPageToken string `json:"nextPageToken,omitempty"`
12565
12566	// Sites: Site collection.
12567	Sites []*Site `json:"sites,omitempty"`
12568
12569	// ServerResponse contains the HTTP response code and headers from the
12570	// server.
12571	googleapi.ServerResponse `json:"-"`
12572
12573	// ForceSendFields is a list of field names (e.g. "Kind") to
12574	// unconditionally include in API requests. By default, fields with
12575	// empty values are omitted from API requests. However, any non-pointer,
12576	// non-interface field appearing in ForceSendFields will be sent to the
12577	// server regardless of whether the field is empty or not. This may be
12578	// used to include empty fields in Patch requests.
12579	ForceSendFields []string `json:"-"`
12580
12581	// NullFields is a list of field names (e.g. "Kind") to include in API
12582	// requests with the JSON null value. By default, fields with empty
12583	// values are omitted from API requests. However, any field with an
12584	// empty value appearing in NullFields will be sent to the server as
12585	// null. It is an error if a field in this list has a non-empty value.
12586	// This may be used to include null fields in Patch requests.
12587	NullFields []string `json:"-"`
12588}
12589
12590func (s *SitesListResponse) MarshalJSON() ([]byte, error) {
12591	type NoMethod SitesListResponse
12592	raw := NoMethod(*s)
12593	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12594}
12595
12596// Size: Represents the dimensions of ads, placements, creatives, or
12597// creative assets.
12598type Size struct {
12599	// Height: Height of this size. Acceptable values are 0 to 32767,
12600	// inclusive.
12601	Height int64 `json:"height,omitempty"`
12602
12603	// Iab: IAB standard size. This is a read-only, auto-generated field.
12604	Iab bool `json:"iab,omitempty"`
12605
12606	// Id: ID of this size. This is a read-only, auto-generated field.
12607	Id int64 `json:"id,omitempty,string"`
12608
12609	// Kind: Identifies what kind of resource this is. Value: the fixed
12610	// string "dfareporting#size".
12611	Kind string `json:"kind,omitempty"`
12612
12613	// Width: Width of this size. Acceptable values are 0 to 32767,
12614	// inclusive.
12615	Width int64 `json:"width,omitempty"`
12616
12617	// ServerResponse contains the HTTP response code and headers from the
12618	// server.
12619	googleapi.ServerResponse `json:"-"`
12620
12621	// ForceSendFields is a list of field names (e.g. "Height") to
12622	// unconditionally include in API requests. By default, fields with
12623	// empty values are omitted from API requests. However, any non-pointer,
12624	// non-interface field appearing in ForceSendFields will be sent to the
12625	// server regardless of whether the field is empty or not. This may be
12626	// used to include empty fields in Patch requests.
12627	ForceSendFields []string `json:"-"`
12628
12629	// NullFields is a list of field names (e.g. "Height") to include in API
12630	// requests with the JSON null value. By default, fields with empty
12631	// values are omitted from API requests. However, any field with an
12632	// empty value appearing in NullFields will be sent to the server as
12633	// null. It is an error if a field in this list has a non-empty value.
12634	// This may be used to include null fields in Patch requests.
12635	NullFields []string `json:"-"`
12636}
12637
12638func (s *Size) MarshalJSON() ([]byte, error) {
12639	type NoMethod Size
12640	raw := NoMethod(*s)
12641	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12642}
12643
12644// SizesListResponse: Size List Response
12645type SizesListResponse struct {
12646	// Kind: Identifies what kind of resource this is. Value: the fixed
12647	// string "dfareporting#sizesListResponse".
12648	Kind string `json:"kind,omitempty"`
12649
12650	// Sizes: Size collection.
12651	Sizes []*Size `json:"sizes,omitempty"`
12652
12653	// ServerResponse contains the HTTP response code and headers from the
12654	// server.
12655	googleapi.ServerResponse `json:"-"`
12656
12657	// ForceSendFields is a list of field names (e.g. "Kind") to
12658	// unconditionally include in API requests. By default, fields with
12659	// empty values are omitted from API requests. However, any non-pointer,
12660	// non-interface field appearing in ForceSendFields will be sent to the
12661	// server regardless of whether the field is empty or not. This may be
12662	// used to include empty fields in Patch requests.
12663	ForceSendFields []string `json:"-"`
12664
12665	// NullFields is a list of field names (e.g. "Kind") to include in API
12666	// requests with the JSON null value. By default, fields with empty
12667	// values are omitted from API requests. However, any field with an
12668	// empty value appearing in NullFields will be sent to the server as
12669	// null. It is an error if a field in this list has a non-empty value.
12670	// This may be used to include null fields in Patch requests.
12671	NullFields []string `json:"-"`
12672}
12673
12674func (s *SizesListResponse) MarshalJSON() ([]byte, error) {
12675	type NoMethod SizesListResponse
12676	raw := NoMethod(*s)
12677	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12678}
12679
12680// SkippableSetting: Skippable Settings
12681type SkippableSetting struct {
12682	// Kind: Identifies what kind of resource this is. Value: the fixed
12683	// string "dfareporting#skippableSetting".
12684	Kind string `json:"kind,omitempty"`
12685
12686	// ProgressOffset: Amount of time to play videos served to this
12687	// placement before counting a view. Applicable when skippable is true.
12688	ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
12689
12690	// SkipOffset: Amount of time to play videos served to this placement
12691	// before the skip button should appear. Applicable when skippable is
12692	// true.
12693	SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
12694
12695	// Skippable: Whether the user can skip creatives served to this
12696	// placement.
12697	Skippable bool `json:"skippable,omitempty"`
12698
12699	// ForceSendFields is a list of field names (e.g. "Kind") to
12700	// unconditionally include in API requests. By default, fields with
12701	// empty values are omitted from API requests. However, any non-pointer,
12702	// non-interface field appearing in ForceSendFields will be sent to the
12703	// server regardless of whether the field is empty or not. This may be
12704	// used to include empty fields in Patch requests.
12705	ForceSendFields []string `json:"-"`
12706
12707	// NullFields is a list of field names (e.g. "Kind") to include in API
12708	// requests with the JSON null value. By default, fields with empty
12709	// values are omitted from API requests. However, any field with an
12710	// empty value appearing in NullFields will be sent to the server as
12711	// null. It is an error if a field in this list has a non-empty value.
12712	// This may be used to include null fields in Patch requests.
12713	NullFields []string `json:"-"`
12714}
12715
12716func (s *SkippableSetting) MarshalJSON() ([]byte, error) {
12717	type NoMethod SkippableSetting
12718	raw := NoMethod(*s)
12719	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12720}
12721
12722// SortedDimension: Represents a sorted dimension.
12723type SortedDimension struct {
12724	// Kind: The kind of resource this is, in this case
12725	// dfareporting#sortedDimension.
12726	Kind string `json:"kind,omitempty"`
12727
12728	// Name: The name of the dimension.
12729	Name string `json:"name,omitempty"`
12730
12731	// SortOrder: An optional sort order for the dimension column.
12732	//
12733	// Possible values:
12734	//   "ASCENDING"
12735	//   "DESCENDING"
12736	SortOrder string `json:"sortOrder,omitempty"`
12737
12738	// ForceSendFields is a list of field names (e.g. "Kind") to
12739	// unconditionally include in API requests. By default, fields with
12740	// empty values are omitted from API requests. However, any non-pointer,
12741	// non-interface field appearing in ForceSendFields will be sent to the
12742	// server regardless of whether the field is empty or not. This may be
12743	// used to include empty fields in Patch requests.
12744	ForceSendFields []string `json:"-"`
12745
12746	// NullFields is a list of field names (e.g. "Kind") to include in API
12747	// requests with the JSON null value. By default, fields with empty
12748	// values are omitted from API requests. However, any field with an
12749	// empty value appearing in NullFields will be sent to the server as
12750	// null. It is an error if a field in this list has a non-empty value.
12751	// This may be used to include null fields in Patch requests.
12752	NullFields []string `json:"-"`
12753}
12754
12755func (s *SortedDimension) MarshalJSON() ([]byte, error) {
12756	type NoMethod SortedDimension
12757	raw := NoMethod(*s)
12758	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12759}
12760
12761// Subaccount: Contains properties of a Campaign Manager subaccount.
12762type Subaccount struct {
12763	// AccountId: ID of the account that contains this subaccount. This is a
12764	// read-only field that can be left blank.
12765	AccountId int64 `json:"accountId,omitempty,string"`
12766
12767	// AvailablePermissionIds: IDs of the available user role permissions
12768	// for this subaccount.
12769	AvailablePermissionIds googleapi.Int64s `json:"availablePermissionIds,omitempty"`
12770
12771	// Id: ID of this subaccount. This is a read-only, auto-generated field.
12772	Id int64 `json:"id,omitempty,string"`
12773
12774	// Kind: Identifies what kind of resource this is. Value: the fixed
12775	// string "dfareporting#subaccount".
12776	Kind string `json:"kind,omitempty"`
12777
12778	// Name: Name of this subaccount. This is a required field. Must be less
12779	// than 128 characters long and be unique among subaccounts of the same
12780	// account.
12781	Name string `json:"name,omitempty"`
12782
12783	// ServerResponse contains the HTTP response code and headers from the
12784	// server.
12785	googleapi.ServerResponse `json:"-"`
12786
12787	// ForceSendFields is a list of field names (e.g. "AccountId") to
12788	// unconditionally include in API requests. By default, fields with
12789	// empty values are omitted from API requests. However, any non-pointer,
12790	// non-interface field appearing in ForceSendFields will be sent to the
12791	// server regardless of whether the field is empty or not. This may be
12792	// used to include empty fields in Patch requests.
12793	ForceSendFields []string `json:"-"`
12794
12795	// NullFields is a list of field names (e.g. "AccountId") to include in
12796	// API requests with the JSON null value. By default, fields with empty
12797	// values are omitted from API requests. However, any field with an
12798	// empty value appearing in NullFields will be sent to the server as
12799	// null. It is an error if a field in this list has a non-empty value.
12800	// This may be used to include null fields in Patch requests.
12801	NullFields []string `json:"-"`
12802}
12803
12804func (s *Subaccount) MarshalJSON() ([]byte, error) {
12805	type NoMethod Subaccount
12806	raw := NoMethod(*s)
12807	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12808}
12809
12810// SubaccountsListResponse: Subaccount List Response
12811type SubaccountsListResponse struct {
12812	// Kind: Identifies what kind of resource this is. Value: the fixed
12813	// string "dfareporting#subaccountsListResponse".
12814	Kind string `json:"kind,omitempty"`
12815
12816	// NextPageToken: Pagination token to be used for the next list
12817	// operation.
12818	NextPageToken string `json:"nextPageToken,omitempty"`
12819
12820	// Subaccounts: Subaccount collection.
12821	Subaccounts []*Subaccount `json:"subaccounts,omitempty"`
12822
12823	// ServerResponse contains the HTTP response code and headers from the
12824	// server.
12825	googleapi.ServerResponse `json:"-"`
12826
12827	// ForceSendFields is a list of field names (e.g. "Kind") to
12828	// unconditionally include in API requests. By default, fields with
12829	// empty values are omitted from API requests. However, any non-pointer,
12830	// non-interface field appearing in ForceSendFields will be sent to the
12831	// server regardless of whether the field is empty or not. This may be
12832	// used to include empty fields in Patch requests.
12833	ForceSendFields []string `json:"-"`
12834
12835	// NullFields is a list of field names (e.g. "Kind") to include in API
12836	// requests with the JSON null value. By default, fields with empty
12837	// values are omitted from API requests. However, any field with an
12838	// empty value appearing in NullFields will be sent to the server as
12839	// null. It is an error if a field in this list has a non-empty value.
12840	// This may be used to include null fields in Patch requests.
12841	NullFields []string `json:"-"`
12842}
12843
12844func (s *SubaccountsListResponse) MarshalJSON() ([]byte, error) {
12845	type NoMethod SubaccountsListResponse
12846	raw := NoMethod(*s)
12847	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12848}
12849
12850// TagData: Placement Tag Data
12851type TagData struct {
12852	// AdId: Ad associated with this placement tag. Applicable only when
12853	// format is PLACEMENT_TAG_TRACKING.
12854	AdId int64 `json:"adId,omitempty,string"`
12855
12856	// ClickTag: Tag string to record a click.
12857	ClickTag string `json:"clickTag,omitempty"`
12858
12859	// CreativeId: Creative associated with this placement tag. Applicable
12860	// only when format is PLACEMENT_TAG_TRACKING.
12861	CreativeId int64 `json:"creativeId,omitempty,string"`
12862
12863	// Format: TagData tag format of this tag.
12864	//
12865	// Possible values:
12866	//   "PLACEMENT_TAG_CLICK_COMMANDS"
12867	//   "PLACEMENT_TAG_IFRAME_ILAYER"
12868	//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT"
12869	//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY"
12870	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH"
12871	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3"
12872	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4"
12873	//   "PLACEMENT_TAG_INTERNAL_REDIRECT"
12874	//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT"
12875	//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY"
12876	//   "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT"
12877	//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT"
12878	//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY"
12879	//   "PLACEMENT_TAG_JAVASCRIPT"
12880	//   "PLACEMENT_TAG_JAVASCRIPT_LEGACY"
12881	//   "PLACEMENT_TAG_STANDARD"
12882	//   "PLACEMENT_TAG_TRACKING"
12883	//   "PLACEMENT_TAG_TRACKING_IFRAME"
12884	//   "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
12885	Format string `json:"format,omitempty"`
12886
12887	// ImpressionTag: Tag string for serving an ad.
12888	ImpressionTag string `json:"impressionTag,omitempty"`
12889
12890	// ForceSendFields is a list of field names (e.g. "AdId") to
12891	// unconditionally include in API requests. By default, fields with
12892	// empty values are omitted from API requests. However, any non-pointer,
12893	// non-interface field appearing in ForceSendFields will be sent to the
12894	// server regardless of whether the field is empty or not. This may be
12895	// used to include empty fields in Patch requests.
12896	ForceSendFields []string `json:"-"`
12897
12898	// NullFields is a list of field names (e.g. "AdId") to include in API
12899	// requests with the JSON null value. By default, fields with empty
12900	// values are omitted from API requests. However, any field with an
12901	// empty value appearing in NullFields will be sent to the server as
12902	// null. It is an error if a field in this list has a non-empty value.
12903	// This may be used to include null fields in Patch requests.
12904	NullFields []string `json:"-"`
12905}
12906
12907func (s *TagData) MarshalJSON() ([]byte, error) {
12908	type NoMethod TagData
12909	raw := NoMethod(*s)
12910	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12911}
12912
12913// TagSetting: Tag Settings
12914type TagSetting struct {
12915	// AdditionalKeyValues: Additional key-values to be included in tags.
12916	// Each key-value pair must be of the form key=value, and pairs must be
12917	// separated by a semicolon (;). Keys and values must not contain
12918	// commas. For example, id=2;color=red is a valid value for this field.
12919	AdditionalKeyValues string `json:"additionalKeyValues,omitempty"`
12920
12921	// IncludeClickThroughUrls: Whether static landing page URLs should be
12922	// included in the tags. This setting applies only to placements.
12923	IncludeClickThroughUrls bool `json:"includeClickThroughUrls,omitempty"`
12924
12925	// IncludeClickTracking: Whether click-tracking string should be
12926	// included in the tags.
12927	IncludeClickTracking bool `json:"includeClickTracking,omitempty"`
12928
12929	// KeywordOption: Option specifying how keywords are embedded in ad
12930	// tags. This setting can be used to specify whether keyword
12931	// placeholders are inserted in placement tags for this site. Publishers
12932	// can then add keywords to those placeholders.
12933	//
12934	// Possible values:
12935	//   "GENERATE_SEPARATE_TAG_FOR_EACH_KEYWORD"
12936	//   "IGNORE"
12937	//   "PLACEHOLDER_WITH_LIST_OF_KEYWORDS"
12938	KeywordOption string `json:"keywordOption,omitempty"`
12939
12940	// ForceSendFields is a list of field names (e.g. "AdditionalKeyValues")
12941	// to unconditionally include in API requests. By default, fields with
12942	// empty values are omitted from API requests. However, any non-pointer,
12943	// non-interface field appearing in ForceSendFields will be sent to the
12944	// server regardless of whether the field is empty or not. This may be
12945	// used to include empty fields in Patch requests.
12946	ForceSendFields []string `json:"-"`
12947
12948	// NullFields is a list of field names (e.g. "AdditionalKeyValues") to
12949	// include in API requests with the JSON null value. By default, fields
12950	// with empty values are omitted from API requests. However, any field
12951	// with an empty value appearing in NullFields will be sent to the
12952	// server as null. It is an error if a field in this list has a
12953	// non-empty value. This may be used to include null fields in Patch
12954	// requests.
12955	NullFields []string `json:"-"`
12956}
12957
12958func (s *TagSetting) MarshalJSON() ([]byte, error) {
12959	type NoMethod TagSetting
12960	raw := NoMethod(*s)
12961	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12962}
12963
12964// TagSettings: Dynamic and Image Tag Settings.
12965type TagSettings struct {
12966	// DynamicTagEnabled: Whether dynamic floodlight tags are enabled.
12967	DynamicTagEnabled bool `json:"dynamicTagEnabled,omitempty"`
12968
12969	// ImageTagEnabled: Whether image tags are enabled.
12970	ImageTagEnabled bool `json:"imageTagEnabled,omitempty"`
12971
12972	// ForceSendFields is a list of field names (e.g. "DynamicTagEnabled")
12973	// to unconditionally include in API requests. By default, fields with
12974	// empty values are omitted from API requests. However, any non-pointer,
12975	// non-interface field appearing in ForceSendFields will be sent to the
12976	// server regardless of whether the field is empty or not. This may be
12977	// used to include empty fields in Patch requests.
12978	ForceSendFields []string `json:"-"`
12979
12980	// NullFields is a list of field names (e.g. "DynamicTagEnabled") to
12981	// include in API requests with the JSON null value. By default, fields
12982	// with empty values are omitted from API requests. However, any field
12983	// with an empty value appearing in NullFields will be sent to the
12984	// server as null. It is an error if a field in this list has a
12985	// non-empty value. This may be used to include null fields in Patch
12986	// requests.
12987	NullFields []string `json:"-"`
12988}
12989
12990func (s *TagSettings) MarshalJSON() ([]byte, error) {
12991	type NoMethod TagSettings
12992	raw := NoMethod(*s)
12993	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12994}
12995
12996// TargetWindow: Target Window.
12997type TargetWindow struct {
12998	// CustomHtml: User-entered value.
12999	CustomHtml string `json:"customHtml,omitempty"`
13000
13001	// TargetWindowOption: Type of browser window for which the backup image
13002	// of the flash creative can be displayed.
13003	//
13004	// Possible values:
13005	//   "CURRENT_WINDOW"
13006	//   "CUSTOM"
13007	//   "NEW_WINDOW"
13008	TargetWindowOption string `json:"targetWindowOption,omitempty"`
13009
13010	// ForceSendFields is a list of field names (e.g. "CustomHtml") to
13011	// unconditionally include in API requests. By default, fields with
13012	// empty values are omitted from API requests. However, any non-pointer,
13013	// non-interface field appearing in ForceSendFields will be sent to the
13014	// server regardless of whether the field is empty or not. This may be
13015	// used to include empty fields in Patch requests.
13016	ForceSendFields []string `json:"-"`
13017
13018	// NullFields is a list of field names (e.g. "CustomHtml") to include in
13019	// API requests with the JSON null value. By default, fields with empty
13020	// values are omitted from API requests. However, any field with an
13021	// empty value appearing in NullFields will be sent to the server as
13022	// null. It is an error if a field in this list has a non-empty value.
13023	// This may be used to include null fields in Patch requests.
13024	NullFields []string `json:"-"`
13025}
13026
13027func (s *TargetWindow) MarshalJSON() ([]byte, error) {
13028	type NoMethod TargetWindow
13029	raw := NoMethod(*s)
13030	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13031}
13032
13033// TargetableRemarketingList: Contains properties of a targetable
13034// remarketing list. Remarketing enables you to create lists of users
13035// who have performed specific actions on a site, then target ads to
13036// members of those lists. This resource is a read-only view of a
13037// remarketing list to be used to faciliate targeting ads to specific
13038// lists. Remarketing lists that are owned by your advertisers and those
13039// that are shared to your advertisers or account are accessible via
13040// this resource. To manage remarketing lists that are owned by your
13041// advertisers, use the RemarketingLists resource.
13042type TargetableRemarketingList struct {
13043	// AccountId: Account ID of this remarketing list. This is a read-only,
13044	// auto-generated field that is only returned in GET requests.
13045	AccountId int64 `json:"accountId,omitempty,string"`
13046
13047	// Active: Whether this targetable remarketing list is active.
13048	Active bool `json:"active,omitempty"`
13049
13050	// AdvertiserId: Dimension value for the advertiser ID that owns this
13051	// targetable remarketing list.
13052	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
13053
13054	// AdvertiserIdDimensionValue: Dimension value for the ID of the
13055	// advertiser.
13056	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
13057
13058	// Description: Targetable remarketing list description.
13059	Description string `json:"description,omitempty"`
13060
13061	// Id: Targetable remarketing list ID.
13062	Id int64 `json:"id,omitempty,string"`
13063
13064	// Kind: Identifies what kind of resource this is. Value: the fixed
13065	// string "dfareporting#targetableRemarketingList".
13066	Kind string `json:"kind,omitempty"`
13067
13068	// LifeSpan: Number of days that a user should remain in the targetable
13069	// remarketing list without an impression.
13070	LifeSpan int64 `json:"lifeSpan,omitempty,string"`
13071
13072	// ListSize: Number of users currently in the list. This is a read-only
13073	// field.
13074	ListSize int64 `json:"listSize,omitempty,string"`
13075
13076	// ListSource: Product from which this targetable remarketing list was
13077	// originated.
13078	//
13079	// Possible values:
13080	//   "REMARKETING_LIST_SOURCE_ADX"
13081	//   "REMARKETING_LIST_SOURCE_DBM"
13082	//   "REMARKETING_LIST_SOURCE_DFA"
13083	//   "REMARKETING_LIST_SOURCE_DFP"
13084	//   "REMARKETING_LIST_SOURCE_DMP"
13085	//   "REMARKETING_LIST_SOURCE_GA"
13086	//   "REMARKETING_LIST_SOURCE_GPLUS"
13087	//   "REMARKETING_LIST_SOURCE_OTHER"
13088	//   "REMARKETING_LIST_SOURCE_PLAY_STORE"
13089	//   "REMARKETING_LIST_SOURCE_XFP"
13090	//   "REMARKETING_LIST_SOURCE_YOUTUBE"
13091	ListSource string `json:"listSource,omitempty"`
13092
13093	// Name: Name of the targetable remarketing list. Is no greater than 128
13094	// characters long.
13095	Name string `json:"name,omitempty"`
13096
13097	// SubaccountId: Subaccount ID of this remarketing list. This is a
13098	// read-only, auto-generated field that is only returned in GET
13099	// requests.
13100	SubaccountId int64 `json:"subaccountId,omitempty,string"`
13101
13102	// ServerResponse contains the HTTP response code and headers from the
13103	// server.
13104	googleapi.ServerResponse `json:"-"`
13105
13106	// ForceSendFields is a list of field names (e.g. "AccountId") to
13107	// unconditionally include in API requests. By default, fields with
13108	// empty values are omitted from API requests. However, any non-pointer,
13109	// non-interface field appearing in ForceSendFields will be sent to the
13110	// server regardless of whether the field is empty or not. This may be
13111	// used to include empty fields in Patch requests.
13112	ForceSendFields []string `json:"-"`
13113
13114	// NullFields is a list of field names (e.g. "AccountId") to include in
13115	// API requests with the JSON null value. By default, fields with empty
13116	// values are omitted from API requests. However, any field with an
13117	// empty value appearing in NullFields will be sent to the server as
13118	// null. It is an error if a field in this list has a non-empty value.
13119	// This may be used to include null fields in Patch requests.
13120	NullFields []string `json:"-"`
13121}
13122
13123func (s *TargetableRemarketingList) MarshalJSON() ([]byte, error) {
13124	type NoMethod TargetableRemarketingList
13125	raw := NoMethod(*s)
13126	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13127}
13128
13129// TargetableRemarketingListsListResponse: Targetable remarketing list
13130// response
13131type TargetableRemarketingListsListResponse struct {
13132	// Kind: Identifies what kind of resource this is. Value: the fixed
13133	// string "dfareporting#targetableRemarketingListsListResponse".
13134	Kind string `json:"kind,omitempty"`
13135
13136	// NextPageToken: Pagination token to be used for the next list
13137	// operation.
13138	NextPageToken string `json:"nextPageToken,omitempty"`
13139
13140	// TargetableRemarketingLists: Targetable remarketing list collection.
13141	TargetableRemarketingLists []*TargetableRemarketingList `json:"targetableRemarketingLists,omitempty"`
13142
13143	// ServerResponse contains the HTTP response code and headers from the
13144	// server.
13145	googleapi.ServerResponse `json:"-"`
13146
13147	// ForceSendFields is a list of field names (e.g. "Kind") to
13148	// unconditionally include in API requests. By default, fields with
13149	// empty values are omitted from API requests. However, any non-pointer,
13150	// non-interface field appearing in ForceSendFields will be sent to the
13151	// server regardless of whether the field is empty or not. This may be
13152	// used to include empty fields in Patch requests.
13153	ForceSendFields []string `json:"-"`
13154
13155	// NullFields is a list of field names (e.g. "Kind") to include in API
13156	// requests with the JSON null value. By default, fields with empty
13157	// values are omitted from API requests. However, any field with an
13158	// empty value appearing in NullFields will be sent to the server as
13159	// null. It is an error if a field in this list has a non-empty value.
13160	// This may be used to include null fields in Patch requests.
13161	NullFields []string `json:"-"`
13162}
13163
13164func (s *TargetableRemarketingListsListResponse) MarshalJSON() ([]byte, error) {
13165	type NoMethod TargetableRemarketingListsListResponse
13166	raw := NoMethod(*s)
13167	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13168}
13169
13170// TargetingTemplate: Contains properties of a targeting template. A
13171// targeting template encapsulates targeting information which can be
13172// reused across multiple ads.
13173type TargetingTemplate struct {
13174	// AccountId: Account ID of this targeting template. This field, if left
13175	// unset, will be auto-generated on insert and is read-only after
13176	// insert.
13177	AccountId int64 `json:"accountId,omitempty,string"`
13178
13179	// AdvertiserId: Advertiser ID of this targeting template. This is a
13180	// required field on insert and is read-only after insert.
13181	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
13182
13183	// AdvertiserIdDimensionValue: Dimension value for the ID of the
13184	// advertiser. This is a read-only, auto-generated field.
13185	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
13186
13187	// DayPartTargeting: Time and day targeting criteria.
13188	DayPartTargeting *DayPartTargeting `json:"dayPartTargeting,omitempty"`
13189
13190	// GeoTargeting: Geographical targeting criteria.
13191	GeoTargeting *GeoTargeting `json:"geoTargeting,omitempty"`
13192
13193	// Id: ID of this targeting template. This is a read-only,
13194	// auto-generated field.
13195	Id int64 `json:"id,omitempty,string"`
13196
13197	// KeyValueTargetingExpression: Key-value targeting criteria.
13198	KeyValueTargetingExpression *KeyValueTargetingExpression `json:"keyValueTargetingExpression,omitempty"`
13199
13200	// Kind: Identifies what kind of resource this is. Value: the fixed
13201	// string "dfareporting#targetingTemplate".
13202	Kind string `json:"kind,omitempty"`
13203
13204	// LanguageTargeting: Language targeting criteria.
13205	LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
13206
13207	// ListTargetingExpression: Remarketing list targeting criteria.
13208	ListTargetingExpression *ListTargetingExpression `json:"listTargetingExpression,omitempty"`
13209
13210	// Name: Name of this targeting template. This field is required. It
13211	// must be less than 256 characters long and unique within an
13212	// advertiser.
13213	Name string `json:"name,omitempty"`
13214
13215	// SubaccountId: Subaccount ID of this targeting template. This field,
13216	// if left unset, will be auto-generated on insert and is read-only
13217	// after insert.
13218	SubaccountId int64 `json:"subaccountId,omitempty,string"`
13219
13220	// TechnologyTargeting: Technology platform targeting criteria.
13221	TechnologyTargeting *TechnologyTargeting `json:"technologyTargeting,omitempty"`
13222
13223	// ServerResponse contains the HTTP response code and headers from the
13224	// server.
13225	googleapi.ServerResponse `json:"-"`
13226
13227	// ForceSendFields is a list of field names (e.g. "AccountId") to
13228	// unconditionally include in API requests. By default, fields with
13229	// empty values are omitted from API requests. However, any non-pointer,
13230	// non-interface field appearing in ForceSendFields will be sent to the
13231	// server regardless of whether the field is empty or not. This may be
13232	// used to include empty fields in Patch requests.
13233	ForceSendFields []string `json:"-"`
13234
13235	// NullFields is a list of field names (e.g. "AccountId") to include in
13236	// API requests with the JSON null value. By default, fields with empty
13237	// values are omitted from API requests. However, any field with an
13238	// empty value appearing in NullFields will be sent to the server as
13239	// null. It is an error if a field in this list has a non-empty value.
13240	// This may be used to include null fields in Patch requests.
13241	NullFields []string `json:"-"`
13242}
13243
13244func (s *TargetingTemplate) MarshalJSON() ([]byte, error) {
13245	type NoMethod TargetingTemplate
13246	raw := NoMethod(*s)
13247	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13248}
13249
13250// TargetingTemplatesListResponse: Targeting Template List Response
13251type TargetingTemplatesListResponse struct {
13252	// Kind: Identifies what kind of resource this is. Value: the fixed
13253	// string "dfareporting#targetingTemplatesListResponse".
13254	Kind string `json:"kind,omitempty"`
13255
13256	// NextPageToken: Pagination token to be used for the next list
13257	// operation.
13258	NextPageToken string `json:"nextPageToken,omitempty"`
13259
13260	// TargetingTemplates: Targeting template collection.
13261	TargetingTemplates []*TargetingTemplate `json:"targetingTemplates,omitempty"`
13262
13263	// ServerResponse contains the HTTP response code and headers from the
13264	// server.
13265	googleapi.ServerResponse `json:"-"`
13266
13267	// ForceSendFields is a list of field names (e.g. "Kind") to
13268	// unconditionally include in API requests. By default, fields with
13269	// empty values are omitted from API requests. However, any non-pointer,
13270	// non-interface field appearing in ForceSendFields will be sent to the
13271	// server regardless of whether the field is empty or not. This may be
13272	// used to include empty fields in Patch requests.
13273	ForceSendFields []string `json:"-"`
13274
13275	// NullFields is a list of field names (e.g. "Kind") to include in API
13276	// requests with the JSON null value. By default, fields with empty
13277	// values are omitted from API requests. However, any field with an
13278	// empty value appearing in NullFields will be sent to the server as
13279	// null. It is an error if a field in this list has a non-empty value.
13280	// This may be used to include null fields in Patch requests.
13281	NullFields []string `json:"-"`
13282}
13283
13284func (s *TargetingTemplatesListResponse) MarshalJSON() ([]byte, error) {
13285	type NoMethod TargetingTemplatesListResponse
13286	raw := NoMethod(*s)
13287	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13288}
13289
13290// TechnologyTargeting: Technology Targeting.
13291type TechnologyTargeting struct {
13292	// Browsers: Browsers that this ad targets. For each browser either set
13293	// browserVersionId or dartId along with the version numbers. If both
13294	// are specified, only browserVersionId will be used. The other fields
13295	// are populated automatically when the ad is inserted or updated.
13296	Browsers []*Browser `json:"browsers,omitempty"`
13297
13298	// ConnectionTypes: Connection types that this ad targets. For each
13299	// connection type only id is required. The other fields are populated
13300	// automatically when the ad is inserted or updated.
13301	ConnectionTypes []*ConnectionType `json:"connectionTypes,omitempty"`
13302
13303	// MobileCarriers: Mobile carriers that this ad targets. For each mobile
13304	// carrier only id is required, and the other fields are populated
13305	// automatically when the ad is inserted or updated. If targeting a
13306	// mobile carrier, do not set targeting for any zip codes.
13307	MobileCarriers []*MobileCarrier `json:"mobileCarriers,omitempty"`
13308
13309	// OperatingSystemVersions: Operating system versions that this ad
13310	// targets. To target all versions, use operatingSystems. For each
13311	// operating system version, only id is required. The other fields are
13312	// populated automatically when the ad is inserted or updated. If
13313	// targeting an operating system version, do not set targeting for the
13314	// corresponding operating system in operatingSystems.
13315	OperatingSystemVersions []*OperatingSystemVersion `json:"operatingSystemVersions,omitempty"`
13316
13317	// OperatingSystems: Operating systems that this ad targets. To target
13318	// specific versions, use operatingSystemVersions. For each operating
13319	// system only dartId is required. The other fields are populated
13320	// automatically when the ad is inserted or updated. If targeting an
13321	// operating system, do not set targeting for operating system versions
13322	// for the same operating system.
13323	OperatingSystems []*OperatingSystem `json:"operatingSystems,omitempty"`
13324
13325	// PlatformTypes: Platform types that this ad targets. For example,
13326	// desktop, mobile, or tablet. For each platform type, only id is
13327	// required, and the other fields are populated automatically when the
13328	// ad is inserted or updated.
13329	PlatformTypes []*PlatformType `json:"platformTypes,omitempty"`
13330
13331	// ForceSendFields is a list of field names (e.g. "Browsers") to
13332	// unconditionally include in API requests. By default, fields with
13333	// empty values are omitted from API requests. However, any non-pointer,
13334	// non-interface field appearing in ForceSendFields will be sent to the
13335	// server regardless of whether the field is empty or not. This may be
13336	// used to include empty fields in Patch requests.
13337	ForceSendFields []string `json:"-"`
13338
13339	// NullFields is a list of field names (e.g. "Browsers") to include in
13340	// API requests with the JSON null value. By default, fields with empty
13341	// values are omitted from API requests. However, any field with an
13342	// empty value appearing in NullFields will be sent to the server as
13343	// null. It is an error if a field in this list has a non-empty value.
13344	// This may be used to include null fields in Patch requests.
13345	NullFields []string `json:"-"`
13346}
13347
13348func (s *TechnologyTargeting) MarshalJSON() ([]byte, error) {
13349	type NoMethod TechnologyTargeting
13350	raw := NoMethod(*s)
13351	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13352}
13353
13354// ThirdPartyAuthenticationToken: Third Party Authentication Token
13355type ThirdPartyAuthenticationToken struct {
13356	// Name: Name of the third-party authentication token.
13357	Name string `json:"name,omitempty"`
13358
13359	// Value: Value of the third-party authentication token. This is a
13360	// read-only, auto-generated field.
13361	Value string `json:"value,omitempty"`
13362
13363	// ForceSendFields is a list of field names (e.g. "Name") to
13364	// unconditionally include in API requests. By default, fields with
13365	// empty values are omitted from API requests. However, any non-pointer,
13366	// non-interface field appearing in ForceSendFields will be sent to the
13367	// server regardless of whether the field is empty or not. This may be
13368	// used to include empty fields in Patch requests.
13369	ForceSendFields []string `json:"-"`
13370
13371	// NullFields is a list of field names (e.g. "Name") to include in API
13372	// requests with the JSON null value. By default, fields with empty
13373	// values are omitted from API requests. However, any field with an
13374	// empty value appearing in NullFields will be sent to the server as
13375	// null. It is an error if a field in this list has a non-empty value.
13376	// This may be used to include null fields in Patch requests.
13377	NullFields []string `json:"-"`
13378}
13379
13380func (s *ThirdPartyAuthenticationToken) MarshalJSON() ([]byte, error) {
13381	type NoMethod ThirdPartyAuthenticationToken
13382	raw := NoMethod(*s)
13383	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13384}
13385
13386// ThirdPartyTrackingUrl: Third-party Tracking URL.
13387type ThirdPartyTrackingUrl struct {
13388	// ThirdPartyUrlType: Third-party URL type for in-stream video and
13389	// in-stream audio creatives.
13390	//
13391	// Possible values:
13392	//   "CLICK_TRACKING"
13393	//   "IMPRESSION"
13394	//   "RICH_MEDIA_BACKUP_IMPRESSION"
13395	//   "RICH_MEDIA_IMPRESSION"
13396	//   "RICH_MEDIA_RM_IMPRESSION"
13397	//   "SURVEY"
13398	//   "VIDEO_COMPLETE"
13399	//   "VIDEO_CUSTOM"
13400	//   "VIDEO_FIRST_QUARTILE"
13401	//   "VIDEO_FULLSCREEN"
13402	//   "VIDEO_MIDPOINT"
13403	//   "VIDEO_MUTE"
13404	//   "VIDEO_PAUSE"
13405	//   "VIDEO_PROGRESS"
13406	//   "VIDEO_REWIND"
13407	//   "VIDEO_SKIP"
13408	//   "VIDEO_START"
13409	//   "VIDEO_STOP"
13410	//   "VIDEO_THIRD_QUARTILE"
13411	ThirdPartyUrlType string `json:"thirdPartyUrlType,omitempty"`
13412
13413	// Url: URL for the specified third-party URL type.
13414	Url string `json:"url,omitempty"`
13415
13416	// ForceSendFields is a list of field names (e.g. "ThirdPartyUrlType")
13417	// to unconditionally include in API requests. By default, fields with
13418	// empty values are omitted from API requests. However, any non-pointer,
13419	// non-interface field appearing in ForceSendFields will be sent to the
13420	// server regardless of whether the field is empty or not. This may be
13421	// used to include empty fields in Patch requests.
13422	ForceSendFields []string `json:"-"`
13423
13424	// NullFields is a list of field names (e.g. "ThirdPartyUrlType") to
13425	// include in API requests with the JSON null value. By default, fields
13426	// with empty values are omitted from API requests. However, any field
13427	// with an empty value appearing in NullFields will be sent to the
13428	// server as null. It is an error if a field in this list has a
13429	// non-empty value. This may be used to include null fields in Patch
13430	// requests.
13431	NullFields []string `json:"-"`
13432}
13433
13434func (s *ThirdPartyTrackingUrl) MarshalJSON() ([]byte, error) {
13435	type NoMethod ThirdPartyTrackingUrl
13436	raw := NoMethod(*s)
13437	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13438}
13439
13440// TranscodeSetting: Transcode Settings
13441type TranscodeSetting struct {
13442	// EnabledVideoFormats: Whitelist of video formats to be served to this
13443	// placement. Set this list to null or empty to serve all video formats.
13444	EnabledVideoFormats []int64 `json:"enabledVideoFormats,omitempty"`
13445
13446	// Kind: Identifies what kind of resource this is. Value: the fixed
13447	// string "dfareporting#transcodeSetting".
13448	Kind string `json:"kind,omitempty"`
13449
13450	// ForceSendFields is a list of field names (e.g. "EnabledVideoFormats")
13451	// to unconditionally include in API requests. By default, fields with
13452	// empty values are omitted from API requests. However, any non-pointer,
13453	// non-interface field appearing in ForceSendFields will be sent to the
13454	// server regardless of whether the field is empty or not. This may be
13455	// used to include empty fields in Patch requests.
13456	ForceSendFields []string `json:"-"`
13457
13458	// NullFields is a list of field names (e.g. "EnabledVideoFormats") to
13459	// include in API requests with the JSON null value. By default, fields
13460	// with empty values are omitted from API requests. However, any field
13461	// with an empty value appearing in NullFields will be sent to the
13462	// server as null. It is an error if a field in this list has a
13463	// non-empty value. This may be used to include null fields in Patch
13464	// requests.
13465	NullFields []string `json:"-"`
13466}
13467
13468func (s *TranscodeSetting) MarshalJSON() ([]byte, error) {
13469	type NoMethod TranscodeSetting
13470	raw := NoMethod(*s)
13471	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13472}
13473
13474// UniversalAdId: A Universal Ad ID as per the VAST 4.0 spec. Applicable
13475// to the following creative types: INSTREAM_AUDIO, INSTREAM_VIDEO and
13476// VPAID.
13477type UniversalAdId struct {
13478	// Registry: Registry used for the Ad ID value.
13479	//
13480	// Possible values:
13481	//   "AD_ID.ORG"
13482	//   "CLEARCAST"
13483	//   "DCM"
13484	//   "OTHER"
13485	Registry string `json:"registry,omitempty"`
13486
13487	// Value: ID value for this creative. Only alphanumeric characters and
13488	// the following symbols are valid: "_/\-". Maximum length is 64
13489	// characters. Read only when registry is DCM.
13490	Value string `json:"value,omitempty"`
13491
13492	// ForceSendFields is a list of field names (e.g. "Registry") to
13493	// unconditionally include in API requests. By default, fields with
13494	// empty values are omitted from API requests. However, any non-pointer,
13495	// non-interface field appearing in ForceSendFields will be sent to the
13496	// server regardless of whether the field is empty or not. This may be
13497	// used to include empty fields in Patch requests.
13498	ForceSendFields []string `json:"-"`
13499
13500	// NullFields is a list of field names (e.g. "Registry") to include in
13501	// API requests with the JSON null value. By default, fields with empty
13502	// values are omitted from API requests. However, any field with an
13503	// empty value appearing in NullFields will be sent to the server as
13504	// null. It is an error if a field in this list has a non-empty value.
13505	// This may be used to include null fields in Patch requests.
13506	NullFields []string `json:"-"`
13507}
13508
13509func (s *UniversalAdId) MarshalJSON() ([]byte, error) {
13510	type NoMethod UniversalAdId
13511	raw := NoMethod(*s)
13512	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13513}
13514
13515// UserDefinedVariableConfiguration: User Defined Variable
13516// configuration.
13517type UserDefinedVariableConfiguration struct {
13518	// DataType: Data type for the variable. This is a required field.
13519	//
13520	// Possible values:
13521	//   "NUMBER"
13522	//   "STRING"
13523	DataType string `json:"dataType,omitempty"`
13524
13525	// ReportName: User-friendly name for the variable which will appear in
13526	// reports. This is a required field, must be less than 64 characters
13527	// long, and cannot contain the following characters: ""<>".
13528	ReportName string `json:"reportName,omitempty"`
13529
13530	// VariableType: Variable name in the tag. This is a required field.
13531	//
13532	// Possible values:
13533	//   "U1"
13534	//   "U10"
13535	//   "U100"
13536	//   "U11"
13537	//   "U12"
13538	//   "U13"
13539	//   "U14"
13540	//   "U15"
13541	//   "U16"
13542	//   "U17"
13543	//   "U18"
13544	//   "U19"
13545	//   "U2"
13546	//   "U20"
13547	//   "U21"
13548	//   "U22"
13549	//   "U23"
13550	//   "U24"
13551	//   "U25"
13552	//   "U26"
13553	//   "U27"
13554	//   "U28"
13555	//   "U29"
13556	//   "U3"
13557	//   "U30"
13558	//   "U31"
13559	//   "U32"
13560	//   "U33"
13561	//   "U34"
13562	//   "U35"
13563	//   "U36"
13564	//   "U37"
13565	//   "U38"
13566	//   "U39"
13567	//   "U4"
13568	//   "U40"
13569	//   "U41"
13570	//   "U42"
13571	//   "U43"
13572	//   "U44"
13573	//   "U45"
13574	//   "U46"
13575	//   "U47"
13576	//   "U48"
13577	//   "U49"
13578	//   "U5"
13579	//   "U50"
13580	//   "U51"
13581	//   "U52"
13582	//   "U53"
13583	//   "U54"
13584	//   "U55"
13585	//   "U56"
13586	//   "U57"
13587	//   "U58"
13588	//   "U59"
13589	//   "U6"
13590	//   "U60"
13591	//   "U61"
13592	//   "U62"
13593	//   "U63"
13594	//   "U64"
13595	//   "U65"
13596	//   "U66"
13597	//   "U67"
13598	//   "U68"
13599	//   "U69"
13600	//   "U7"
13601	//   "U70"
13602	//   "U71"
13603	//   "U72"
13604	//   "U73"
13605	//   "U74"
13606	//   "U75"
13607	//   "U76"
13608	//   "U77"
13609	//   "U78"
13610	//   "U79"
13611	//   "U8"
13612	//   "U80"
13613	//   "U81"
13614	//   "U82"
13615	//   "U83"
13616	//   "U84"
13617	//   "U85"
13618	//   "U86"
13619	//   "U87"
13620	//   "U88"
13621	//   "U89"
13622	//   "U9"
13623	//   "U90"
13624	//   "U91"
13625	//   "U92"
13626	//   "U93"
13627	//   "U94"
13628	//   "U95"
13629	//   "U96"
13630	//   "U97"
13631	//   "U98"
13632	//   "U99"
13633	VariableType string `json:"variableType,omitempty"`
13634
13635	// ForceSendFields is a list of field names (e.g. "DataType") to
13636	// unconditionally include in API requests. By default, fields with
13637	// empty values are omitted from API requests. However, any non-pointer,
13638	// non-interface field appearing in ForceSendFields will be sent to the
13639	// server regardless of whether the field is empty or not. This may be
13640	// used to include empty fields in Patch requests.
13641	ForceSendFields []string `json:"-"`
13642
13643	// NullFields is a list of field names (e.g. "DataType") to include in
13644	// API requests with the JSON null value. By default, fields with empty
13645	// values are omitted from API requests. However, any field with an
13646	// empty value appearing in NullFields will be sent to the server as
13647	// null. It is an error if a field in this list has a non-empty value.
13648	// This may be used to include null fields in Patch requests.
13649	NullFields []string `json:"-"`
13650}
13651
13652func (s *UserDefinedVariableConfiguration) MarshalJSON() ([]byte, error) {
13653	type NoMethod UserDefinedVariableConfiguration
13654	raw := NoMethod(*s)
13655	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13656}
13657
13658// UserProfile: Represents a UserProfile resource.
13659type UserProfile struct {
13660	// AccountId: The account ID to which this profile belongs.
13661	AccountId int64 `json:"accountId,omitempty,string"`
13662
13663	// AccountName: The account name this profile belongs to.
13664	AccountName string `json:"accountName,omitempty"`
13665
13666	// Etag: The eTag of this response for caching purposes.
13667	Etag string `json:"etag,omitempty"`
13668
13669	// Kind: The kind of resource this is, in this case
13670	// dfareporting#userProfile.
13671	Kind string `json:"kind,omitempty"`
13672
13673	// ProfileId: The unique ID of the user profile.
13674	ProfileId int64 `json:"profileId,omitempty,string"`
13675
13676	// SubAccountId: The sub account ID this profile belongs to if
13677	// applicable.
13678	SubAccountId int64 `json:"subAccountId,omitempty,string"`
13679
13680	// SubAccountName: The sub account name this profile belongs to if
13681	// applicable.
13682	SubAccountName string `json:"subAccountName,omitempty"`
13683
13684	// UserName: The user name.
13685	UserName string `json:"userName,omitempty"`
13686
13687	// ServerResponse contains the HTTP response code and headers from the
13688	// server.
13689	googleapi.ServerResponse `json:"-"`
13690
13691	// ForceSendFields is a list of field names (e.g. "AccountId") to
13692	// unconditionally include in API requests. By default, fields with
13693	// empty values are omitted from API requests. However, any non-pointer,
13694	// non-interface field appearing in ForceSendFields will be sent to the
13695	// server regardless of whether the field is empty or not. This may be
13696	// used to include empty fields in Patch requests.
13697	ForceSendFields []string `json:"-"`
13698
13699	// NullFields is a list of field names (e.g. "AccountId") to include in
13700	// API requests with the JSON null value. By default, fields with empty
13701	// values are omitted from API requests. However, any field with an
13702	// empty value appearing in NullFields will be sent to the server as
13703	// null. It is an error if a field in this list has a non-empty value.
13704	// This may be used to include null fields in Patch requests.
13705	NullFields []string `json:"-"`
13706}
13707
13708func (s *UserProfile) MarshalJSON() ([]byte, error) {
13709	type NoMethod UserProfile
13710	raw := NoMethod(*s)
13711	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13712}
13713
13714// UserProfileList: Represents the list of user profiles.
13715type UserProfileList struct {
13716	// Etag: The eTag of this response for caching purposes.
13717	Etag string `json:"etag,omitempty"`
13718
13719	// Items: The user profiles returned in this response.
13720	Items []*UserProfile `json:"items,omitempty"`
13721
13722	// Kind: The kind of list this is, in this case
13723	// dfareporting#userProfileList.
13724	Kind string `json:"kind,omitempty"`
13725
13726	// ServerResponse contains the HTTP response code and headers from the
13727	// server.
13728	googleapi.ServerResponse `json:"-"`
13729
13730	// ForceSendFields is a list of field names (e.g. "Etag") to
13731	// unconditionally include in API requests. By default, fields with
13732	// empty values are omitted from API requests. However, any non-pointer,
13733	// non-interface field appearing in ForceSendFields will be sent to the
13734	// server regardless of whether the field is empty or not. This may be
13735	// used to include empty fields in Patch requests.
13736	ForceSendFields []string `json:"-"`
13737
13738	// NullFields is a list of field names (e.g. "Etag") to include in API
13739	// requests with the JSON null value. By default, fields with empty
13740	// values are omitted from API requests. However, any field with an
13741	// empty value appearing in NullFields will be sent to the server as
13742	// null. It is an error if a field in this list has a non-empty value.
13743	// This may be used to include null fields in Patch requests.
13744	NullFields []string `json:"-"`
13745}
13746
13747func (s *UserProfileList) MarshalJSON() ([]byte, error) {
13748	type NoMethod UserProfileList
13749	raw := NoMethod(*s)
13750	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13751}
13752
13753// UserRole: Contains properties of auser role, which is used to manage
13754// user access.
13755type UserRole struct {
13756	// AccountId: Account ID of this user role. This is a read-only field
13757	// that can be left blank.
13758	AccountId int64 `json:"accountId,omitempty,string"`
13759
13760	// DefaultUserRole: Whether this is a default user role. Default user
13761	// roles are created by the system for the account/subaccount and cannot
13762	// be modified or deleted. Each default user role comes with a basic set
13763	// of preassigned permissions.
13764	DefaultUserRole bool `json:"defaultUserRole,omitempty"`
13765
13766	// Id: ID of this user role. This is a read-only, auto-generated field.
13767	Id int64 `json:"id,omitempty,string"`
13768
13769	// Kind: Identifies what kind of resource this is. Value: the fixed
13770	// string "dfareporting#userRole".
13771	Kind string `json:"kind,omitempty"`
13772
13773	// Name: Name of this user role. This is a required field. Must be less
13774	// than 256 characters long. If this user role is under a subaccount,
13775	// the name must be unique among sites of the same subaccount.
13776	// Otherwise, this user role is a top-level user role, and the name must
13777	// be unique among top-level user roles of the same account.
13778	Name string `json:"name,omitempty"`
13779
13780	// ParentUserRoleId: ID of the user role that this user role is based on
13781	// or copied from. This is a required field.
13782	ParentUserRoleId int64 `json:"parentUserRoleId,omitempty,string"`
13783
13784	// Permissions: List of permissions associated with this user role.
13785	Permissions []*UserRolePermission `json:"permissions,omitempty"`
13786
13787	// SubaccountId: Subaccount ID of this user role. This is a read-only
13788	// field that can be left blank.
13789	SubaccountId int64 `json:"subaccountId,omitempty,string"`
13790
13791	// ServerResponse contains the HTTP response code and headers from the
13792	// server.
13793	googleapi.ServerResponse `json:"-"`
13794
13795	// ForceSendFields is a list of field names (e.g. "AccountId") to
13796	// unconditionally include in API requests. By default, fields with
13797	// empty values are omitted from API requests. However, any non-pointer,
13798	// non-interface field appearing in ForceSendFields will be sent to the
13799	// server regardless of whether the field is empty or not. This may be
13800	// used to include empty fields in Patch requests.
13801	ForceSendFields []string `json:"-"`
13802
13803	// NullFields is a list of field names (e.g. "AccountId") to include in
13804	// API requests with the JSON null value. By default, fields with empty
13805	// values are omitted from API requests. However, any field with an
13806	// empty value appearing in NullFields will be sent to the server as
13807	// null. It is an error if a field in this list has a non-empty value.
13808	// This may be used to include null fields in Patch requests.
13809	NullFields []string `json:"-"`
13810}
13811
13812func (s *UserRole) MarshalJSON() ([]byte, error) {
13813	type NoMethod UserRole
13814	raw := NoMethod(*s)
13815	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13816}
13817
13818// UserRolePermission: Contains properties of a user role permission.
13819type UserRolePermission struct {
13820	// Availability: Levels of availability for a user role permission.
13821	//
13822	// Possible values:
13823	//   "ACCOUNT_ALWAYS"
13824	//   "ACCOUNT_BY_DEFAULT"
13825	//   "NOT_AVAILABLE_BY_DEFAULT"
13826	//   "SUBACCOUNT_AND_ACCOUNT_ALWAYS"
13827	//   "SUBACCOUNT_AND_ACCOUNT_BY_DEFAULT"
13828	Availability string `json:"availability,omitempty"`
13829
13830	// Id: ID of this user role permission.
13831	Id int64 `json:"id,omitempty,string"`
13832
13833	// Kind: Identifies what kind of resource this is. Value: the fixed
13834	// string "dfareporting#userRolePermission".
13835	Kind string `json:"kind,omitempty"`
13836
13837	// Name: Name of this user role permission.
13838	Name string `json:"name,omitempty"`
13839
13840	// PermissionGroupId: ID of the permission group that this user role
13841	// permission belongs to.
13842	PermissionGroupId int64 `json:"permissionGroupId,omitempty,string"`
13843
13844	// ServerResponse contains the HTTP response code and headers from the
13845	// server.
13846	googleapi.ServerResponse `json:"-"`
13847
13848	// ForceSendFields is a list of field names (e.g. "Availability") to
13849	// unconditionally include in API requests. By default, fields with
13850	// empty values are omitted from API requests. However, any non-pointer,
13851	// non-interface field appearing in ForceSendFields will be sent to the
13852	// server regardless of whether the field is empty or not. This may be
13853	// used to include empty fields in Patch requests.
13854	ForceSendFields []string `json:"-"`
13855
13856	// NullFields is a list of field names (e.g. "Availability") to include
13857	// in API requests with the JSON null value. By default, fields with
13858	// empty values are omitted from API requests. However, any field with
13859	// an empty value appearing in NullFields will be sent to the server as
13860	// null. It is an error if a field in this list has a non-empty value.
13861	// This may be used to include null fields in Patch requests.
13862	NullFields []string `json:"-"`
13863}
13864
13865func (s *UserRolePermission) MarshalJSON() ([]byte, error) {
13866	type NoMethod UserRolePermission
13867	raw := NoMethod(*s)
13868	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13869}
13870
13871// UserRolePermissionGroup: Represents a grouping of related user role
13872// permissions.
13873type UserRolePermissionGroup struct {
13874	// Id: ID of this user role permission.
13875	Id int64 `json:"id,omitempty,string"`
13876
13877	// Kind: Identifies what kind of resource this is. Value: the fixed
13878	// string "dfareporting#userRolePermissionGroup".
13879	Kind string `json:"kind,omitempty"`
13880
13881	// Name: Name of this user role permission group.
13882	Name string `json:"name,omitempty"`
13883
13884	// ServerResponse contains the HTTP response code and headers from the
13885	// server.
13886	googleapi.ServerResponse `json:"-"`
13887
13888	// ForceSendFields is a list of field names (e.g. "Id") to
13889	// unconditionally include in API requests. By default, fields with
13890	// empty values are omitted from API requests. However, any non-pointer,
13891	// non-interface field appearing in ForceSendFields will be sent to the
13892	// server regardless of whether the field is empty or not. This may be
13893	// used to include empty fields in Patch requests.
13894	ForceSendFields []string `json:"-"`
13895
13896	// NullFields is a list of field names (e.g. "Id") to include in API
13897	// requests with the JSON null value. By default, fields with empty
13898	// values are omitted from API requests. However, any field with an
13899	// empty value appearing in NullFields will be sent to the server as
13900	// null. It is an error if a field in this list has a non-empty value.
13901	// This may be used to include null fields in Patch requests.
13902	NullFields []string `json:"-"`
13903}
13904
13905func (s *UserRolePermissionGroup) MarshalJSON() ([]byte, error) {
13906	type NoMethod UserRolePermissionGroup
13907	raw := NoMethod(*s)
13908	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13909}
13910
13911// UserRolePermissionGroupsListResponse: User Role Permission Group List
13912// Response
13913type UserRolePermissionGroupsListResponse struct {
13914	// Kind: Identifies what kind of resource this is. Value: the fixed
13915	// string "dfareporting#userRolePermissionGroupsListResponse".
13916	Kind string `json:"kind,omitempty"`
13917
13918	// UserRolePermissionGroups: User role permission group collection.
13919	UserRolePermissionGroups []*UserRolePermissionGroup `json:"userRolePermissionGroups,omitempty"`
13920
13921	// ServerResponse contains the HTTP response code and headers from the
13922	// server.
13923	googleapi.ServerResponse `json:"-"`
13924
13925	// ForceSendFields is a list of field names (e.g. "Kind") to
13926	// unconditionally include in API requests. By default, fields with
13927	// empty values are omitted from API requests. However, any non-pointer,
13928	// non-interface field appearing in ForceSendFields will be sent to the
13929	// server regardless of whether the field is empty or not. This may be
13930	// used to include empty fields in Patch requests.
13931	ForceSendFields []string `json:"-"`
13932
13933	// NullFields is a list of field names (e.g. "Kind") to include in API
13934	// requests with the JSON null value. By default, fields with empty
13935	// values are omitted from API requests. However, any field with an
13936	// empty value appearing in NullFields will be sent to the server as
13937	// null. It is an error if a field in this list has a non-empty value.
13938	// This may be used to include null fields in Patch requests.
13939	NullFields []string `json:"-"`
13940}
13941
13942func (s *UserRolePermissionGroupsListResponse) MarshalJSON() ([]byte, error) {
13943	type NoMethod UserRolePermissionGroupsListResponse
13944	raw := NoMethod(*s)
13945	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13946}
13947
13948// UserRolePermissionsListResponse: User Role Permission List Response
13949type UserRolePermissionsListResponse struct {
13950	// Kind: Identifies what kind of resource this is. Value: the fixed
13951	// string "dfareporting#userRolePermissionsListResponse".
13952	Kind string `json:"kind,omitempty"`
13953
13954	// UserRolePermissions: User role permission collection.
13955	UserRolePermissions []*UserRolePermission `json:"userRolePermissions,omitempty"`
13956
13957	// ServerResponse contains the HTTP response code and headers from the
13958	// server.
13959	googleapi.ServerResponse `json:"-"`
13960
13961	// ForceSendFields is a list of field names (e.g. "Kind") to
13962	// unconditionally include in API requests. By default, fields with
13963	// empty values are omitted from API requests. However, any non-pointer,
13964	// non-interface field appearing in ForceSendFields will be sent to the
13965	// server regardless of whether the field is empty or not. This may be
13966	// used to include empty fields in Patch requests.
13967	ForceSendFields []string `json:"-"`
13968
13969	// NullFields is a list of field names (e.g. "Kind") to include in API
13970	// requests with the JSON null value. By default, fields with empty
13971	// values are omitted from API requests. However, any field with an
13972	// empty value appearing in NullFields will be sent to the server as
13973	// null. It is an error if a field in this list has a non-empty value.
13974	// This may be used to include null fields in Patch requests.
13975	NullFields []string `json:"-"`
13976}
13977
13978func (s *UserRolePermissionsListResponse) MarshalJSON() ([]byte, error) {
13979	type NoMethod UserRolePermissionsListResponse
13980	raw := NoMethod(*s)
13981	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13982}
13983
13984// UserRolesListResponse: User Role List Response
13985type UserRolesListResponse struct {
13986	// Kind: Identifies what kind of resource this is. Value: the fixed
13987	// string "dfareporting#userRolesListResponse".
13988	Kind string `json:"kind,omitempty"`
13989
13990	// NextPageToken: Pagination token to be used for the next list
13991	// operation.
13992	NextPageToken string `json:"nextPageToken,omitempty"`
13993
13994	// UserRoles: User role collection.
13995	UserRoles []*UserRole `json:"userRoles,omitempty"`
13996
13997	// ServerResponse contains the HTTP response code and headers from the
13998	// server.
13999	googleapi.ServerResponse `json:"-"`
14000
14001	// ForceSendFields is a list of field names (e.g. "Kind") to
14002	// unconditionally include in API requests. By default, fields with
14003	// empty values are omitted from API requests. However, any non-pointer,
14004	// non-interface field appearing in ForceSendFields will be sent to the
14005	// server regardless of whether the field is empty or not. This may be
14006	// used to include empty fields in Patch requests.
14007	ForceSendFields []string `json:"-"`
14008
14009	// NullFields is a list of field names (e.g. "Kind") to include in API
14010	// requests with the JSON null value. By default, fields with empty
14011	// values are omitted from API requests. However, any field with an
14012	// empty value appearing in NullFields will be sent to the server as
14013	// null. It is an error if a field in this list has a non-empty value.
14014	// This may be used to include null fields in Patch requests.
14015	NullFields []string `json:"-"`
14016}
14017
14018func (s *UserRolesListResponse) MarshalJSON() ([]byte, error) {
14019	type NoMethod UserRolesListResponse
14020	raw := NoMethod(*s)
14021	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14022}
14023
14024// VideoFormat: Contains information about supported video formats.
14025type VideoFormat struct {
14026	// FileType: File type of the video format.
14027	//
14028	// Possible values:
14029	//   "FLV"
14030	//   "M3U8"
14031	//   "MP4"
14032	//   "THREEGPP"
14033	//   "WEBM"
14034	FileType string `json:"fileType,omitempty"`
14035
14036	// Id: ID of the video format.
14037	Id int64 `json:"id,omitempty"`
14038
14039	// Kind: Identifies what kind of resource this is. Value: the fixed
14040	// string "dfareporting#videoFormat".
14041	Kind string `json:"kind,omitempty"`
14042
14043	// Resolution: The resolution of this video format.
14044	Resolution *Size `json:"resolution,omitempty"`
14045
14046	// TargetBitRate: The target bit rate of this video format.
14047	TargetBitRate int64 `json:"targetBitRate,omitempty"`
14048
14049	// ServerResponse contains the HTTP response code and headers from the
14050	// server.
14051	googleapi.ServerResponse `json:"-"`
14052
14053	// ForceSendFields is a list of field names (e.g. "FileType") to
14054	// unconditionally include in API requests. By default, fields with
14055	// empty values are omitted from API requests. However, any non-pointer,
14056	// non-interface field appearing in ForceSendFields will be sent to the
14057	// server regardless of whether the field is empty or not. This may be
14058	// used to include empty fields in Patch requests.
14059	ForceSendFields []string `json:"-"`
14060
14061	// NullFields is a list of field names (e.g. "FileType") to include in
14062	// API requests with the JSON null value. By default, fields with empty
14063	// values are omitted from API requests. However, any field with an
14064	// empty value appearing in NullFields will be sent to the server as
14065	// null. It is an error if a field in this list has a non-empty value.
14066	// This may be used to include null fields in Patch requests.
14067	NullFields []string `json:"-"`
14068}
14069
14070func (s *VideoFormat) MarshalJSON() ([]byte, error) {
14071	type NoMethod VideoFormat
14072	raw := NoMethod(*s)
14073	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14074}
14075
14076// VideoFormatsListResponse: Video Format List Response
14077type VideoFormatsListResponse struct {
14078	// Kind: Identifies what kind of resource this is. Value: the fixed
14079	// string "dfareporting#videoFormatsListResponse".
14080	Kind string `json:"kind,omitempty"`
14081
14082	// VideoFormats: Video format collection.
14083	VideoFormats []*VideoFormat `json:"videoFormats,omitempty"`
14084
14085	// ServerResponse contains the HTTP response code and headers from the
14086	// server.
14087	googleapi.ServerResponse `json:"-"`
14088
14089	// ForceSendFields is a list of field names (e.g. "Kind") to
14090	// unconditionally include in API requests. By default, fields with
14091	// empty values are omitted from API requests. However, any non-pointer,
14092	// non-interface field appearing in ForceSendFields will be sent to the
14093	// server regardless of whether the field is empty or not. This may be
14094	// used to include empty fields in Patch requests.
14095	ForceSendFields []string `json:"-"`
14096
14097	// NullFields is a list of field names (e.g. "Kind") to include in API
14098	// requests with the JSON null value. By default, fields with empty
14099	// values are omitted from API requests. However, any field with an
14100	// empty value appearing in NullFields will be sent to the server as
14101	// null. It is an error if a field in this list has a non-empty value.
14102	// This may be used to include null fields in Patch requests.
14103	NullFields []string `json:"-"`
14104}
14105
14106func (s *VideoFormatsListResponse) MarshalJSON() ([]byte, error) {
14107	type NoMethod VideoFormatsListResponse
14108	raw := NoMethod(*s)
14109	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14110}
14111
14112// VideoOffset: Video Offset
14113type VideoOffset struct {
14114	// OffsetPercentage: Duration, as a percentage of video duration. Do not
14115	// set when offsetSeconds is set. Acceptable values are 0 to 100,
14116	// inclusive.
14117	OffsetPercentage int64 `json:"offsetPercentage,omitempty"`
14118
14119	// OffsetSeconds: Duration, in seconds. Do not set when offsetPercentage
14120	// is set. Acceptable values are 0 to 86399, inclusive.
14121	OffsetSeconds int64 `json:"offsetSeconds,omitempty"`
14122
14123	// ForceSendFields is a list of field names (e.g. "OffsetPercentage") to
14124	// unconditionally include in API requests. By default, fields with
14125	// empty values are omitted from API requests. However, any non-pointer,
14126	// non-interface field appearing in ForceSendFields will be sent to the
14127	// server regardless of whether the field is empty or not. This may be
14128	// used to include empty fields in Patch requests.
14129	ForceSendFields []string `json:"-"`
14130
14131	// NullFields is a list of field names (e.g. "OffsetPercentage") to
14132	// include in API requests with the JSON null value. By default, fields
14133	// with empty values are omitted from API requests. However, any field
14134	// with an empty value appearing in NullFields will be sent to the
14135	// server as null. It is an error if a field in this list has a
14136	// non-empty value. This may be used to include null fields in Patch
14137	// requests.
14138	NullFields []string `json:"-"`
14139}
14140
14141func (s *VideoOffset) MarshalJSON() ([]byte, error) {
14142	type NoMethod VideoOffset
14143	raw := NoMethod(*s)
14144	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14145}
14146
14147// VideoSettings: Video Settings
14148type VideoSettings struct {
14149	// CompanionSettings: Settings for the companion creatives of video
14150	// creatives served to this placement.
14151	CompanionSettings *CompanionSetting `json:"companionSettings,omitempty"`
14152
14153	// Kind: Identifies what kind of resource this is. Value: the fixed
14154	// string "dfareporting#videoSettings".
14155	Kind string `json:"kind,omitempty"`
14156
14157	// Orientation: Orientation of a video placement. If this value is set,
14158	// placement will return assets matching the specified orientation.
14159	//
14160	// Possible values:
14161	//   "ANY"
14162	//   "LANDSCAPE"
14163	//   "PORTRAIT"
14164	Orientation string `json:"orientation,omitempty"`
14165
14166	// SkippableSettings: Settings for the skippability of video creatives
14167	// served to this placement. If this object is provided, the
14168	// creative-level skippable settings will be overridden.
14169	SkippableSettings *SkippableSetting `json:"skippableSettings,omitempty"`
14170
14171	// TranscodeSettings: Settings for the transcodes of video creatives
14172	// served to this placement. If this object is provided, the
14173	// creative-level transcode settings will be overridden.
14174	TranscodeSettings *TranscodeSetting `json:"transcodeSettings,omitempty"`
14175
14176	// ForceSendFields is a list of field names (e.g. "CompanionSettings")
14177	// to unconditionally include in API requests. By default, fields with
14178	// empty values are omitted from API requests. However, any non-pointer,
14179	// non-interface field appearing in ForceSendFields will be sent to the
14180	// server regardless of whether the field is empty or not. This may be
14181	// used to include empty fields in Patch requests.
14182	ForceSendFields []string `json:"-"`
14183
14184	// NullFields is a list of field names (e.g. "CompanionSettings") to
14185	// include in API requests with the JSON null value. By default, fields
14186	// with empty values are omitted from API requests. However, any field
14187	// with an empty value appearing in NullFields will be sent to the
14188	// server as null. It is an error if a field in this list has a
14189	// non-empty value. This may be used to include null fields in Patch
14190	// requests.
14191	NullFields []string `json:"-"`
14192}
14193
14194func (s *VideoSettings) MarshalJSON() ([]byte, error) {
14195	type NoMethod VideoSettings
14196	raw := NoMethod(*s)
14197	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14198}
14199
14200// method id "dfareporting.accountActiveAdSummaries.get":
14201
14202type AccountActiveAdSummariesGetCall struct {
14203	s                *Service
14204	profileId        int64
14205	summaryAccountId int64
14206	urlParams_       gensupport.URLParams
14207	ifNoneMatch_     string
14208	ctx_             context.Context
14209	header_          http.Header
14210}
14211
14212// Get: Gets the account's active ad summary by account ID.
14213func (r *AccountActiveAdSummariesService) Get(profileId int64, summaryAccountId int64) *AccountActiveAdSummariesGetCall {
14214	c := &AccountActiveAdSummariesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14215	c.profileId = profileId
14216	c.summaryAccountId = summaryAccountId
14217	return c
14218}
14219
14220// Fields allows partial responses to be retrieved. See
14221// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
14222// for more information.
14223func (c *AccountActiveAdSummariesGetCall) Fields(s ...googleapi.Field) *AccountActiveAdSummariesGetCall {
14224	c.urlParams_.Set("fields", googleapi.CombineFields(s))
14225	return c
14226}
14227
14228// IfNoneMatch sets the optional parameter which makes the operation
14229// fail if the object's ETag matches the given value. This is useful for
14230// getting updates only after the object has changed since the last
14231// request. Use googleapi.IsNotModified to check whether the response
14232// error from Do is the result of In-None-Match.
14233func (c *AccountActiveAdSummariesGetCall) IfNoneMatch(entityTag string) *AccountActiveAdSummariesGetCall {
14234	c.ifNoneMatch_ = entityTag
14235	return c
14236}
14237
14238// Context sets the context to be used in this call's Do method. Any
14239// pending HTTP request will be aborted if the provided context is
14240// canceled.
14241func (c *AccountActiveAdSummariesGetCall) Context(ctx context.Context) *AccountActiveAdSummariesGetCall {
14242	c.ctx_ = ctx
14243	return c
14244}
14245
14246// Header returns an http.Header that can be modified by the caller to
14247// add HTTP headers to the request.
14248func (c *AccountActiveAdSummariesGetCall) Header() http.Header {
14249	if c.header_ == nil {
14250		c.header_ = make(http.Header)
14251	}
14252	return c.header_
14253}
14254
14255func (c *AccountActiveAdSummariesGetCall) doRequest(alt string) (*http.Response, error) {
14256	reqHeaders := make(http.Header)
14257	for k, v := range c.header_ {
14258		reqHeaders[k] = v
14259	}
14260	reqHeaders.Set("User-Agent", c.s.userAgent())
14261	if c.ifNoneMatch_ != "" {
14262		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14263	}
14264	var body io.Reader = nil
14265	c.urlParams_.Set("alt", alt)
14266	c.urlParams_.Set("prettyPrint", "false")
14267	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountActiveAdSummaries/{summaryAccountId}")
14268	urls += "?" + c.urlParams_.Encode()
14269	req, err := http.NewRequest("GET", urls, body)
14270	if err != nil {
14271		return nil, err
14272	}
14273	req.Header = reqHeaders
14274	googleapi.Expand(req.URL, map[string]string{
14275		"profileId":        strconv.FormatInt(c.profileId, 10),
14276		"summaryAccountId": strconv.FormatInt(c.summaryAccountId, 10),
14277	})
14278	return gensupport.SendRequest(c.ctx_, c.s.client, req)
14279}
14280
14281// Do executes the "dfareporting.accountActiveAdSummaries.get" call.
14282// Exactly one of *AccountActiveAdSummary or error will be non-nil. Any
14283// non-2xx status code is an error. Response headers are in either
14284// *AccountActiveAdSummary.ServerResponse.Header or (if a response was
14285// returned at all) in error.(*googleapi.Error).Header. Use
14286// googleapi.IsNotModified to check whether the returned error was
14287// because http.StatusNotModified was returned.
14288func (c *AccountActiveAdSummariesGetCall) Do(opts ...googleapi.CallOption) (*AccountActiveAdSummary, error) {
14289	gensupport.SetOptions(c.urlParams_, opts...)
14290	res, err := c.doRequest("json")
14291	if res != nil && res.StatusCode == http.StatusNotModified {
14292		if res.Body != nil {
14293			res.Body.Close()
14294		}
14295		return nil, &googleapi.Error{
14296			Code:   res.StatusCode,
14297			Header: res.Header,
14298		}
14299	}
14300	if err != nil {
14301		return nil, err
14302	}
14303	defer googleapi.CloseBody(res)
14304	if err := googleapi.CheckResponse(res); err != nil {
14305		return nil, err
14306	}
14307	ret := &AccountActiveAdSummary{
14308		ServerResponse: googleapi.ServerResponse{
14309			Header:         res.Header,
14310			HTTPStatusCode: res.StatusCode,
14311		},
14312	}
14313	target := &ret
14314	if err := gensupport.DecodeResponse(target, res); err != nil {
14315		return nil, err
14316	}
14317	return ret, nil
14318	// {
14319	//   "description": "Gets the account's active ad summary by account ID.",
14320	//   "httpMethod": "GET",
14321	//   "id": "dfareporting.accountActiveAdSummaries.get",
14322	//   "parameterOrder": [
14323	//     "profileId",
14324	//     "summaryAccountId"
14325	//   ],
14326	//   "parameters": {
14327	//     "profileId": {
14328	//       "description": "User profile ID associated with this request.",
14329	//       "format": "int64",
14330	//       "location": "path",
14331	//       "required": true,
14332	//       "type": "string"
14333	//     },
14334	//     "summaryAccountId": {
14335	//       "description": "Account ID.",
14336	//       "format": "int64",
14337	//       "location": "path",
14338	//       "required": true,
14339	//       "type": "string"
14340	//     }
14341	//   },
14342	//   "path": "userprofiles/{profileId}/accountActiveAdSummaries/{summaryAccountId}",
14343	//   "response": {
14344	//     "$ref": "AccountActiveAdSummary"
14345	//   },
14346	//   "scopes": [
14347	//     "https://www.googleapis.com/auth/dfatrafficking"
14348	//   ]
14349	// }
14350
14351}
14352
14353// method id "dfareporting.accountPermissionGroups.get":
14354
14355type AccountPermissionGroupsGetCall struct {
14356	s            *Service
14357	profileId    int64
14358	id           int64
14359	urlParams_   gensupport.URLParams
14360	ifNoneMatch_ string
14361	ctx_         context.Context
14362	header_      http.Header
14363}
14364
14365// Get: Gets one account permission group by ID.
14366func (r *AccountPermissionGroupsService) Get(profileId int64, id int64) *AccountPermissionGroupsGetCall {
14367	c := &AccountPermissionGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14368	c.profileId = profileId
14369	c.id = id
14370	return c
14371}
14372
14373// Fields allows partial responses to be retrieved. See
14374// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
14375// for more information.
14376func (c *AccountPermissionGroupsGetCall) Fields(s ...googleapi.Field) *AccountPermissionGroupsGetCall {
14377	c.urlParams_.Set("fields", googleapi.CombineFields(s))
14378	return c
14379}
14380
14381// IfNoneMatch sets the optional parameter which makes the operation
14382// fail if the object's ETag matches the given value. This is useful for
14383// getting updates only after the object has changed since the last
14384// request. Use googleapi.IsNotModified to check whether the response
14385// error from Do is the result of In-None-Match.
14386func (c *AccountPermissionGroupsGetCall) IfNoneMatch(entityTag string) *AccountPermissionGroupsGetCall {
14387	c.ifNoneMatch_ = entityTag
14388	return c
14389}
14390
14391// Context sets the context to be used in this call's Do method. Any
14392// pending HTTP request will be aborted if the provided context is
14393// canceled.
14394func (c *AccountPermissionGroupsGetCall) Context(ctx context.Context) *AccountPermissionGroupsGetCall {
14395	c.ctx_ = ctx
14396	return c
14397}
14398
14399// Header returns an http.Header that can be modified by the caller to
14400// add HTTP headers to the request.
14401func (c *AccountPermissionGroupsGetCall) Header() http.Header {
14402	if c.header_ == nil {
14403		c.header_ = make(http.Header)
14404	}
14405	return c.header_
14406}
14407
14408func (c *AccountPermissionGroupsGetCall) doRequest(alt string) (*http.Response, error) {
14409	reqHeaders := make(http.Header)
14410	for k, v := range c.header_ {
14411		reqHeaders[k] = v
14412	}
14413	reqHeaders.Set("User-Agent", c.s.userAgent())
14414	if c.ifNoneMatch_ != "" {
14415		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14416	}
14417	var body io.Reader = nil
14418	c.urlParams_.Set("alt", alt)
14419	c.urlParams_.Set("prettyPrint", "false")
14420	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissionGroups/{id}")
14421	urls += "?" + c.urlParams_.Encode()
14422	req, err := http.NewRequest("GET", urls, body)
14423	if err != nil {
14424		return nil, err
14425	}
14426	req.Header = reqHeaders
14427	googleapi.Expand(req.URL, map[string]string{
14428		"profileId": strconv.FormatInt(c.profileId, 10),
14429		"id":        strconv.FormatInt(c.id, 10),
14430	})
14431	return gensupport.SendRequest(c.ctx_, c.s.client, req)
14432}
14433
14434// Do executes the "dfareporting.accountPermissionGroups.get" call.
14435// Exactly one of *AccountPermissionGroup or error will be non-nil. Any
14436// non-2xx status code is an error. Response headers are in either
14437// *AccountPermissionGroup.ServerResponse.Header or (if a response was
14438// returned at all) in error.(*googleapi.Error).Header. Use
14439// googleapi.IsNotModified to check whether the returned error was
14440// because http.StatusNotModified was returned.
14441func (c *AccountPermissionGroupsGetCall) Do(opts ...googleapi.CallOption) (*AccountPermissionGroup, error) {
14442	gensupport.SetOptions(c.urlParams_, opts...)
14443	res, err := c.doRequest("json")
14444	if res != nil && res.StatusCode == http.StatusNotModified {
14445		if res.Body != nil {
14446			res.Body.Close()
14447		}
14448		return nil, &googleapi.Error{
14449			Code:   res.StatusCode,
14450			Header: res.Header,
14451		}
14452	}
14453	if err != nil {
14454		return nil, err
14455	}
14456	defer googleapi.CloseBody(res)
14457	if err := googleapi.CheckResponse(res); err != nil {
14458		return nil, err
14459	}
14460	ret := &AccountPermissionGroup{
14461		ServerResponse: googleapi.ServerResponse{
14462			Header:         res.Header,
14463			HTTPStatusCode: res.StatusCode,
14464		},
14465	}
14466	target := &ret
14467	if err := gensupport.DecodeResponse(target, res); err != nil {
14468		return nil, err
14469	}
14470	return ret, nil
14471	// {
14472	//   "description": "Gets one account permission group by ID.",
14473	//   "httpMethod": "GET",
14474	//   "id": "dfareporting.accountPermissionGroups.get",
14475	//   "parameterOrder": [
14476	//     "profileId",
14477	//     "id"
14478	//   ],
14479	//   "parameters": {
14480	//     "id": {
14481	//       "description": "Account permission group ID.",
14482	//       "format": "int64",
14483	//       "location": "path",
14484	//       "required": true,
14485	//       "type": "string"
14486	//     },
14487	//     "profileId": {
14488	//       "description": "User profile ID associated with this request.",
14489	//       "format": "int64",
14490	//       "location": "path",
14491	//       "required": true,
14492	//       "type": "string"
14493	//     }
14494	//   },
14495	//   "path": "userprofiles/{profileId}/accountPermissionGroups/{id}",
14496	//   "response": {
14497	//     "$ref": "AccountPermissionGroup"
14498	//   },
14499	//   "scopes": [
14500	//     "https://www.googleapis.com/auth/dfatrafficking"
14501	//   ]
14502	// }
14503
14504}
14505
14506// method id "dfareporting.accountPermissionGroups.list":
14507
14508type AccountPermissionGroupsListCall struct {
14509	s            *Service
14510	profileId    int64
14511	urlParams_   gensupport.URLParams
14512	ifNoneMatch_ string
14513	ctx_         context.Context
14514	header_      http.Header
14515}
14516
14517// List: Retrieves the list of account permission groups.
14518func (r *AccountPermissionGroupsService) List(profileId int64) *AccountPermissionGroupsListCall {
14519	c := &AccountPermissionGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14520	c.profileId = profileId
14521	return c
14522}
14523
14524// Fields allows partial responses to be retrieved. See
14525// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
14526// for more information.
14527func (c *AccountPermissionGroupsListCall) Fields(s ...googleapi.Field) *AccountPermissionGroupsListCall {
14528	c.urlParams_.Set("fields", googleapi.CombineFields(s))
14529	return c
14530}
14531
14532// IfNoneMatch sets the optional parameter which makes the operation
14533// fail if the object's ETag matches the given value. This is useful for
14534// getting updates only after the object has changed since the last
14535// request. Use googleapi.IsNotModified to check whether the response
14536// error from Do is the result of In-None-Match.
14537func (c *AccountPermissionGroupsListCall) IfNoneMatch(entityTag string) *AccountPermissionGroupsListCall {
14538	c.ifNoneMatch_ = entityTag
14539	return c
14540}
14541
14542// Context sets the context to be used in this call's Do method. Any
14543// pending HTTP request will be aborted if the provided context is
14544// canceled.
14545func (c *AccountPermissionGroupsListCall) Context(ctx context.Context) *AccountPermissionGroupsListCall {
14546	c.ctx_ = ctx
14547	return c
14548}
14549
14550// Header returns an http.Header that can be modified by the caller to
14551// add HTTP headers to the request.
14552func (c *AccountPermissionGroupsListCall) Header() http.Header {
14553	if c.header_ == nil {
14554		c.header_ = make(http.Header)
14555	}
14556	return c.header_
14557}
14558
14559func (c *AccountPermissionGroupsListCall) doRequest(alt string) (*http.Response, error) {
14560	reqHeaders := make(http.Header)
14561	for k, v := range c.header_ {
14562		reqHeaders[k] = v
14563	}
14564	reqHeaders.Set("User-Agent", c.s.userAgent())
14565	if c.ifNoneMatch_ != "" {
14566		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14567	}
14568	var body io.Reader = nil
14569	c.urlParams_.Set("alt", alt)
14570	c.urlParams_.Set("prettyPrint", "false")
14571	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissionGroups")
14572	urls += "?" + c.urlParams_.Encode()
14573	req, err := http.NewRequest("GET", urls, body)
14574	if err != nil {
14575		return nil, err
14576	}
14577	req.Header = reqHeaders
14578	googleapi.Expand(req.URL, map[string]string{
14579		"profileId": strconv.FormatInt(c.profileId, 10),
14580	})
14581	return gensupport.SendRequest(c.ctx_, c.s.client, req)
14582}
14583
14584// Do executes the "dfareporting.accountPermissionGroups.list" call.
14585// Exactly one of *AccountPermissionGroupsListResponse or error will be
14586// non-nil. Any non-2xx status code is an error. Response headers are in
14587// either *AccountPermissionGroupsListResponse.ServerResponse.Header or
14588// (if a response was returned at all) in
14589// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
14590// whether the returned error was because http.StatusNotModified was
14591// returned.
14592func (c *AccountPermissionGroupsListCall) Do(opts ...googleapi.CallOption) (*AccountPermissionGroupsListResponse, error) {
14593	gensupport.SetOptions(c.urlParams_, opts...)
14594	res, err := c.doRequest("json")
14595	if res != nil && res.StatusCode == http.StatusNotModified {
14596		if res.Body != nil {
14597			res.Body.Close()
14598		}
14599		return nil, &googleapi.Error{
14600			Code:   res.StatusCode,
14601			Header: res.Header,
14602		}
14603	}
14604	if err != nil {
14605		return nil, err
14606	}
14607	defer googleapi.CloseBody(res)
14608	if err := googleapi.CheckResponse(res); err != nil {
14609		return nil, err
14610	}
14611	ret := &AccountPermissionGroupsListResponse{
14612		ServerResponse: googleapi.ServerResponse{
14613			Header:         res.Header,
14614			HTTPStatusCode: res.StatusCode,
14615		},
14616	}
14617	target := &ret
14618	if err := gensupport.DecodeResponse(target, res); err != nil {
14619		return nil, err
14620	}
14621	return ret, nil
14622	// {
14623	//   "description": "Retrieves the list of account permission groups.",
14624	//   "httpMethod": "GET",
14625	//   "id": "dfareporting.accountPermissionGroups.list",
14626	//   "parameterOrder": [
14627	//     "profileId"
14628	//   ],
14629	//   "parameters": {
14630	//     "profileId": {
14631	//       "description": "User profile ID associated with this request.",
14632	//       "format": "int64",
14633	//       "location": "path",
14634	//       "required": true,
14635	//       "type": "string"
14636	//     }
14637	//   },
14638	//   "path": "userprofiles/{profileId}/accountPermissionGroups",
14639	//   "response": {
14640	//     "$ref": "AccountPermissionGroupsListResponse"
14641	//   },
14642	//   "scopes": [
14643	//     "https://www.googleapis.com/auth/dfatrafficking"
14644	//   ]
14645	// }
14646
14647}
14648
14649// method id "dfareporting.accountPermissions.get":
14650
14651type AccountPermissionsGetCall struct {
14652	s            *Service
14653	profileId    int64
14654	id           int64
14655	urlParams_   gensupport.URLParams
14656	ifNoneMatch_ string
14657	ctx_         context.Context
14658	header_      http.Header
14659}
14660
14661// Get: Gets one account permission by ID.
14662func (r *AccountPermissionsService) Get(profileId int64, id int64) *AccountPermissionsGetCall {
14663	c := &AccountPermissionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14664	c.profileId = profileId
14665	c.id = id
14666	return c
14667}
14668
14669// Fields allows partial responses to be retrieved. See
14670// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
14671// for more information.
14672func (c *AccountPermissionsGetCall) Fields(s ...googleapi.Field) *AccountPermissionsGetCall {
14673	c.urlParams_.Set("fields", googleapi.CombineFields(s))
14674	return c
14675}
14676
14677// IfNoneMatch sets the optional parameter which makes the operation
14678// fail if the object's ETag matches the given value. This is useful for
14679// getting updates only after the object has changed since the last
14680// request. Use googleapi.IsNotModified to check whether the response
14681// error from Do is the result of In-None-Match.
14682func (c *AccountPermissionsGetCall) IfNoneMatch(entityTag string) *AccountPermissionsGetCall {
14683	c.ifNoneMatch_ = entityTag
14684	return c
14685}
14686
14687// Context sets the context to be used in this call's Do method. Any
14688// pending HTTP request will be aborted if the provided context is
14689// canceled.
14690func (c *AccountPermissionsGetCall) Context(ctx context.Context) *AccountPermissionsGetCall {
14691	c.ctx_ = ctx
14692	return c
14693}
14694
14695// Header returns an http.Header that can be modified by the caller to
14696// add HTTP headers to the request.
14697func (c *AccountPermissionsGetCall) Header() http.Header {
14698	if c.header_ == nil {
14699		c.header_ = make(http.Header)
14700	}
14701	return c.header_
14702}
14703
14704func (c *AccountPermissionsGetCall) doRequest(alt string) (*http.Response, error) {
14705	reqHeaders := make(http.Header)
14706	for k, v := range c.header_ {
14707		reqHeaders[k] = v
14708	}
14709	reqHeaders.Set("User-Agent", c.s.userAgent())
14710	if c.ifNoneMatch_ != "" {
14711		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14712	}
14713	var body io.Reader = nil
14714	c.urlParams_.Set("alt", alt)
14715	c.urlParams_.Set("prettyPrint", "false")
14716	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissions/{id}")
14717	urls += "?" + c.urlParams_.Encode()
14718	req, err := http.NewRequest("GET", urls, body)
14719	if err != nil {
14720		return nil, err
14721	}
14722	req.Header = reqHeaders
14723	googleapi.Expand(req.URL, map[string]string{
14724		"profileId": strconv.FormatInt(c.profileId, 10),
14725		"id":        strconv.FormatInt(c.id, 10),
14726	})
14727	return gensupport.SendRequest(c.ctx_, c.s.client, req)
14728}
14729
14730// Do executes the "dfareporting.accountPermissions.get" call.
14731// Exactly one of *AccountPermission or error will be non-nil. Any
14732// non-2xx status code is an error. Response headers are in either
14733// *AccountPermission.ServerResponse.Header or (if a response was
14734// returned at all) in error.(*googleapi.Error).Header. Use
14735// googleapi.IsNotModified to check whether the returned error was
14736// because http.StatusNotModified was returned.
14737func (c *AccountPermissionsGetCall) Do(opts ...googleapi.CallOption) (*AccountPermission, error) {
14738	gensupport.SetOptions(c.urlParams_, opts...)
14739	res, err := c.doRequest("json")
14740	if res != nil && res.StatusCode == http.StatusNotModified {
14741		if res.Body != nil {
14742			res.Body.Close()
14743		}
14744		return nil, &googleapi.Error{
14745			Code:   res.StatusCode,
14746			Header: res.Header,
14747		}
14748	}
14749	if err != nil {
14750		return nil, err
14751	}
14752	defer googleapi.CloseBody(res)
14753	if err := googleapi.CheckResponse(res); err != nil {
14754		return nil, err
14755	}
14756	ret := &AccountPermission{
14757		ServerResponse: googleapi.ServerResponse{
14758			Header:         res.Header,
14759			HTTPStatusCode: res.StatusCode,
14760		},
14761	}
14762	target := &ret
14763	if err := gensupport.DecodeResponse(target, res); err != nil {
14764		return nil, err
14765	}
14766	return ret, nil
14767	// {
14768	//   "description": "Gets one account permission by ID.",
14769	//   "httpMethod": "GET",
14770	//   "id": "dfareporting.accountPermissions.get",
14771	//   "parameterOrder": [
14772	//     "profileId",
14773	//     "id"
14774	//   ],
14775	//   "parameters": {
14776	//     "id": {
14777	//       "description": "Account permission ID.",
14778	//       "format": "int64",
14779	//       "location": "path",
14780	//       "required": true,
14781	//       "type": "string"
14782	//     },
14783	//     "profileId": {
14784	//       "description": "User profile ID associated with this request.",
14785	//       "format": "int64",
14786	//       "location": "path",
14787	//       "required": true,
14788	//       "type": "string"
14789	//     }
14790	//   },
14791	//   "path": "userprofiles/{profileId}/accountPermissions/{id}",
14792	//   "response": {
14793	//     "$ref": "AccountPermission"
14794	//   },
14795	//   "scopes": [
14796	//     "https://www.googleapis.com/auth/dfatrafficking"
14797	//   ]
14798	// }
14799
14800}
14801
14802// method id "dfareporting.accountPermissions.list":
14803
14804type AccountPermissionsListCall struct {
14805	s            *Service
14806	profileId    int64
14807	urlParams_   gensupport.URLParams
14808	ifNoneMatch_ string
14809	ctx_         context.Context
14810	header_      http.Header
14811}
14812
14813// List: Retrieves the list of account permissions.
14814func (r *AccountPermissionsService) List(profileId int64) *AccountPermissionsListCall {
14815	c := &AccountPermissionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14816	c.profileId = profileId
14817	return c
14818}
14819
14820// Fields allows partial responses to be retrieved. See
14821// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
14822// for more information.
14823func (c *AccountPermissionsListCall) Fields(s ...googleapi.Field) *AccountPermissionsListCall {
14824	c.urlParams_.Set("fields", googleapi.CombineFields(s))
14825	return c
14826}
14827
14828// IfNoneMatch sets the optional parameter which makes the operation
14829// fail if the object's ETag matches the given value. This is useful for
14830// getting updates only after the object has changed since the last
14831// request. Use googleapi.IsNotModified to check whether the response
14832// error from Do is the result of In-None-Match.
14833func (c *AccountPermissionsListCall) IfNoneMatch(entityTag string) *AccountPermissionsListCall {
14834	c.ifNoneMatch_ = entityTag
14835	return c
14836}
14837
14838// Context sets the context to be used in this call's Do method. Any
14839// pending HTTP request will be aborted if the provided context is
14840// canceled.
14841func (c *AccountPermissionsListCall) Context(ctx context.Context) *AccountPermissionsListCall {
14842	c.ctx_ = ctx
14843	return c
14844}
14845
14846// Header returns an http.Header that can be modified by the caller to
14847// add HTTP headers to the request.
14848func (c *AccountPermissionsListCall) Header() http.Header {
14849	if c.header_ == nil {
14850		c.header_ = make(http.Header)
14851	}
14852	return c.header_
14853}
14854
14855func (c *AccountPermissionsListCall) doRequest(alt string) (*http.Response, error) {
14856	reqHeaders := make(http.Header)
14857	for k, v := range c.header_ {
14858		reqHeaders[k] = v
14859	}
14860	reqHeaders.Set("User-Agent", c.s.userAgent())
14861	if c.ifNoneMatch_ != "" {
14862		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14863	}
14864	var body io.Reader = nil
14865	c.urlParams_.Set("alt", alt)
14866	c.urlParams_.Set("prettyPrint", "false")
14867	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissions")
14868	urls += "?" + c.urlParams_.Encode()
14869	req, err := http.NewRequest("GET", urls, body)
14870	if err != nil {
14871		return nil, err
14872	}
14873	req.Header = reqHeaders
14874	googleapi.Expand(req.URL, map[string]string{
14875		"profileId": strconv.FormatInt(c.profileId, 10),
14876	})
14877	return gensupport.SendRequest(c.ctx_, c.s.client, req)
14878}
14879
14880// Do executes the "dfareporting.accountPermissions.list" call.
14881// Exactly one of *AccountPermissionsListResponse or error will be
14882// non-nil. Any non-2xx status code is an error. Response headers are in
14883// either *AccountPermissionsListResponse.ServerResponse.Header or (if a
14884// response was returned at all) in error.(*googleapi.Error).Header. Use
14885// googleapi.IsNotModified to check whether the returned error was
14886// because http.StatusNotModified was returned.
14887func (c *AccountPermissionsListCall) Do(opts ...googleapi.CallOption) (*AccountPermissionsListResponse, error) {
14888	gensupport.SetOptions(c.urlParams_, opts...)
14889	res, err := c.doRequest("json")
14890	if res != nil && res.StatusCode == http.StatusNotModified {
14891		if res.Body != nil {
14892			res.Body.Close()
14893		}
14894		return nil, &googleapi.Error{
14895			Code:   res.StatusCode,
14896			Header: res.Header,
14897		}
14898	}
14899	if err != nil {
14900		return nil, err
14901	}
14902	defer googleapi.CloseBody(res)
14903	if err := googleapi.CheckResponse(res); err != nil {
14904		return nil, err
14905	}
14906	ret := &AccountPermissionsListResponse{
14907		ServerResponse: googleapi.ServerResponse{
14908			Header:         res.Header,
14909			HTTPStatusCode: res.StatusCode,
14910		},
14911	}
14912	target := &ret
14913	if err := gensupport.DecodeResponse(target, res); err != nil {
14914		return nil, err
14915	}
14916	return ret, nil
14917	// {
14918	//   "description": "Retrieves the list of account permissions.",
14919	//   "httpMethod": "GET",
14920	//   "id": "dfareporting.accountPermissions.list",
14921	//   "parameterOrder": [
14922	//     "profileId"
14923	//   ],
14924	//   "parameters": {
14925	//     "profileId": {
14926	//       "description": "User profile ID associated with this request.",
14927	//       "format": "int64",
14928	//       "location": "path",
14929	//       "required": true,
14930	//       "type": "string"
14931	//     }
14932	//   },
14933	//   "path": "userprofiles/{profileId}/accountPermissions",
14934	//   "response": {
14935	//     "$ref": "AccountPermissionsListResponse"
14936	//   },
14937	//   "scopes": [
14938	//     "https://www.googleapis.com/auth/dfatrafficking"
14939	//   ]
14940	// }
14941
14942}
14943
14944// method id "dfareporting.accountUserProfiles.get":
14945
14946type AccountUserProfilesGetCall struct {
14947	s            *Service
14948	profileId    int64
14949	id           int64
14950	urlParams_   gensupport.URLParams
14951	ifNoneMatch_ string
14952	ctx_         context.Context
14953	header_      http.Header
14954}
14955
14956// Get: Gets one account user profile by ID.
14957func (r *AccountUserProfilesService) Get(profileId int64, id int64) *AccountUserProfilesGetCall {
14958	c := &AccountUserProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14959	c.profileId = profileId
14960	c.id = id
14961	return c
14962}
14963
14964// Fields allows partial responses to be retrieved. See
14965// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
14966// for more information.
14967func (c *AccountUserProfilesGetCall) Fields(s ...googleapi.Field) *AccountUserProfilesGetCall {
14968	c.urlParams_.Set("fields", googleapi.CombineFields(s))
14969	return c
14970}
14971
14972// IfNoneMatch sets the optional parameter which makes the operation
14973// fail if the object's ETag matches the given value. This is useful for
14974// getting updates only after the object has changed since the last
14975// request. Use googleapi.IsNotModified to check whether the response
14976// error from Do is the result of In-None-Match.
14977func (c *AccountUserProfilesGetCall) IfNoneMatch(entityTag string) *AccountUserProfilesGetCall {
14978	c.ifNoneMatch_ = entityTag
14979	return c
14980}
14981
14982// Context sets the context to be used in this call's Do method. Any
14983// pending HTTP request will be aborted if the provided context is
14984// canceled.
14985func (c *AccountUserProfilesGetCall) Context(ctx context.Context) *AccountUserProfilesGetCall {
14986	c.ctx_ = ctx
14987	return c
14988}
14989
14990// Header returns an http.Header that can be modified by the caller to
14991// add HTTP headers to the request.
14992func (c *AccountUserProfilesGetCall) Header() http.Header {
14993	if c.header_ == nil {
14994		c.header_ = make(http.Header)
14995	}
14996	return c.header_
14997}
14998
14999func (c *AccountUserProfilesGetCall) doRequest(alt string) (*http.Response, error) {
15000	reqHeaders := make(http.Header)
15001	for k, v := range c.header_ {
15002		reqHeaders[k] = v
15003	}
15004	reqHeaders.Set("User-Agent", c.s.userAgent())
15005	if c.ifNoneMatch_ != "" {
15006		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15007	}
15008	var body io.Reader = nil
15009	c.urlParams_.Set("alt", alt)
15010	c.urlParams_.Set("prettyPrint", "false")
15011	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles/{id}")
15012	urls += "?" + c.urlParams_.Encode()
15013	req, err := http.NewRequest("GET", urls, body)
15014	if err != nil {
15015		return nil, err
15016	}
15017	req.Header = reqHeaders
15018	googleapi.Expand(req.URL, map[string]string{
15019		"profileId": strconv.FormatInt(c.profileId, 10),
15020		"id":        strconv.FormatInt(c.id, 10),
15021	})
15022	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15023}
15024
15025// Do executes the "dfareporting.accountUserProfiles.get" call.
15026// Exactly one of *AccountUserProfile or error will be non-nil. Any
15027// non-2xx status code is an error. Response headers are in either
15028// *AccountUserProfile.ServerResponse.Header or (if a response was
15029// returned at all) in error.(*googleapi.Error).Header. Use
15030// googleapi.IsNotModified to check whether the returned error was
15031// because http.StatusNotModified was returned.
15032func (c *AccountUserProfilesGetCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15033	gensupport.SetOptions(c.urlParams_, opts...)
15034	res, err := c.doRequest("json")
15035	if res != nil && res.StatusCode == http.StatusNotModified {
15036		if res.Body != nil {
15037			res.Body.Close()
15038		}
15039		return nil, &googleapi.Error{
15040			Code:   res.StatusCode,
15041			Header: res.Header,
15042		}
15043	}
15044	if err != nil {
15045		return nil, err
15046	}
15047	defer googleapi.CloseBody(res)
15048	if err := googleapi.CheckResponse(res); err != nil {
15049		return nil, err
15050	}
15051	ret := &AccountUserProfile{
15052		ServerResponse: googleapi.ServerResponse{
15053			Header:         res.Header,
15054			HTTPStatusCode: res.StatusCode,
15055		},
15056	}
15057	target := &ret
15058	if err := gensupport.DecodeResponse(target, res); err != nil {
15059		return nil, err
15060	}
15061	return ret, nil
15062	// {
15063	//   "description": "Gets one account user profile by ID.",
15064	//   "httpMethod": "GET",
15065	//   "id": "dfareporting.accountUserProfiles.get",
15066	//   "parameterOrder": [
15067	//     "profileId",
15068	//     "id"
15069	//   ],
15070	//   "parameters": {
15071	//     "id": {
15072	//       "description": "User profile ID.",
15073	//       "format": "int64",
15074	//       "location": "path",
15075	//       "required": true,
15076	//       "type": "string"
15077	//     },
15078	//     "profileId": {
15079	//       "description": "User profile ID associated with this request.",
15080	//       "format": "int64",
15081	//       "location": "path",
15082	//       "required": true,
15083	//       "type": "string"
15084	//     }
15085	//   },
15086	//   "path": "userprofiles/{profileId}/accountUserProfiles/{id}",
15087	//   "response": {
15088	//     "$ref": "AccountUserProfile"
15089	//   },
15090	//   "scopes": [
15091	//     "https://www.googleapis.com/auth/dfatrafficking"
15092	//   ]
15093	// }
15094
15095}
15096
15097// method id "dfareporting.accountUserProfiles.insert":
15098
15099type AccountUserProfilesInsertCall struct {
15100	s                  *Service
15101	profileId          int64
15102	accountuserprofile *AccountUserProfile
15103	urlParams_         gensupport.URLParams
15104	ctx_               context.Context
15105	header_            http.Header
15106}
15107
15108// Insert: Inserts a new account user profile.
15109func (r *AccountUserProfilesService) Insert(profileId int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesInsertCall {
15110	c := &AccountUserProfilesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15111	c.profileId = profileId
15112	c.accountuserprofile = accountuserprofile
15113	return c
15114}
15115
15116// Fields allows partial responses to be retrieved. See
15117// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15118// for more information.
15119func (c *AccountUserProfilesInsertCall) Fields(s ...googleapi.Field) *AccountUserProfilesInsertCall {
15120	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15121	return c
15122}
15123
15124// Context sets the context to be used in this call's Do method. Any
15125// pending HTTP request will be aborted if the provided context is
15126// canceled.
15127func (c *AccountUserProfilesInsertCall) Context(ctx context.Context) *AccountUserProfilesInsertCall {
15128	c.ctx_ = ctx
15129	return c
15130}
15131
15132// Header returns an http.Header that can be modified by the caller to
15133// add HTTP headers to the request.
15134func (c *AccountUserProfilesInsertCall) Header() http.Header {
15135	if c.header_ == nil {
15136		c.header_ = make(http.Header)
15137	}
15138	return c.header_
15139}
15140
15141func (c *AccountUserProfilesInsertCall) doRequest(alt string) (*http.Response, error) {
15142	reqHeaders := make(http.Header)
15143	for k, v := range c.header_ {
15144		reqHeaders[k] = v
15145	}
15146	reqHeaders.Set("User-Agent", c.s.userAgent())
15147	var body io.Reader = nil
15148	body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
15149	if err != nil {
15150		return nil, err
15151	}
15152	reqHeaders.Set("Content-Type", "application/json")
15153	c.urlParams_.Set("alt", alt)
15154	c.urlParams_.Set("prettyPrint", "false")
15155	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15156	urls += "?" + c.urlParams_.Encode()
15157	req, err := http.NewRequest("POST", urls, body)
15158	if err != nil {
15159		return nil, err
15160	}
15161	req.Header = reqHeaders
15162	googleapi.Expand(req.URL, map[string]string{
15163		"profileId": strconv.FormatInt(c.profileId, 10),
15164	})
15165	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15166}
15167
15168// Do executes the "dfareporting.accountUserProfiles.insert" call.
15169// Exactly one of *AccountUserProfile or error will be non-nil. Any
15170// non-2xx status code is an error. Response headers are in either
15171// *AccountUserProfile.ServerResponse.Header or (if a response was
15172// returned at all) in error.(*googleapi.Error).Header. Use
15173// googleapi.IsNotModified to check whether the returned error was
15174// because http.StatusNotModified was returned.
15175func (c *AccountUserProfilesInsertCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15176	gensupport.SetOptions(c.urlParams_, opts...)
15177	res, err := c.doRequest("json")
15178	if res != nil && res.StatusCode == http.StatusNotModified {
15179		if res.Body != nil {
15180			res.Body.Close()
15181		}
15182		return nil, &googleapi.Error{
15183			Code:   res.StatusCode,
15184			Header: res.Header,
15185		}
15186	}
15187	if err != nil {
15188		return nil, err
15189	}
15190	defer googleapi.CloseBody(res)
15191	if err := googleapi.CheckResponse(res); err != nil {
15192		return nil, err
15193	}
15194	ret := &AccountUserProfile{
15195		ServerResponse: googleapi.ServerResponse{
15196			Header:         res.Header,
15197			HTTPStatusCode: res.StatusCode,
15198		},
15199	}
15200	target := &ret
15201	if err := gensupport.DecodeResponse(target, res); err != nil {
15202		return nil, err
15203	}
15204	return ret, nil
15205	// {
15206	//   "description": "Inserts a new account user profile.",
15207	//   "httpMethod": "POST",
15208	//   "id": "dfareporting.accountUserProfiles.insert",
15209	//   "parameterOrder": [
15210	//     "profileId"
15211	//   ],
15212	//   "parameters": {
15213	//     "profileId": {
15214	//       "description": "User profile ID associated with this request.",
15215	//       "format": "int64",
15216	//       "location": "path",
15217	//       "required": true,
15218	//       "type": "string"
15219	//     }
15220	//   },
15221	//   "path": "userprofiles/{profileId}/accountUserProfiles",
15222	//   "request": {
15223	//     "$ref": "AccountUserProfile"
15224	//   },
15225	//   "response": {
15226	//     "$ref": "AccountUserProfile"
15227	//   },
15228	//   "scopes": [
15229	//     "https://www.googleapis.com/auth/dfatrafficking"
15230	//   ]
15231	// }
15232
15233}
15234
15235// method id "dfareporting.accountUserProfiles.list":
15236
15237type AccountUserProfilesListCall struct {
15238	s            *Service
15239	profileId    int64
15240	urlParams_   gensupport.URLParams
15241	ifNoneMatch_ string
15242	ctx_         context.Context
15243	header_      http.Header
15244}
15245
15246// List: Retrieves a list of account user profiles, possibly filtered.
15247// This method supports paging.
15248func (r *AccountUserProfilesService) List(profileId int64) *AccountUserProfilesListCall {
15249	c := &AccountUserProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15250	c.profileId = profileId
15251	return c
15252}
15253
15254// Active sets the optional parameter "active": Select only active user
15255// profiles.
15256func (c *AccountUserProfilesListCall) Active(active bool) *AccountUserProfilesListCall {
15257	c.urlParams_.Set("active", fmt.Sprint(active))
15258	return c
15259}
15260
15261// Ids sets the optional parameter "ids": Select only user profiles with
15262// these IDs.
15263func (c *AccountUserProfilesListCall) Ids(ids ...int64) *AccountUserProfilesListCall {
15264	var ids_ []string
15265	for _, v := range ids {
15266		ids_ = append(ids_, fmt.Sprint(v))
15267	}
15268	c.urlParams_.SetMulti("ids", ids_)
15269	return c
15270}
15271
15272// MaxResults sets the optional parameter "maxResults": Maximum number
15273// of results to return.
15274func (c *AccountUserProfilesListCall) MaxResults(maxResults int64) *AccountUserProfilesListCall {
15275	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
15276	return c
15277}
15278
15279// PageToken sets the optional parameter "pageToken": Value of the
15280// nextPageToken from the previous result page.
15281func (c *AccountUserProfilesListCall) PageToken(pageToken string) *AccountUserProfilesListCall {
15282	c.urlParams_.Set("pageToken", pageToken)
15283	return c
15284}
15285
15286// SearchString sets the optional parameter "searchString": Allows
15287// searching for objects by name, ID or email. Wildcards (*) are
15288// allowed. For example, "user profile*2015" will return objects with
15289// names like "user profile June 2015", "user profile April 2015", or
15290// simply "user profile 2015". Most of the searches also add wildcards
15291// implicitly at the start and the end of the search string. For
15292// example, a search string of "user profile" will match objects with
15293// name "my user profile", "user profile 2015", or simply "user
15294// profile".
15295func (c *AccountUserProfilesListCall) SearchString(searchString string) *AccountUserProfilesListCall {
15296	c.urlParams_.Set("searchString", searchString)
15297	return c
15298}
15299
15300// SortField sets the optional parameter "sortField": Field by which to
15301// sort the list.
15302//
15303// Possible values:
15304//   "ID" (default)
15305//   "NAME"
15306func (c *AccountUserProfilesListCall) SortField(sortField string) *AccountUserProfilesListCall {
15307	c.urlParams_.Set("sortField", sortField)
15308	return c
15309}
15310
15311// SortOrder sets the optional parameter "sortOrder": Order of sorted
15312// results.
15313//
15314// Possible values:
15315//   "ASCENDING" (default)
15316//   "DESCENDING"
15317func (c *AccountUserProfilesListCall) SortOrder(sortOrder string) *AccountUserProfilesListCall {
15318	c.urlParams_.Set("sortOrder", sortOrder)
15319	return c
15320}
15321
15322// SubaccountId sets the optional parameter "subaccountId": Select only
15323// user profiles with the specified subaccount ID.
15324func (c *AccountUserProfilesListCall) SubaccountId(subaccountId int64) *AccountUserProfilesListCall {
15325	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
15326	return c
15327}
15328
15329// UserRoleId sets the optional parameter "userRoleId": Select only user
15330// profiles with the specified user role ID.
15331func (c *AccountUserProfilesListCall) UserRoleId(userRoleId int64) *AccountUserProfilesListCall {
15332	c.urlParams_.Set("userRoleId", fmt.Sprint(userRoleId))
15333	return c
15334}
15335
15336// Fields allows partial responses to be retrieved. See
15337// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15338// for more information.
15339func (c *AccountUserProfilesListCall) Fields(s ...googleapi.Field) *AccountUserProfilesListCall {
15340	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15341	return c
15342}
15343
15344// IfNoneMatch sets the optional parameter which makes the operation
15345// fail if the object's ETag matches the given value. This is useful for
15346// getting updates only after the object has changed since the last
15347// request. Use googleapi.IsNotModified to check whether the response
15348// error from Do is the result of In-None-Match.
15349func (c *AccountUserProfilesListCall) IfNoneMatch(entityTag string) *AccountUserProfilesListCall {
15350	c.ifNoneMatch_ = entityTag
15351	return c
15352}
15353
15354// Context sets the context to be used in this call's Do method. Any
15355// pending HTTP request will be aborted if the provided context is
15356// canceled.
15357func (c *AccountUserProfilesListCall) Context(ctx context.Context) *AccountUserProfilesListCall {
15358	c.ctx_ = ctx
15359	return c
15360}
15361
15362// Header returns an http.Header that can be modified by the caller to
15363// add HTTP headers to the request.
15364func (c *AccountUserProfilesListCall) Header() http.Header {
15365	if c.header_ == nil {
15366		c.header_ = make(http.Header)
15367	}
15368	return c.header_
15369}
15370
15371func (c *AccountUserProfilesListCall) doRequest(alt string) (*http.Response, error) {
15372	reqHeaders := make(http.Header)
15373	for k, v := range c.header_ {
15374		reqHeaders[k] = v
15375	}
15376	reqHeaders.Set("User-Agent", c.s.userAgent())
15377	if c.ifNoneMatch_ != "" {
15378		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15379	}
15380	var body io.Reader = nil
15381	c.urlParams_.Set("alt", alt)
15382	c.urlParams_.Set("prettyPrint", "false")
15383	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15384	urls += "?" + c.urlParams_.Encode()
15385	req, err := http.NewRequest("GET", urls, body)
15386	if err != nil {
15387		return nil, err
15388	}
15389	req.Header = reqHeaders
15390	googleapi.Expand(req.URL, map[string]string{
15391		"profileId": strconv.FormatInt(c.profileId, 10),
15392	})
15393	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15394}
15395
15396// Do executes the "dfareporting.accountUserProfiles.list" call.
15397// Exactly one of *AccountUserProfilesListResponse or error will be
15398// non-nil. Any non-2xx status code is an error. Response headers are in
15399// either *AccountUserProfilesListResponse.ServerResponse.Header or (if
15400// a response was returned at all) in error.(*googleapi.Error).Header.
15401// Use googleapi.IsNotModified to check whether the returned error was
15402// because http.StatusNotModified was returned.
15403func (c *AccountUserProfilesListCall) Do(opts ...googleapi.CallOption) (*AccountUserProfilesListResponse, error) {
15404	gensupport.SetOptions(c.urlParams_, opts...)
15405	res, err := c.doRequest("json")
15406	if res != nil && res.StatusCode == http.StatusNotModified {
15407		if res.Body != nil {
15408			res.Body.Close()
15409		}
15410		return nil, &googleapi.Error{
15411			Code:   res.StatusCode,
15412			Header: res.Header,
15413		}
15414	}
15415	if err != nil {
15416		return nil, err
15417	}
15418	defer googleapi.CloseBody(res)
15419	if err := googleapi.CheckResponse(res); err != nil {
15420		return nil, err
15421	}
15422	ret := &AccountUserProfilesListResponse{
15423		ServerResponse: googleapi.ServerResponse{
15424			Header:         res.Header,
15425			HTTPStatusCode: res.StatusCode,
15426		},
15427	}
15428	target := &ret
15429	if err := gensupport.DecodeResponse(target, res); err != nil {
15430		return nil, err
15431	}
15432	return ret, nil
15433	// {
15434	//   "description": "Retrieves a list of account user profiles, possibly filtered. This method supports paging.",
15435	//   "httpMethod": "GET",
15436	//   "id": "dfareporting.accountUserProfiles.list",
15437	//   "parameterOrder": [
15438	//     "profileId"
15439	//   ],
15440	//   "parameters": {
15441	//     "active": {
15442	//       "description": "Select only active user profiles.",
15443	//       "location": "query",
15444	//       "type": "boolean"
15445	//     },
15446	//     "ids": {
15447	//       "description": "Select only user profiles with these IDs.",
15448	//       "format": "int64",
15449	//       "location": "query",
15450	//       "repeated": true,
15451	//       "type": "string"
15452	//     },
15453	//     "maxResults": {
15454	//       "default": "1000",
15455	//       "description": "Maximum number of results to return.",
15456	//       "format": "int32",
15457	//       "location": "query",
15458	//       "maximum": "1000",
15459	//       "minimum": "0",
15460	//       "type": "integer"
15461	//     },
15462	//     "pageToken": {
15463	//       "description": "Value of the nextPageToken from the previous result page.",
15464	//       "location": "query",
15465	//       "type": "string"
15466	//     },
15467	//     "profileId": {
15468	//       "description": "User profile ID associated with this request.",
15469	//       "format": "int64",
15470	//       "location": "path",
15471	//       "required": true,
15472	//       "type": "string"
15473	//     },
15474	//     "searchString": {
15475	//       "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\".",
15476	//       "location": "query",
15477	//       "type": "string"
15478	//     },
15479	//     "sortField": {
15480	//       "default": "ID",
15481	//       "description": "Field by which to sort the list.",
15482	//       "enum": [
15483	//         "ID",
15484	//         "NAME"
15485	//       ],
15486	//       "enumDescriptions": [
15487	//         "",
15488	//         ""
15489	//       ],
15490	//       "location": "query",
15491	//       "type": "string"
15492	//     },
15493	//     "sortOrder": {
15494	//       "default": "ASCENDING",
15495	//       "description": "Order of sorted results.",
15496	//       "enum": [
15497	//         "ASCENDING",
15498	//         "DESCENDING"
15499	//       ],
15500	//       "enumDescriptions": [
15501	//         "",
15502	//         ""
15503	//       ],
15504	//       "location": "query",
15505	//       "type": "string"
15506	//     },
15507	//     "subaccountId": {
15508	//       "description": "Select only user profiles with the specified subaccount ID.",
15509	//       "format": "int64",
15510	//       "location": "query",
15511	//       "type": "string"
15512	//     },
15513	//     "userRoleId": {
15514	//       "description": "Select only user profiles with the specified user role ID.",
15515	//       "format": "int64",
15516	//       "location": "query",
15517	//       "type": "string"
15518	//     }
15519	//   },
15520	//   "path": "userprofiles/{profileId}/accountUserProfiles",
15521	//   "response": {
15522	//     "$ref": "AccountUserProfilesListResponse"
15523	//   },
15524	//   "scopes": [
15525	//     "https://www.googleapis.com/auth/dfatrafficking"
15526	//   ]
15527	// }
15528
15529}
15530
15531// Pages invokes f for each page of results.
15532// A non-nil error returned from f will halt the iteration.
15533// The provided context supersedes any context provided to the Context method.
15534func (c *AccountUserProfilesListCall) Pages(ctx context.Context, f func(*AccountUserProfilesListResponse) error) error {
15535	c.ctx_ = ctx
15536	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
15537	for {
15538		x, err := c.Do()
15539		if err != nil {
15540			return err
15541		}
15542		if err := f(x); err != nil {
15543			return err
15544		}
15545		if x.NextPageToken == "" {
15546			return nil
15547		}
15548		c.PageToken(x.NextPageToken)
15549	}
15550}
15551
15552// method id "dfareporting.accountUserProfiles.patch":
15553
15554type AccountUserProfilesPatchCall struct {
15555	s                  *Service
15556	profileId          int64
15557	accountuserprofile *AccountUserProfile
15558	urlParams_         gensupport.URLParams
15559	ctx_               context.Context
15560	header_            http.Header
15561}
15562
15563// Patch: Updates an existing account user profile. This method supports
15564// patch semantics.
15565func (r *AccountUserProfilesService) Patch(profileId int64, id int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesPatchCall {
15566	c := &AccountUserProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15567	c.profileId = profileId
15568	c.urlParams_.Set("id", fmt.Sprint(id))
15569	c.accountuserprofile = accountuserprofile
15570	return c
15571}
15572
15573// Fields allows partial responses to be retrieved. See
15574// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15575// for more information.
15576func (c *AccountUserProfilesPatchCall) Fields(s ...googleapi.Field) *AccountUserProfilesPatchCall {
15577	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15578	return c
15579}
15580
15581// Context sets the context to be used in this call's Do method. Any
15582// pending HTTP request will be aborted if the provided context is
15583// canceled.
15584func (c *AccountUserProfilesPatchCall) Context(ctx context.Context) *AccountUserProfilesPatchCall {
15585	c.ctx_ = ctx
15586	return c
15587}
15588
15589// Header returns an http.Header that can be modified by the caller to
15590// add HTTP headers to the request.
15591func (c *AccountUserProfilesPatchCall) Header() http.Header {
15592	if c.header_ == nil {
15593		c.header_ = make(http.Header)
15594	}
15595	return c.header_
15596}
15597
15598func (c *AccountUserProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
15599	reqHeaders := make(http.Header)
15600	for k, v := range c.header_ {
15601		reqHeaders[k] = v
15602	}
15603	reqHeaders.Set("User-Agent", c.s.userAgent())
15604	var body io.Reader = nil
15605	body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
15606	if err != nil {
15607		return nil, err
15608	}
15609	reqHeaders.Set("Content-Type", "application/json")
15610	c.urlParams_.Set("alt", alt)
15611	c.urlParams_.Set("prettyPrint", "false")
15612	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15613	urls += "?" + c.urlParams_.Encode()
15614	req, err := http.NewRequest("PATCH", urls, body)
15615	if err != nil {
15616		return nil, err
15617	}
15618	req.Header = reqHeaders
15619	googleapi.Expand(req.URL, map[string]string{
15620		"profileId": strconv.FormatInt(c.profileId, 10),
15621	})
15622	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15623}
15624
15625// Do executes the "dfareporting.accountUserProfiles.patch" call.
15626// Exactly one of *AccountUserProfile or error will be non-nil. Any
15627// non-2xx status code is an error. Response headers are in either
15628// *AccountUserProfile.ServerResponse.Header or (if a response was
15629// returned at all) in error.(*googleapi.Error).Header. Use
15630// googleapi.IsNotModified to check whether the returned error was
15631// because http.StatusNotModified was returned.
15632func (c *AccountUserProfilesPatchCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15633	gensupport.SetOptions(c.urlParams_, opts...)
15634	res, err := c.doRequest("json")
15635	if res != nil && res.StatusCode == http.StatusNotModified {
15636		if res.Body != nil {
15637			res.Body.Close()
15638		}
15639		return nil, &googleapi.Error{
15640			Code:   res.StatusCode,
15641			Header: res.Header,
15642		}
15643	}
15644	if err != nil {
15645		return nil, err
15646	}
15647	defer googleapi.CloseBody(res)
15648	if err := googleapi.CheckResponse(res); err != nil {
15649		return nil, err
15650	}
15651	ret := &AccountUserProfile{
15652		ServerResponse: googleapi.ServerResponse{
15653			Header:         res.Header,
15654			HTTPStatusCode: res.StatusCode,
15655		},
15656	}
15657	target := &ret
15658	if err := gensupport.DecodeResponse(target, res); err != nil {
15659		return nil, err
15660	}
15661	return ret, nil
15662	// {
15663	//   "description": "Updates an existing account user profile. This method supports patch semantics.",
15664	//   "httpMethod": "PATCH",
15665	//   "id": "dfareporting.accountUserProfiles.patch",
15666	//   "parameterOrder": [
15667	//     "profileId",
15668	//     "id"
15669	//   ],
15670	//   "parameters": {
15671	//     "id": {
15672	//       "description": "User profile ID.",
15673	//       "format": "int64",
15674	//       "location": "query",
15675	//       "required": true,
15676	//       "type": "string"
15677	//     },
15678	//     "profileId": {
15679	//       "description": "User profile ID associated with this request.",
15680	//       "format": "int64",
15681	//       "location": "path",
15682	//       "required": true,
15683	//       "type": "string"
15684	//     }
15685	//   },
15686	//   "path": "userprofiles/{profileId}/accountUserProfiles",
15687	//   "request": {
15688	//     "$ref": "AccountUserProfile"
15689	//   },
15690	//   "response": {
15691	//     "$ref": "AccountUserProfile"
15692	//   },
15693	//   "scopes": [
15694	//     "https://www.googleapis.com/auth/dfatrafficking"
15695	//   ]
15696	// }
15697
15698}
15699
15700// method id "dfareporting.accountUserProfiles.update":
15701
15702type AccountUserProfilesUpdateCall struct {
15703	s                  *Service
15704	profileId          int64
15705	accountuserprofile *AccountUserProfile
15706	urlParams_         gensupport.URLParams
15707	ctx_               context.Context
15708	header_            http.Header
15709}
15710
15711// Update: Updates an existing account user profile.
15712func (r *AccountUserProfilesService) Update(profileId int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesUpdateCall {
15713	c := &AccountUserProfilesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15714	c.profileId = profileId
15715	c.accountuserprofile = accountuserprofile
15716	return c
15717}
15718
15719// Fields allows partial responses to be retrieved. See
15720// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15721// for more information.
15722func (c *AccountUserProfilesUpdateCall) Fields(s ...googleapi.Field) *AccountUserProfilesUpdateCall {
15723	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15724	return c
15725}
15726
15727// Context sets the context to be used in this call's Do method. Any
15728// pending HTTP request will be aborted if the provided context is
15729// canceled.
15730func (c *AccountUserProfilesUpdateCall) Context(ctx context.Context) *AccountUserProfilesUpdateCall {
15731	c.ctx_ = ctx
15732	return c
15733}
15734
15735// Header returns an http.Header that can be modified by the caller to
15736// add HTTP headers to the request.
15737func (c *AccountUserProfilesUpdateCall) Header() http.Header {
15738	if c.header_ == nil {
15739		c.header_ = make(http.Header)
15740	}
15741	return c.header_
15742}
15743
15744func (c *AccountUserProfilesUpdateCall) doRequest(alt string) (*http.Response, error) {
15745	reqHeaders := make(http.Header)
15746	for k, v := range c.header_ {
15747		reqHeaders[k] = v
15748	}
15749	reqHeaders.Set("User-Agent", c.s.userAgent())
15750	var body io.Reader = nil
15751	body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
15752	if err != nil {
15753		return nil, err
15754	}
15755	reqHeaders.Set("Content-Type", "application/json")
15756	c.urlParams_.Set("alt", alt)
15757	c.urlParams_.Set("prettyPrint", "false")
15758	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15759	urls += "?" + c.urlParams_.Encode()
15760	req, err := http.NewRequest("PUT", urls, body)
15761	if err != nil {
15762		return nil, err
15763	}
15764	req.Header = reqHeaders
15765	googleapi.Expand(req.URL, map[string]string{
15766		"profileId": strconv.FormatInt(c.profileId, 10),
15767	})
15768	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15769}
15770
15771// Do executes the "dfareporting.accountUserProfiles.update" call.
15772// Exactly one of *AccountUserProfile or error will be non-nil. Any
15773// non-2xx status code is an error. Response headers are in either
15774// *AccountUserProfile.ServerResponse.Header or (if a response was
15775// returned at all) in error.(*googleapi.Error).Header. Use
15776// googleapi.IsNotModified to check whether the returned error was
15777// because http.StatusNotModified was returned.
15778func (c *AccountUserProfilesUpdateCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15779	gensupport.SetOptions(c.urlParams_, opts...)
15780	res, err := c.doRequest("json")
15781	if res != nil && res.StatusCode == http.StatusNotModified {
15782		if res.Body != nil {
15783			res.Body.Close()
15784		}
15785		return nil, &googleapi.Error{
15786			Code:   res.StatusCode,
15787			Header: res.Header,
15788		}
15789	}
15790	if err != nil {
15791		return nil, err
15792	}
15793	defer googleapi.CloseBody(res)
15794	if err := googleapi.CheckResponse(res); err != nil {
15795		return nil, err
15796	}
15797	ret := &AccountUserProfile{
15798		ServerResponse: googleapi.ServerResponse{
15799			Header:         res.Header,
15800			HTTPStatusCode: res.StatusCode,
15801		},
15802	}
15803	target := &ret
15804	if err := gensupport.DecodeResponse(target, res); err != nil {
15805		return nil, err
15806	}
15807	return ret, nil
15808	// {
15809	//   "description": "Updates an existing account user profile.",
15810	//   "httpMethod": "PUT",
15811	//   "id": "dfareporting.accountUserProfiles.update",
15812	//   "parameterOrder": [
15813	//     "profileId"
15814	//   ],
15815	//   "parameters": {
15816	//     "profileId": {
15817	//       "description": "User profile ID associated with this request.",
15818	//       "format": "int64",
15819	//       "location": "path",
15820	//       "required": true,
15821	//       "type": "string"
15822	//     }
15823	//   },
15824	//   "path": "userprofiles/{profileId}/accountUserProfiles",
15825	//   "request": {
15826	//     "$ref": "AccountUserProfile"
15827	//   },
15828	//   "response": {
15829	//     "$ref": "AccountUserProfile"
15830	//   },
15831	//   "scopes": [
15832	//     "https://www.googleapis.com/auth/dfatrafficking"
15833	//   ]
15834	// }
15835
15836}
15837
15838// method id "dfareporting.accounts.get":
15839
15840type AccountsGetCall struct {
15841	s            *Service
15842	profileId    int64
15843	id           int64
15844	urlParams_   gensupport.URLParams
15845	ifNoneMatch_ string
15846	ctx_         context.Context
15847	header_      http.Header
15848}
15849
15850// Get: Gets one account by ID.
15851func (r *AccountsService) Get(profileId int64, id int64) *AccountsGetCall {
15852	c := &AccountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15853	c.profileId = profileId
15854	c.id = id
15855	return c
15856}
15857
15858// Fields allows partial responses to be retrieved. See
15859// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15860// for more information.
15861func (c *AccountsGetCall) Fields(s ...googleapi.Field) *AccountsGetCall {
15862	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15863	return c
15864}
15865
15866// IfNoneMatch sets the optional parameter which makes the operation
15867// fail if the object's ETag matches the given value. This is useful for
15868// getting updates only after the object has changed since the last
15869// request. Use googleapi.IsNotModified to check whether the response
15870// error from Do is the result of In-None-Match.
15871func (c *AccountsGetCall) IfNoneMatch(entityTag string) *AccountsGetCall {
15872	c.ifNoneMatch_ = entityTag
15873	return c
15874}
15875
15876// Context sets the context to be used in this call's Do method. Any
15877// pending HTTP request will be aborted if the provided context is
15878// canceled.
15879func (c *AccountsGetCall) Context(ctx context.Context) *AccountsGetCall {
15880	c.ctx_ = ctx
15881	return c
15882}
15883
15884// Header returns an http.Header that can be modified by the caller to
15885// add HTTP headers to the request.
15886func (c *AccountsGetCall) Header() http.Header {
15887	if c.header_ == nil {
15888		c.header_ = make(http.Header)
15889	}
15890	return c.header_
15891}
15892
15893func (c *AccountsGetCall) doRequest(alt string) (*http.Response, error) {
15894	reqHeaders := make(http.Header)
15895	for k, v := range c.header_ {
15896		reqHeaders[k] = v
15897	}
15898	reqHeaders.Set("User-Agent", c.s.userAgent())
15899	if c.ifNoneMatch_ != "" {
15900		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15901	}
15902	var body io.Reader = nil
15903	c.urlParams_.Set("alt", alt)
15904	c.urlParams_.Set("prettyPrint", "false")
15905	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts/{id}")
15906	urls += "?" + c.urlParams_.Encode()
15907	req, err := http.NewRequest("GET", urls, body)
15908	if err != nil {
15909		return nil, err
15910	}
15911	req.Header = reqHeaders
15912	googleapi.Expand(req.URL, map[string]string{
15913		"profileId": strconv.FormatInt(c.profileId, 10),
15914		"id":        strconv.FormatInt(c.id, 10),
15915	})
15916	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15917}
15918
15919// Do executes the "dfareporting.accounts.get" call.
15920// Exactly one of *Account or error will be non-nil. Any non-2xx status
15921// code is an error. Response headers are in either
15922// *Account.ServerResponse.Header or (if a response was returned at all)
15923// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
15924// check whether the returned error was because http.StatusNotModified
15925// was returned.
15926func (c *AccountsGetCall) Do(opts ...googleapi.CallOption) (*Account, error) {
15927	gensupport.SetOptions(c.urlParams_, opts...)
15928	res, err := c.doRequest("json")
15929	if res != nil && res.StatusCode == http.StatusNotModified {
15930		if res.Body != nil {
15931			res.Body.Close()
15932		}
15933		return nil, &googleapi.Error{
15934			Code:   res.StatusCode,
15935			Header: res.Header,
15936		}
15937	}
15938	if err != nil {
15939		return nil, err
15940	}
15941	defer googleapi.CloseBody(res)
15942	if err := googleapi.CheckResponse(res); err != nil {
15943		return nil, err
15944	}
15945	ret := &Account{
15946		ServerResponse: googleapi.ServerResponse{
15947			Header:         res.Header,
15948			HTTPStatusCode: res.StatusCode,
15949		},
15950	}
15951	target := &ret
15952	if err := gensupport.DecodeResponse(target, res); err != nil {
15953		return nil, err
15954	}
15955	return ret, nil
15956	// {
15957	//   "description": "Gets one account by ID.",
15958	//   "httpMethod": "GET",
15959	//   "id": "dfareporting.accounts.get",
15960	//   "parameterOrder": [
15961	//     "profileId",
15962	//     "id"
15963	//   ],
15964	//   "parameters": {
15965	//     "id": {
15966	//       "description": "Account ID.",
15967	//       "format": "int64",
15968	//       "location": "path",
15969	//       "required": true,
15970	//       "type": "string"
15971	//     },
15972	//     "profileId": {
15973	//       "description": "User profile ID associated with this request.",
15974	//       "format": "int64",
15975	//       "location": "path",
15976	//       "required": true,
15977	//       "type": "string"
15978	//     }
15979	//   },
15980	//   "path": "userprofiles/{profileId}/accounts/{id}",
15981	//   "response": {
15982	//     "$ref": "Account"
15983	//   },
15984	//   "scopes": [
15985	//     "https://www.googleapis.com/auth/dfatrafficking"
15986	//   ]
15987	// }
15988
15989}
15990
15991// method id "dfareporting.accounts.list":
15992
15993type AccountsListCall struct {
15994	s            *Service
15995	profileId    int64
15996	urlParams_   gensupport.URLParams
15997	ifNoneMatch_ string
15998	ctx_         context.Context
15999	header_      http.Header
16000}
16001
16002// List: Retrieves the list of accounts, possibly filtered. This method
16003// supports paging.
16004func (r *AccountsService) List(profileId int64) *AccountsListCall {
16005	c := &AccountsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16006	c.profileId = profileId
16007	return c
16008}
16009
16010// Active sets the optional parameter "active": Select only active
16011// accounts. Don't set this field to select both active and non-active
16012// accounts.
16013func (c *AccountsListCall) Active(active bool) *AccountsListCall {
16014	c.urlParams_.Set("active", fmt.Sprint(active))
16015	return c
16016}
16017
16018// Ids sets the optional parameter "ids": Select only accounts with
16019// these IDs.
16020func (c *AccountsListCall) Ids(ids ...int64) *AccountsListCall {
16021	var ids_ []string
16022	for _, v := range ids {
16023		ids_ = append(ids_, fmt.Sprint(v))
16024	}
16025	c.urlParams_.SetMulti("ids", ids_)
16026	return c
16027}
16028
16029// MaxResults sets the optional parameter "maxResults": Maximum number
16030// of results to return.
16031func (c *AccountsListCall) MaxResults(maxResults int64) *AccountsListCall {
16032	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
16033	return c
16034}
16035
16036// PageToken sets the optional parameter "pageToken": Value of the
16037// nextPageToken from the previous result page.
16038func (c *AccountsListCall) PageToken(pageToken string) *AccountsListCall {
16039	c.urlParams_.Set("pageToken", pageToken)
16040	return c
16041}
16042
16043// SearchString sets the optional parameter "searchString": Allows
16044// searching for objects by name or ID. Wildcards (*) are allowed. For
16045// example, "account*2015" will return objects with names like "account
16046// June 2015", "account April 2015", or simply "account 2015". Most of
16047// the searches also add wildcards implicitly at the start and the end
16048// of the search string. For example, a search string of "account" will
16049// match objects with name "my account", "account 2015", or simply
16050// "account".
16051func (c *AccountsListCall) SearchString(searchString string) *AccountsListCall {
16052	c.urlParams_.Set("searchString", searchString)
16053	return c
16054}
16055
16056// SortField sets the optional parameter "sortField": Field by which to
16057// sort the list.
16058//
16059// Possible values:
16060//   "ID" (default)
16061//   "NAME"
16062func (c *AccountsListCall) SortField(sortField string) *AccountsListCall {
16063	c.urlParams_.Set("sortField", sortField)
16064	return c
16065}
16066
16067// SortOrder sets the optional parameter "sortOrder": Order of sorted
16068// results.
16069//
16070// Possible values:
16071//   "ASCENDING" (default)
16072//   "DESCENDING"
16073func (c *AccountsListCall) SortOrder(sortOrder string) *AccountsListCall {
16074	c.urlParams_.Set("sortOrder", sortOrder)
16075	return c
16076}
16077
16078// Fields allows partial responses to be retrieved. See
16079// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16080// for more information.
16081func (c *AccountsListCall) Fields(s ...googleapi.Field) *AccountsListCall {
16082	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16083	return c
16084}
16085
16086// IfNoneMatch sets the optional parameter which makes the operation
16087// fail if the object's ETag matches the given value. This is useful for
16088// getting updates only after the object has changed since the last
16089// request. Use googleapi.IsNotModified to check whether the response
16090// error from Do is the result of In-None-Match.
16091func (c *AccountsListCall) IfNoneMatch(entityTag string) *AccountsListCall {
16092	c.ifNoneMatch_ = entityTag
16093	return c
16094}
16095
16096// Context sets the context to be used in this call's Do method. Any
16097// pending HTTP request will be aborted if the provided context is
16098// canceled.
16099func (c *AccountsListCall) Context(ctx context.Context) *AccountsListCall {
16100	c.ctx_ = ctx
16101	return c
16102}
16103
16104// Header returns an http.Header that can be modified by the caller to
16105// add HTTP headers to the request.
16106func (c *AccountsListCall) Header() http.Header {
16107	if c.header_ == nil {
16108		c.header_ = make(http.Header)
16109	}
16110	return c.header_
16111}
16112
16113func (c *AccountsListCall) doRequest(alt string) (*http.Response, error) {
16114	reqHeaders := make(http.Header)
16115	for k, v := range c.header_ {
16116		reqHeaders[k] = v
16117	}
16118	reqHeaders.Set("User-Agent", c.s.userAgent())
16119	if c.ifNoneMatch_ != "" {
16120		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
16121	}
16122	var body io.Reader = nil
16123	c.urlParams_.Set("alt", alt)
16124	c.urlParams_.Set("prettyPrint", "false")
16125	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
16126	urls += "?" + c.urlParams_.Encode()
16127	req, err := http.NewRequest("GET", urls, body)
16128	if err != nil {
16129		return nil, err
16130	}
16131	req.Header = reqHeaders
16132	googleapi.Expand(req.URL, map[string]string{
16133		"profileId": strconv.FormatInt(c.profileId, 10),
16134	})
16135	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16136}
16137
16138// Do executes the "dfareporting.accounts.list" call.
16139// Exactly one of *AccountsListResponse or error will be non-nil. Any
16140// non-2xx status code is an error. Response headers are in either
16141// *AccountsListResponse.ServerResponse.Header or (if a response was
16142// returned at all) in error.(*googleapi.Error).Header. Use
16143// googleapi.IsNotModified to check whether the returned error was
16144// because http.StatusNotModified was returned.
16145func (c *AccountsListCall) Do(opts ...googleapi.CallOption) (*AccountsListResponse, error) {
16146	gensupport.SetOptions(c.urlParams_, opts...)
16147	res, err := c.doRequest("json")
16148	if res != nil && res.StatusCode == http.StatusNotModified {
16149		if res.Body != nil {
16150			res.Body.Close()
16151		}
16152		return nil, &googleapi.Error{
16153			Code:   res.StatusCode,
16154			Header: res.Header,
16155		}
16156	}
16157	if err != nil {
16158		return nil, err
16159	}
16160	defer googleapi.CloseBody(res)
16161	if err := googleapi.CheckResponse(res); err != nil {
16162		return nil, err
16163	}
16164	ret := &AccountsListResponse{
16165		ServerResponse: googleapi.ServerResponse{
16166			Header:         res.Header,
16167			HTTPStatusCode: res.StatusCode,
16168		},
16169	}
16170	target := &ret
16171	if err := gensupport.DecodeResponse(target, res); err != nil {
16172		return nil, err
16173	}
16174	return ret, nil
16175	// {
16176	//   "description": "Retrieves the list of accounts, possibly filtered. This method supports paging.",
16177	//   "httpMethod": "GET",
16178	//   "id": "dfareporting.accounts.list",
16179	//   "parameterOrder": [
16180	//     "profileId"
16181	//   ],
16182	//   "parameters": {
16183	//     "active": {
16184	//       "description": "Select only active accounts. Don't set this field to select both active and non-active accounts.",
16185	//       "location": "query",
16186	//       "type": "boolean"
16187	//     },
16188	//     "ids": {
16189	//       "description": "Select only accounts with these IDs.",
16190	//       "format": "int64",
16191	//       "location": "query",
16192	//       "repeated": true,
16193	//       "type": "string"
16194	//     },
16195	//     "maxResults": {
16196	//       "default": "1000",
16197	//       "description": "Maximum number of results to return.",
16198	//       "format": "int32",
16199	//       "location": "query",
16200	//       "maximum": "1000",
16201	//       "minimum": "0",
16202	//       "type": "integer"
16203	//     },
16204	//     "pageToken": {
16205	//       "description": "Value of the nextPageToken from the previous result page.",
16206	//       "location": "query",
16207	//       "type": "string"
16208	//     },
16209	//     "profileId": {
16210	//       "description": "User profile ID associated with this request.",
16211	//       "format": "int64",
16212	//       "location": "path",
16213	//       "required": true,
16214	//       "type": "string"
16215	//     },
16216	//     "searchString": {
16217	//       "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\".",
16218	//       "location": "query",
16219	//       "type": "string"
16220	//     },
16221	//     "sortField": {
16222	//       "default": "ID",
16223	//       "description": "Field by which to sort the list.",
16224	//       "enum": [
16225	//         "ID",
16226	//         "NAME"
16227	//       ],
16228	//       "enumDescriptions": [
16229	//         "",
16230	//         ""
16231	//       ],
16232	//       "location": "query",
16233	//       "type": "string"
16234	//     },
16235	//     "sortOrder": {
16236	//       "default": "ASCENDING",
16237	//       "description": "Order of sorted results.",
16238	//       "enum": [
16239	//         "ASCENDING",
16240	//         "DESCENDING"
16241	//       ],
16242	//       "enumDescriptions": [
16243	//         "",
16244	//         ""
16245	//       ],
16246	//       "location": "query",
16247	//       "type": "string"
16248	//     }
16249	//   },
16250	//   "path": "userprofiles/{profileId}/accounts",
16251	//   "response": {
16252	//     "$ref": "AccountsListResponse"
16253	//   },
16254	//   "scopes": [
16255	//     "https://www.googleapis.com/auth/dfatrafficking"
16256	//   ]
16257	// }
16258
16259}
16260
16261// Pages invokes f for each page of results.
16262// A non-nil error returned from f will halt the iteration.
16263// The provided context supersedes any context provided to the Context method.
16264func (c *AccountsListCall) Pages(ctx context.Context, f func(*AccountsListResponse) error) error {
16265	c.ctx_ = ctx
16266	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
16267	for {
16268		x, err := c.Do()
16269		if err != nil {
16270			return err
16271		}
16272		if err := f(x); err != nil {
16273			return err
16274		}
16275		if x.NextPageToken == "" {
16276			return nil
16277		}
16278		c.PageToken(x.NextPageToken)
16279	}
16280}
16281
16282// method id "dfareporting.accounts.patch":
16283
16284type AccountsPatchCall struct {
16285	s          *Service
16286	profileId  int64
16287	account    *Account
16288	urlParams_ gensupport.URLParams
16289	ctx_       context.Context
16290	header_    http.Header
16291}
16292
16293// Patch: Updates an existing account. This method supports patch
16294// semantics.
16295func (r *AccountsService) Patch(profileId int64, id int64, account *Account) *AccountsPatchCall {
16296	c := &AccountsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16297	c.profileId = profileId
16298	c.urlParams_.Set("id", fmt.Sprint(id))
16299	c.account = account
16300	return c
16301}
16302
16303// Fields allows partial responses to be retrieved. See
16304// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16305// for more information.
16306func (c *AccountsPatchCall) Fields(s ...googleapi.Field) *AccountsPatchCall {
16307	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16308	return c
16309}
16310
16311// Context sets the context to be used in this call's Do method. Any
16312// pending HTTP request will be aborted if the provided context is
16313// canceled.
16314func (c *AccountsPatchCall) Context(ctx context.Context) *AccountsPatchCall {
16315	c.ctx_ = ctx
16316	return c
16317}
16318
16319// Header returns an http.Header that can be modified by the caller to
16320// add HTTP headers to the request.
16321func (c *AccountsPatchCall) Header() http.Header {
16322	if c.header_ == nil {
16323		c.header_ = make(http.Header)
16324	}
16325	return c.header_
16326}
16327
16328func (c *AccountsPatchCall) doRequest(alt string) (*http.Response, error) {
16329	reqHeaders := make(http.Header)
16330	for k, v := range c.header_ {
16331		reqHeaders[k] = v
16332	}
16333	reqHeaders.Set("User-Agent", c.s.userAgent())
16334	var body io.Reader = nil
16335	body, err := googleapi.WithoutDataWrapper.JSONReader(c.account)
16336	if err != nil {
16337		return nil, err
16338	}
16339	reqHeaders.Set("Content-Type", "application/json")
16340	c.urlParams_.Set("alt", alt)
16341	c.urlParams_.Set("prettyPrint", "false")
16342	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
16343	urls += "?" + c.urlParams_.Encode()
16344	req, err := http.NewRequest("PATCH", urls, body)
16345	if err != nil {
16346		return nil, err
16347	}
16348	req.Header = reqHeaders
16349	googleapi.Expand(req.URL, map[string]string{
16350		"profileId": strconv.FormatInt(c.profileId, 10),
16351	})
16352	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16353}
16354
16355// Do executes the "dfareporting.accounts.patch" call.
16356// Exactly one of *Account or error will be non-nil. Any non-2xx status
16357// code is an error. Response headers are in either
16358// *Account.ServerResponse.Header or (if a response was returned at all)
16359// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
16360// check whether the returned error was because http.StatusNotModified
16361// was returned.
16362func (c *AccountsPatchCall) Do(opts ...googleapi.CallOption) (*Account, error) {
16363	gensupport.SetOptions(c.urlParams_, opts...)
16364	res, err := c.doRequest("json")
16365	if res != nil && res.StatusCode == http.StatusNotModified {
16366		if res.Body != nil {
16367			res.Body.Close()
16368		}
16369		return nil, &googleapi.Error{
16370			Code:   res.StatusCode,
16371			Header: res.Header,
16372		}
16373	}
16374	if err != nil {
16375		return nil, err
16376	}
16377	defer googleapi.CloseBody(res)
16378	if err := googleapi.CheckResponse(res); err != nil {
16379		return nil, err
16380	}
16381	ret := &Account{
16382		ServerResponse: googleapi.ServerResponse{
16383			Header:         res.Header,
16384			HTTPStatusCode: res.StatusCode,
16385		},
16386	}
16387	target := &ret
16388	if err := gensupport.DecodeResponse(target, res); err != nil {
16389		return nil, err
16390	}
16391	return ret, nil
16392	// {
16393	//   "description": "Updates an existing account. This method supports patch semantics.",
16394	//   "httpMethod": "PATCH",
16395	//   "id": "dfareporting.accounts.patch",
16396	//   "parameterOrder": [
16397	//     "profileId",
16398	//     "id"
16399	//   ],
16400	//   "parameters": {
16401	//     "id": {
16402	//       "description": "Account ID.",
16403	//       "format": "int64",
16404	//       "location": "query",
16405	//       "required": true,
16406	//       "type": "string"
16407	//     },
16408	//     "profileId": {
16409	//       "description": "User profile ID associated with this request.",
16410	//       "format": "int64",
16411	//       "location": "path",
16412	//       "required": true,
16413	//       "type": "string"
16414	//     }
16415	//   },
16416	//   "path": "userprofiles/{profileId}/accounts",
16417	//   "request": {
16418	//     "$ref": "Account"
16419	//   },
16420	//   "response": {
16421	//     "$ref": "Account"
16422	//   },
16423	//   "scopes": [
16424	//     "https://www.googleapis.com/auth/dfatrafficking"
16425	//   ]
16426	// }
16427
16428}
16429
16430// method id "dfareporting.accounts.update":
16431
16432type AccountsUpdateCall struct {
16433	s          *Service
16434	profileId  int64
16435	account    *Account
16436	urlParams_ gensupport.URLParams
16437	ctx_       context.Context
16438	header_    http.Header
16439}
16440
16441// Update: Updates an existing account.
16442func (r *AccountsService) Update(profileId int64, account *Account) *AccountsUpdateCall {
16443	c := &AccountsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16444	c.profileId = profileId
16445	c.account = account
16446	return c
16447}
16448
16449// Fields allows partial responses to be retrieved. See
16450// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16451// for more information.
16452func (c *AccountsUpdateCall) Fields(s ...googleapi.Field) *AccountsUpdateCall {
16453	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16454	return c
16455}
16456
16457// Context sets the context to be used in this call's Do method. Any
16458// pending HTTP request will be aborted if the provided context is
16459// canceled.
16460func (c *AccountsUpdateCall) Context(ctx context.Context) *AccountsUpdateCall {
16461	c.ctx_ = ctx
16462	return c
16463}
16464
16465// Header returns an http.Header that can be modified by the caller to
16466// add HTTP headers to the request.
16467func (c *AccountsUpdateCall) Header() http.Header {
16468	if c.header_ == nil {
16469		c.header_ = make(http.Header)
16470	}
16471	return c.header_
16472}
16473
16474func (c *AccountsUpdateCall) doRequest(alt string) (*http.Response, error) {
16475	reqHeaders := make(http.Header)
16476	for k, v := range c.header_ {
16477		reqHeaders[k] = v
16478	}
16479	reqHeaders.Set("User-Agent", c.s.userAgent())
16480	var body io.Reader = nil
16481	body, err := googleapi.WithoutDataWrapper.JSONReader(c.account)
16482	if err != nil {
16483		return nil, err
16484	}
16485	reqHeaders.Set("Content-Type", "application/json")
16486	c.urlParams_.Set("alt", alt)
16487	c.urlParams_.Set("prettyPrint", "false")
16488	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
16489	urls += "?" + c.urlParams_.Encode()
16490	req, err := http.NewRequest("PUT", urls, body)
16491	if err != nil {
16492		return nil, err
16493	}
16494	req.Header = reqHeaders
16495	googleapi.Expand(req.URL, map[string]string{
16496		"profileId": strconv.FormatInt(c.profileId, 10),
16497	})
16498	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16499}
16500
16501// Do executes the "dfareporting.accounts.update" call.
16502// Exactly one of *Account or error will be non-nil. Any non-2xx status
16503// code is an error. Response headers are in either
16504// *Account.ServerResponse.Header or (if a response was returned at all)
16505// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
16506// check whether the returned error was because http.StatusNotModified
16507// was returned.
16508func (c *AccountsUpdateCall) Do(opts ...googleapi.CallOption) (*Account, error) {
16509	gensupport.SetOptions(c.urlParams_, opts...)
16510	res, err := c.doRequest("json")
16511	if res != nil && res.StatusCode == http.StatusNotModified {
16512		if res.Body != nil {
16513			res.Body.Close()
16514		}
16515		return nil, &googleapi.Error{
16516			Code:   res.StatusCode,
16517			Header: res.Header,
16518		}
16519	}
16520	if err != nil {
16521		return nil, err
16522	}
16523	defer googleapi.CloseBody(res)
16524	if err := googleapi.CheckResponse(res); err != nil {
16525		return nil, err
16526	}
16527	ret := &Account{
16528		ServerResponse: googleapi.ServerResponse{
16529			Header:         res.Header,
16530			HTTPStatusCode: res.StatusCode,
16531		},
16532	}
16533	target := &ret
16534	if err := gensupport.DecodeResponse(target, res); err != nil {
16535		return nil, err
16536	}
16537	return ret, nil
16538	// {
16539	//   "description": "Updates an existing account.",
16540	//   "httpMethod": "PUT",
16541	//   "id": "dfareporting.accounts.update",
16542	//   "parameterOrder": [
16543	//     "profileId"
16544	//   ],
16545	//   "parameters": {
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}/accounts",
16555	//   "request": {
16556	//     "$ref": "Account"
16557	//   },
16558	//   "response": {
16559	//     "$ref": "Account"
16560	//   },
16561	//   "scopes": [
16562	//     "https://www.googleapis.com/auth/dfatrafficking"
16563	//   ]
16564	// }
16565
16566}
16567
16568// method id "dfareporting.ads.get":
16569
16570type AdsGetCall struct {
16571	s            *Service
16572	profileId    int64
16573	id           int64
16574	urlParams_   gensupport.URLParams
16575	ifNoneMatch_ string
16576	ctx_         context.Context
16577	header_      http.Header
16578}
16579
16580// Get: Gets one ad by ID.
16581func (r *AdsService) Get(profileId int64, id int64) *AdsGetCall {
16582	c := &AdsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16583	c.profileId = profileId
16584	c.id = id
16585	return c
16586}
16587
16588// Fields allows partial responses to be retrieved. See
16589// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16590// for more information.
16591func (c *AdsGetCall) Fields(s ...googleapi.Field) *AdsGetCall {
16592	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16593	return c
16594}
16595
16596// IfNoneMatch sets the optional parameter which makes the operation
16597// fail if the object's ETag matches the given value. This is useful for
16598// getting updates only after the object has changed since the last
16599// request. Use googleapi.IsNotModified to check whether the response
16600// error from Do is the result of In-None-Match.
16601func (c *AdsGetCall) IfNoneMatch(entityTag string) *AdsGetCall {
16602	c.ifNoneMatch_ = entityTag
16603	return c
16604}
16605
16606// Context sets the context to be used in this call's Do method. Any
16607// pending HTTP request will be aborted if the provided context is
16608// canceled.
16609func (c *AdsGetCall) Context(ctx context.Context) *AdsGetCall {
16610	c.ctx_ = ctx
16611	return c
16612}
16613
16614// Header returns an http.Header that can be modified by the caller to
16615// add HTTP headers to the request.
16616func (c *AdsGetCall) Header() http.Header {
16617	if c.header_ == nil {
16618		c.header_ = make(http.Header)
16619	}
16620	return c.header_
16621}
16622
16623func (c *AdsGetCall) doRequest(alt string) (*http.Response, error) {
16624	reqHeaders := make(http.Header)
16625	for k, v := range c.header_ {
16626		reqHeaders[k] = v
16627	}
16628	reqHeaders.Set("User-Agent", c.s.userAgent())
16629	if c.ifNoneMatch_ != "" {
16630		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
16631	}
16632	var body io.Reader = nil
16633	c.urlParams_.Set("alt", alt)
16634	c.urlParams_.Set("prettyPrint", "false")
16635	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads/{id}")
16636	urls += "?" + c.urlParams_.Encode()
16637	req, err := http.NewRequest("GET", urls, body)
16638	if err != nil {
16639		return nil, err
16640	}
16641	req.Header = reqHeaders
16642	googleapi.Expand(req.URL, map[string]string{
16643		"profileId": strconv.FormatInt(c.profileId, 10),
16644		"id":        strconv.FormatInt(c.id, 10),
16645	})
16646	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16647}
16648
16649// Do executes the "dfareporting.ads.get" call.
16650// Exactly one of *Ad or error will be non-nil. Any non-2xx status code
16651// is an error. Response headers are in either *Ad.ServerResponse.Header
16652// or (if a response was returned at all) in
16653// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
16654// whether the returned error was because http.StatusNotModified was
16655// returned.
16656func (c *AdsGetCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
16657	gensupport.SetOptions(c.urlParams_, opts...)
16658	res, err := c.doRequest("json")
16659	if res != nil && res.StatusCode == http.StatusNotModified {
16660		if res.Body != nil {
16661			res.Body.Close()
16662		}
16663		return nil, &googleapi.Error{
16664			Code:   res.StatusCode,
16665			Header: res.Header,
16666		}
16667	}
16668	if err != nil {
16669		return nil, err
16670	}
16671	defer googleapi.CloseBody(res)
16672	if err := googleapi.CheckResponse(res); err != nil {
16673		return nil, err
16674	}
16675	ret := &Ad{
16676		ServerResponse: googleapi.ServerResponse{
16677			Header:         res.Header,
16678			HTTPStatusCode: res.StatusCode,
16679		},
16680	}
16681	target := &ret
16682	if err := gensupport.DecodeResponse(target, res); err != nil {
16683		return nil, err
16684	}
16685	return ret, nil
16686	// {
16687	//   "description": "Gets one ad by ID.",
16688	//   "httpMethod": "GET",
16689	//   "id": "dfareporting.ads.get",
16690	//   "parameterOrder": [
16691	//     "profileId",
16692	//     "id"
16693	//   ],
16694	//   "parameters": {
16695	//     "id": {
16696	//       "description": "Ad ID.",
16697	//       "format": "int64",
16698	//       "location": "path",
16699	//       "required": true,
16700	//       "type": "string"
16701	//     },
16702	//     "profileId": {
16703	//       "description": "User profile ID associated with this request.",
16704	//       "format": "int64",
16705	//       "location": "path",
16706	//       "required": true,
16707	//       "type": "string"
16708	//     }
16709	//   },
16710	//   "path": "userprofiles/{profileId}/ads/{id}",
16711	//   "response": {
16712	//     "$ref": "Ad"
16713	//   },
16714	//   "scopes": [
16715	//     "https://www.googleapis.com/auth/dfatrafficking"
16716	//   ]
16717	// }
16718
16719}
16720
16721// method id "dfareporting.ads.insert":
16722
16723type AdsInsertCall struct {
16724	s          *Service
16725	profileId  int64
16726	ad         *Ad
16727	urlParams_ gensupport.URLParams
16728	ctx_       context.Context
16729	header_    http.Header
16730}
16731
16732// Insert: Inserts a new ad.
16733func (r *AdsService) Insert(profileId int64, ad *Ad) *AdsInsertCall {
16734	c := &AdsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16735	c.profileId = profileId
16736	c.ad = ad
16737	return c
16738}
16739
16740// Fields allows partial responses to be retrieved. See
16741// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16742// for more information.
16743func (c *AdsInsertCall) Fields(s ...googleapi.Field) *AdsInsertCall {
16744	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16745	return c
16746}
16747
16748// Context sets the context to be used in this call's Do method. Any
16749// pending HTTP request will be aborted if the provided context is
16750// canceled.
16751func (c *AdsInsertCall) Context(ctx context.Context) *AdsInsertCall {
16752	c.ctx_ = ctx
16753	return c
16754}
16755
16756// Header returns an http.Header that can be modified by the caller to
16757// add HTTP headers to the request.
16758func (c *AdsInsertCall) Header() http.Header {
16759	if c.header_ == nil {
16760		c.header_ = make(http.Header)
16761	}
16762	return c.header_
16763}
16764
16765func (c *AdsInsertCall) doRequest(alt string) (*http.Response, error) {
16766	reqHeaders := make(http.Header)
16767	for k, v := range c.header_ {
16768		reqHeaders[k] = v
16769	}
16770	reqHeaders.Set("User-Agent", c.s.userAgent())
16771	var body io.Reader = nil
16772	body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
16773	if err != nil {
16774		return nil, err
16775	}
16776	reqHeaders.Set("Content-Type", "application/json")
16777	c.urlParams_.Set("alt", alt)
16778	c.urlParams_.Set("prettyPrint", "false")
16779	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
16780	urls += "?" + c.urlParams_.Encode()
16781	req, err := http.NewRequest("POST", urls, body)
16782	if err != nil {
16783		return nil, err
16784	}
16785	req.Header = reqHeaders
16786	googleapi.Expand(req.URL, map[string]string{
16787		"profileId": strconv.FormatInt(c.profileId, 10),
16788	})
16789	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16790}
16791
16792// Do executes the "dfareporting.ads.insert" call.
16793// Exactly one of *Ad or error will be non-nil. Any non-2xx status code
16794// is an error. Response headers are in either *Ad.ServerResponse.Header
16795// or (if a response was returned at all) in
16796// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
16797// whether the returned error was because http.StatusNotModified was
16798// returned.
16799func (c *AdsInsertCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
16800	gensupport.SetOptions(c.urlParams_, opts...)
16801	res, err := c.doRequest("json")
16802	if res != nil && res.StatusCode == http.StatusNotModified {
16803		if res.Body != nil {
16804			res.Body.Close()
16805		}
16806		return nil, &googleapi.Error{
16807			Code:   res.StatusCode,
16808			Header: res.Header,
16809		}
16810	}
16811	if err != nil {
16812		return nil, err
16813	}
16814	defer googleapi.CloseBody(res)
16815	if err := googleapi.CheckResponse(res); err != nil {
16816		return nil, err
16817	}
16818	ret := &Ad{
16819		ServerResponse: googleapi.ServerResponse{
16820			Header:         res.Header,
16821			HTTPStatusCode: res.StatusCode,
16822		},
16823	}
16824	target := &ret
16825	if err := gensupport.DecodeResponse(target, res); err != nil {
16826		return nil, err
16827	}
16828	return ret, nil
16829	// {
16830	//   "description": "Inserts a new ad.",
16831	//   "httpMethod": "POST",
16832	//   "id": "dfareporting.ads.insert",
16833	//   "parameterOrder": [
16834	//     "profileId"
16835	//   ],
16836	//   "parameters": {
16837	//     "profileId": {
16838	//       "description": "User profile ID associated with this request.",
16839	//       "format": "int64",
16840	//       "location": "path",
16841	//       "required": true,
16842	//       "type": "string"
16843	//     }
16844	//   },
16845	//   "path": "userprofiles/{profileId}/ads",
16846	//   "request": {
16847	//     "$ref": "Ad"
16848	//   },
16849	//   "response": {
16850	//     "$ref": "Ad"
16851	//   },
16852	//   "scopes": [
16853	//     "https://www.googleapis.com/auth/dfatrafficking"
16854	//   ]
16855	// }
16856
16857}
16858
16859// method id "dfareporting.ads.list":
16860
16861type AdsListCall struct {
16862	s            *Service
16863	profileId    int64
16864	urlParams_   gensupport.URLParams
16865	ifNoneMatch_ string
16866	ctx_         context.Context
16867	header_      http.Header
16868}
16869
16870// List: Retrieves a list of ads, possibly filtered. This method
16871// supports paging.
16872func (r *AdsService) List(profileId int64) *AdsListCall {
16873	c := &AdsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16874	c.profileId = profileId
16875	return c
16876}
16877
16878// Active sets the optional parameter "active": Select only active ads.
16879func (c *AdsListCall) Active(active bool) *AdsListCall {
16880	c.urlParams_.Set("active", fmt.Sprint(active))
16881	return c
16882}
16883
16884// AdvertiserId sets the optional parameter "advertiserId": Select only
16885// ads with this advertiser ID.
16886func (c *AdsListCall) AdvertiserId(advertiserId int64) *AdsListCall {
16887	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
16888	return c
16889}
16890
16891// Archived sets the optional parameter "archived": Select only archived
16892// ads.
16893func (c *AdsListCall) Archived(archived bool) *AdsListCall {
16894	c.urlParams_.Set("archived", fmt.Sprint(archived))
16895	return c
16896}
16897
16898// AudienceSegmentIds sets the optional parameter "audienceSegmentIds":
16899// Select only ads with these audience segment IDs.
16900func (c *AdsListCall) AudienceSegmentIds(audienceSegmentIds ...int64) *AdsListCall {
16901	var audienceSegmentIds_ []string
16902	for _, v := range audienceSegmentIds {
16903		audienceSegmentIds_ = append(audienceSegmentIds_, fmt.Sprint(v))
16904	}
16905	c.urlParams_.SetMulti("audienceSegmentIds", audienceSegmentIds_)
16906	return c
16907}
16908
16909// CampaignIds sets the optional parameter "campaignIds": Select only
16910// ads with these campaign IDs.
16911func (c *AdsListCall) CampaignIds(campaignIds ...int64) *AdsListCall {
16912	var campaignIds_ []string
16913	for _, v := range campaignIds {
16914		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
16915	}
16916	c.urlParams_.SetMulti("campaignIds", campaignIds_)
16917	return c
16918}
16919
16920// Compatibility sets the optional parameter "compatibility": Select
16921// default ads with the specified compatibility. Applicable when type is
16922// AD_SERVING_DEFAULT_AD. DISPLAY and DISPLAY_INTERSTITIAL refer to
16923// rendering either on desktop or on mobile devices for regular or
16924// interstitial ads, respectively. APP and APP_INTERSTITIAL are for
16925// rendering in mobile apps. IN_STREAM_VIDEO refers to rendering an
16926// in-stream video ads developed with the VAST standard.
16927//
16928// Possible values:
16929//   "APP"
16930//   "APP_INTERSTITIAL"
16931//   "DISPLAY"
16932//   "DISPLAY_INTERSTITIAL"
16933//   "IN_STREAM_AUDIO"
16934//   "IN_STREAM_VIDEO"
16935func (c *AdsListCall) Compatibility(compatibility string) *AdsListCall {
16936	c.urlParams_.Set("compatibility", compatibility)
16937	return c
16938}
16939
16940// CreativeIds sets the optional parameter "creativeIds": Select only
16941// ads with these creative IDs assigned.
16942func (c *AdsListCall) CreativeIds(creativeIds ...int64) *AdsListCall {
16943	var creativeIds_ []string
16944	for _, v := range creativeIds {
16945		creativeIds_ = append(creativeIds_, fmt.Sprint(v))
16946	}
16947	c.urlParams_.SetMulti("creativeIds", creativeIds_)
16948	return c
16949}
16950
16951// CreativeOptimizationConfigurationIds sets the optional parameter
16952// "creativeOptimizationConfigurationIds": Select only ads with these
16953// creative optimization configuration IDs.
16954func (c *AdsListCall) CreativeOptimizationConfigurationIds(creativeOptimizationConfigurationIds ...int64) *AdsListCall {
16955	var creativeOptimizationConfigurationIds_ []string
16956	for _, v := range creativeOptimizationConfigurationIds {
16957		creativeOptimizationConfigurationIds_ = append(creativeOptimizationConfigurationIds_, fmt.Sprint(v))
16958	}
16959	c.urlParams_.SetMulti("creativeOptimizationConfigurationIds", creativeOptimizationConfigurationIds_)
16960	return c
16961}
16962
16963// DynamicClickTracker sets the optional parameter
16964// "dynamicClickTracker": Select only dynamic click trackers. Applicable
16965// when type is AD_SERVING_CLICK_TRACKER. If true, select dynamic click
16966// trackers. If false, select static click trackers. Leave unset to
16967// select both.
16968func (c *AdsListCall) DynamicClickTracker(dynamicClickTracker bool) *AdsListCall {
16969	c.urlParams_.Set("dynamicClickTracker", fmt.Sprint(dynamicClickTracker))
16970	return c
16971}
16972
16973// Ids sets the optional parameter "ids": Select only ads with these
16974// IDs.
16975func (c *AdsListCall) Ids(ids ...int64) *AdsListCall {
16976	var ids_ []string
16977	for _, v := range ids {
16978		ids_ = append(ids_, fmt.Sprint(v))
16979	}
16980	c.urlParams_.SetMulti("ids", ids_)
16981	return c
16982}
16983
16984// LandingPageIds sets the optional parameter "landingPageIds": Select
16985// only ads with these landing page IDs.
16986func (c *AdsListCall) LandingPageIds(landingPageIds ...int64) *AdsListCall {
16987	var landingPageIds_ []string
16988	for _, v := range landingPageIds {
16989		landingPageIds_ = append(landingPageIds_, fmt.Sprint(v))
16990	}
16991	c.urlParams_.SetMulti("landingPageIds", landingPageIds_)
16992	return c
16993}
16994
16995// MaxResults sets the optional parameter "maxResults": Maximum number
16996// of results to return.
16997func (c *AdsListCall) MaxResults(maxResults int64) *AdsListCall {
16998	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
16999	return c
17000}
17001
17002// OverriddenEventTagId sets the optional parameter
17003// "overriddenEventTagId": Select only ads with this event tag override
17004// ID.
17005func (c *AdsListCall) OverriddenEventTagId(overriddenEventTagId int64) *AdsListCall {
17006	c.urlParams_.Set("overriddenEventTagId", fmt.Sprint(overriddenEventTagId))
17007	return c
17008}
17009
17010// PageToken sets the optional parameter "pageToken": Value of the
17011// nextPageToken from the previous result page.
17012func (c *AdsListCall) PageToken(pageToken string) *AdsListCall {
17013	c.urlParams_.Set("pageToken", pageToken)
17014	return c
17015}
17016
17017// PlacementIds sets the optional parameter "placementIds": Select only
17018// ads with these placement IDs assigned.
17019func (c *AdsListCall) PlacementIds(placementIds ...int64) *AdsListCall {
17020	var placementIds_ []string
17021	for _, v := range placementIds {
17022		placementIds_ = append(placementIds_, fmt.Sprint(v))
17023	}
17024	c.urlParams_.SetMulti("placementIds", placementIds_)
17025	return c
17026}
17027
17028// RemarketingListIds sets the optional parameter "remarketingListIds":
17029// Select only ads whose list targeting expression use these remarketing
17030// list IDs.
17031func (c *AdsListCall) RemarketingListIds(remarketingListIds ...int64) *AdsListCall {
17032	var remarketingListIds_ []string
17033	for _, v := range remarketingListIds {
17034		remarketingListIds_ = append(remarketingListIds_, fmt.Sprint(v))
17035	}
17036	c.urlParams_.SetMulti("remarketingListIds", remarketingListIds_)
17037	return c
17038}
17039
17040// SearchString sets the optional parameter "searchString": Allows
17041// searching for objects by name or ID. Wildcards (*) are allowed. For
17042// example, "ad*2015" will return objects with names like "ad June
17043// 2015", "ad April 2015", or simply "ad 2015". Most of the searches
17044// also add wildcards implicitly at the start and the end of the search
17045// string. For example, a search string of "ad" will match objects with
17046// name "my ad", "ad 2015", or simply "ad".
17047func (c *AdsListCall) SearchString(searchString string) *AdsListCall {
17048	c.urlParams_.Set("searchString", searchString)
17049	return c
17050}
17051
17052// SizeIds sets the optional parameter "sizeIds": Select only ads with
17053// these size IDs.
17054func (c *AdsListCall) SizeIds(sizeIds ...int64) *AdsListCall {
17055	var sizeIds_ []string
17056	for _, v := range sizeIds {
17057		sizeIds_ = append(sizeIds_, fmt.Sprint(v))
17058	}
17059	c.urlParams_.SetMulti("sizeIds", sizeIds_)
17060	return c
17061}
17062
17063// SortField sets the optional parameter "sortField": Field by which to
17064// sort the list.
17065//
17066// Possible values:
17067//   "ID" (default)
17068//   "NAME"
17069func (c *AdsListCall) SortField(sortField string) *AdsListCall {
17070	c.urlParams_.Set("sortField", sortField)
17071	return c
17072}
17073
17074// SortOrder sets the optional parameter "sortOrder": Order of sorted
17075// results.
17076//
17077// Possible values:
17078//   "ASCENDING" (default)
17079//   "DESCENDING"
17080func (c *AdsListCall) SortOrder(sortOrder string) *AdsListCall {
17081	c.urlParams_.Set("sortOrder", sortOrder)
17082	return c
17083}
17084
17085// SslCompliant sets the optional parameter "sslCompliant": Select only
17086// ads that are SSL-compliant.
17087func (c *AdsListCall) SslCompliant(sslCompliant bool) *AdsListCall {
17088	c.urlParams_.Set("sslCompliant", fmt.Sprint(sslCompliant))
17089	return c
17090}
17091
17092// SslRequired sets the optional parameter "sslRequired": Select only
17093// ads that require SSL.
17094func (c *AdsListCall) SslRequired(sslRequired bool) *AdsListCall {
17095	c.urlParams_.Set("sslRequired", fmt.Sprint(sslRequired))
17096	return c
17097}
17098
17099// Type sets the optional parameter "type": Select only ads with these
17100// types.
17101//
17102// Possible values:
17103//   "AD_SERVING_CLICK_TRACKER"
17104//   "AD_SERVING_DEFAULT_AD"
17105//   "AD_SERVING_STANDARD_AD"
17106//   "AD_SERVING_TRACKING"
17107func (c *AdsListCall) Type(type_ ...string) *AdsListCall {
17108	c.urlParams_.SetMulti("type", append([]string{}, type_...))
17109	return c
17110}
17111
17112// Fields allows partial responses to be retrieved. See
17113// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17114// for more information.
17115func (c *AdsListCall) Fields(s ...googleapi.Field) *AdsListCall {
17116	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17117	return c
17118}
17119
17120// IfNoneMatch sets the optional parameter which makes the operation
17121// fail if the object's ETag matches the given value. This is useful for
17122// getting updates only after the object has changed since the last
17123// request. Use googleapi.IsNotModified to check whether the response
17124// error from Do is the result of In-None-Match.
17125func (c *AdsListCall) IfNoneMatch(entityTag string) *AdsListCall {
17126	c.ifNoneMatch_ = entityTag
17127	return c
17128}
17129
17130// Context sets the context to be used in this call's Do method. Any
17131// pending HTTP request will be aborted if the provided context is
17132// canceled.
17133func (c *AdsListCall) Context(ctx context.Context) *AdsListCall {
17134	c.ctx_ = ctx
17135	return c
17136}
17137
17138// Header returns an http.Header that can be modified by the caller to
17139// add HTTP headers to the request.
17140func (c *AdsListCall) Header() http.Header {
17141	if c.header_ == nil {
17142		c.header_ = make(http.Header)
17143	}
17144	return c.header_
17145}
17146
17147func (c *AdsListCall) doRequest(alt string) (*http.Response, error) {
17148	reqHeaders := make(http.Header)
17149	for k, v := range c.header_ {
17150		reqHeaders[k] = v
17151	}
17152	reqHeaders.Set("User-Agent", c.s.userAgent())
17153	if c.ifNoneMatch_ != "" {
17154		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17155	}
17156	var body io.Reader = nil
17157	c.urlParams_.Set("alt", alt)
17158	c.urlParams_.Set("prettyPrint", "false")
17159	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17160	urls += "?" + c.urlParams_.Encode()
17161	req, err := http.NewRequest("GET", urls, body)
17162	if err != nil {
17163		return nil, err
17164	}
17165	req.Header = reqHeaders
17166	googleapi.Expand(req.URL, map[string]string{
17167		"profileId": strconv.FormatInt(c.profileId, 10),
17168	})
17169	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17170}
17171
17172// Do executes the "dfareporting.ads.list" call.
17173// Exactly one of *AdsListResponse or error will be non-nil. Any non-2xx
17174// status code is an error. Response headers are in either
17175// *AdsListResponse.ServerResponse.Header or (if a response was returned
17176// at all) in error.(*googleapi.Error).Header. Use
17177// googleapi.IsNotModified to check whether the returned error was
17178// because http.StatusNotModified was returned.
17179func (c *AdsListCall) Do(opts ...googleapi.CallOption) (*AdsListResponse, error) {
17180	gensupport.SetOptions(c.urlParams_, opts...)
17181	res, err := c.doRequest("json")
17182	if res != nil && res.StatusCode == http.StatusNotModified {
17183		if res.Body != nil {
17184			res.Body.Close()
17185		}
17186		return nil, &googleapi.Error{
17187			Code:   res.StatusCode,
17188			Header: res.Header,
17189		}
17190	}
17191	if err != nil {
17192		return nil, err
17193	}
17194	defer googleapi.CloseBody(res)
17195	if err := googleapi.CheckResponse(res); err != nil {
17196		return nil, err
17197	}
17198	ret := &AdsListResponse{
17199		ServerResponse: googleapi.ServerResponse{
17200			Header:         res.Header,
17201			HTTPStatusCode: res.StatusCode,
17202		},
17203	}
17204	target := &ret
17205	if err := gensupport.DecodeResponse(target, res); err != nil {
17206		return nil, err
17207	}
17208	return ret, nil
17209	// {
17210	//   "description": "Retrieves a list of ads, possibly filtered. This method supports paging.",
17211	//   "httpMethod": "GET",
17212	//   "id": "dfareporting.ads.list",
17213	//   "parameterOrder": [
17214	//     "profileId"
17215	//   ],
17216	//   "parameters": {
17217	//     "active": {
17218	//       "description": "Select only active ads.",
17219	//       "location": "query",
17220	//       "type": "boolean"
17221	//     },
17222	//     "advertiserId": {
17223	//       "description": "Select only ads with this advertiser ID.",
17224	//       "format": "int64",
17225	//       "location": "query",
17226	//       "type": "string"
17227	//     },
17228	//     "archived": {
17229	//       "description": "Select only archived ads.",
17230	//       "location": "query",
17231	//       "type": "boolean"
17232	//     },
17233	//     "audienceSegmentIds": {
17234	//       "description": "Select only ads with these audience segment IDs.",
17235	//       "format": "int64",
17236	//       "location": "query",
17237	//       "repeated": true,
17238	//       "type": "string"
17239	//     },
17240	//     "campaignIds": {
17241	//       "description": "Select only ads with these campaign IDs.",
17242	//       "format": "int64",
17243	//       "location": "query",
17244	//       "repeated": true,
17245	//       "type": "string"
17246	//     },
17247	//     "compatibility": {
17248	//       "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.",
17249	//       "enum": [
17250	//         "APP",
17251	//         "APP_INTERSTITIAL",
17252	//         "DISPLAY",
17253	//         "DISPLAY_INTERSTITIAL",
17254	//         "IN_STREAM_AUDIO",
17255	//         "IN_STREAM_VIDEO"
17256	//       ],
17257	//       "enumDescriptions": [
17258	//         "",
17259	//         "",
17260	//         "",
17261	//         "",
17262	//         "",
17263	//         ""
17264	//       ],
17265	//       "location": "query",
17266	//       "type": "string"
17267	//     },
17268	//     "creativeIds": {
17269	//       "description": "Select only ads with these creative IDs assigned.",
17270	//       "format": "int64",
17271	//       "location": "query",
17272	//       "repeated": true,
17273	//       "type": "string"
17274	//     },
17275	//     "creativeOptimizationConfigurationIds": {
17276	//       "description": "Select only ads with these creative optimization configuration IDs.",
17277	//       "format": "int64",
17278	//       "location": "query",
17279	//       "repeated": true,
17280	//       "type": "string"
17281	//     },
17282	//     "dynamicClickTracker": {
17283	//       "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.",
17284	//       "location": "query",
17285	//       "type": "boolean"
17286	//     },
17287	//     "ids": {
17288	//       "description": "Select only ads with these IDs.",
17289	//       "format": "int64",
17290	//       "location": "query",
17291	//       "repeated": true,
17292	//       "type": "string"
17293	//     },
17294	//     "landingPageIds": {
17295	//       "description": "Select only ads with these landing page IDs.",
17296	//       "format": "int64",
17297	//       "location": "query",
17298	//       "repeated": true,
17299	//       "type": "string"
17300	//     },
17301	//     "maxResults": {
17302	//       "default": "1000",
17303	//       "description": "Maximum number of results to return.",
17304	//       "format": "int32",
17305	//       "location": "query",
17306	//       "maximum": "1000",
17307	//       "minimum": "0",
17308	//       "type": "integer"
17309	//     },
17310	//     "overriddenEventTagId": {
17311	//       "description": "Select only ads with this event tag override ID.",
17312	//       "format": "int64",
17313	//       "location": "query",
17314	//       "type": "string"
17315	//     },
17316	//     "pageToken": {
17317	//       "description": "Value of the nextPageToken from the previous result page.",
17318	//       "location": "query",
17319	//       "type": "string"
17320	//     },
17321	//     "placementIds": {
17322	//       "description": "Select only ads with these placement IDs assigned.",
17323	//       "format": "int64",
17324	//       "location": "query",
17325	//       "repeated": true,
17326	//       "type": "string"
17327	//     },
17328	//     "profileId": {
17329	//       "description": "User profile ID associated with this request.",
17330	//       "format": "int64",
17331	//       "location": "path",
17332	//       "required": true,
17333	//       "type": "string"
17334	//     },
17335	//     "remarketingListIds": {
17336	//       "description": "Select only ads whose list targeting expression use these remarketing list IDs.",
17337	//       "format": "int64",
17338	//       "location": "query",
17339	//       "repeated": true,
17340	//       "type": "string"
17341	//     },
17342	//     "searchString": {
17343	//       "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\".",
17344	//       "location": "query",
17345	//       "type": "string"
17346	//     },
17347	//     "sizeIds": {
17348	//       "description": "Select only ads with these size IDs.",
17349	//       "format": "int64",
17350	//       "location": "query",
17351	//       "repeated": true,
17352	//       "type": "string"
17353	//     },
17354	//     "sortField": {
17355	//       "default": "ID",
17356	//       "description": "Field by which to sort the list.",
17357	//       "enum": [
17358	//         "ID",
17359	//         "NAME"
17360	//       ],
17361	//       "enumDescriptions": [
17362	//         "",
17363	//         ""
17364	//       ],
17365	//       "location": "query",
17366	//       "type": "string"
17367	//     },
17368	//     "sortOrder": {
17369	//       "default": "ASCENDING",
17370	//       "description": "Order of sorted results.",
17371	//       "enum": [
17372	//         "ASCENDING",
17373	//         "DESCENDING"
17374	//       ],
17375	//       "enumDescriptions": [
17376	//         "",
17377	//         ""
17378	//       ],
17379	//       "location": "query",
17380	//       "type": "string"
17381	//     },
17382	//     "sslCompliant": {
17383	//       "description": "Select only ads that are SSL-compliant.",
17384	//       "location": "query",
17385	//       "type": "boolean"
17386	//     },
17387	//     "sslRequired": {
17388	//       "description": "Select only ads that require SSL.",
17389	//       "location": "query",
17390	//       "type": "boolean"
17391	//     },
17392	//     "type": {
17393	//       "description": "Select only ads with these types.",
17394	//       "enum": [
17395	//         "AD_SERVING_CLICK_TRACKER",
17396	//         "AD_SERVING_DEFAULT_AD",
17397	//         "AD_SERVING_STANDARD_AD",
17398	//         "AD_SERVING_TRACKING"
17399	//       ],
17400	//       "enumDescriptions": [
17401	//         "",
17402	//         "",
17403	//         "",
17404	//         ""
17405	//       ],
17406	//       "location": "query",
17407	//       "repeated": true,
17408	//       "type": "string"
17409	//     }
17410	//   },
17411	//   "path": "userprofiles/{profileId}/ads",
17412	//   "response": {
17413	//     "$ref": "AdsListResponse"
17414	//   },
17415	//   "scopes": [
17416	//     "https://www.googleapis.com/auth/dfatrafficking"
17417	//   ]
17418	// }
17419
17420}
17421
17422// Pages invokes f for each page of results.
17423// A non-nil error returned from f will halt the iteration.
17424// The provided context supersedes any context provided to the Context method.
17425func (c *AdsListCall) Pages(ctx context.Context, f func(*AdsListResponse) error) error {
17426	c.ctx_ = ctx
17427	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
17428	for {
17429		x, err := c.Do()
17430		if err != nil {
17431			return err
17432		}
17433		if err := f(x); err != nil {
17434			return err
17435		}
17436		if x.NextPageToken == "" {
17437			return nil
17438		}
17439		c.PageToken(x.NextPageToken)
17440	}
17441}
17442
17443// method id "dfareporting.ads.patch":
17444
17445type AdsPatchCall struct {
17446	s          *Service
17447	profileId  int64
17448	ad         *Ad
17449	urlParams_ gensupport.URLParams
17450	ctx_       context.Context
17451	header_    http.Header
17452}
17453
17454// Patch: Updates an existing ad. This method supports patch semantics.
17455func (r *AdsService) Patch(profileId int64, id int64, ad *Ad) *AdsPatchCall {
17456	c := &AdsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17457	c.profileId = profileId
17458	c.urlParams_.Set("id", fmt.Sprint(id))
17459	c.ad = ad
17460	return c
17461}
17462
17463// Fields allows partial responses to be retrieved. See
17464// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17465// for more information.
17466func (c *AdsPatchCall) Fields(s ...googleapi.Field) *AdsPatchCall {
17467	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17468	return c
17469}
17470
17471// Context sets the context to be used in this call's Do method. Any
17472// pending HTTP request will be aborted if the provided context is
17473// canceled.
17474func (c *AdsPatchCall) Context(ctx context.Context) *AdsPatchCall {
17475	c.ctx_ = ctx
17476	return c
17477}
17478
17479// Header returns an http.Header that can be modified by the caller to
17480// add HTTP headers to the request.
17481func (c *AdsPatchCall) Header() http.Header {
17482	if c.header_ == nil {
17483		c.header_ = make(http.Header)
17484	}
17485	return c.header_
17486}
17487
17488func (c *AdsPatchCall) doRequest(alt string) (*http.Response, error) {
17489	reqHeaders := make(http.Header)
17490	for k, v := range c.header_ {
17491		reqHeaders[k] = v
17492	}
17493	reqHeaders.Set("User-Agent", c.s.userAgent())
17494	var body io.Reader = nil
17495	body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
17496	if err != nil {
17497		return nil, err
17498	}
17499	reqHeaders.Set("Content-Type", "application/json")
17500	c.urlParams_.Set("alt", alt)
17501	c.urlParams_.Set("prettyPrint", "false")
17502	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17503	urls += "?" + c.urlParams_.Encode()
17504	req, err := http.NewRequest("PATCH", urls, body)
17505	if err != nil {
17506		return nil, err
17507	}
17508	req.Header = reqHeaders
17509	googleapi.Expand(req.URL, map[string]string{
17510		"profileId": strconv.FormatInt(c.profileId, 10),
17511	})
17512	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17513}
17514
17515// Do executes the "dfareporting.ads.patch" call.
17516// Exactly one of *Ad or error will be non-nil. Any non-2xx status code
17517// is an error. Response headers are in either *Ad.ServerResponse.Header
17518// or (if a response was returned at all) in
17519// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
17520// whether the returned error was because http.StatusNotModified was
17521// returned.
17522func (c *AdsPatchCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
17523	gensupport.SetOptions(c.urlParams_, opts...)
17524	res, err := c.doRequest("json")
17525	if res != nil && res.StatusCode == http.StatusNotModified {
17526		if res.Body != nil {
17527			res.Body.Close()
17528		}
17529		return nil, &googleapi.Error{
17530			Code:   res.StatusCode,
17531			Header: res.Header,
17532		}
17533	}
17534	if err != nil {
17535		return nil, err
17536	}
17537	defer googleapi.CloseBody(res)
17538	if err := googleapi.CheckResponse(res); err != nil {
17539		return nil, err
17540	}
17541	ret := &Ad{
17542		ServerResponse: googleapi.ServerResponse{
17543			Header:         res.Header,
17544			HTTPStatusCode: res.StatusCode,
17545		},
17546	}
17547	target := &ret
17548	if err := gensupport.DecodeResponse(target, res); err != nil {
17549		return nil, err
17550	}
17551	return ret, nil
17552	// {
17553	//   "description": "Updates an existing ad. This method supports patch semantics.",
17554	//   "httpMethod": "PATCH",
17555	//   "id": "dfareporting.ads.patch",
17556	//   "parameterOrder": [
17557	//     "profileId",
17558	//     "id"
17559	//   ],
17560	//   "parameters": {
17561	//     "id": {
17562	//       "description": "Ad ID.",
17563	//       "format": "int64",
17564	//       "location": "query",
17565	//       "required": true,
17566	//       "type": "string"
17567	//     },
17568	//     "profileId": {
17569	//       "description": "User profile ID associated with this request.",
17570	//       "format": "int64",
17571	//       "location": "path",
17572	//       "required": true,
17573	//       "type": "string"
17574	//     }
17575	//   },
17576	//   "path": "userprofiles/{profileId}/ads",
17577	//   "request": {
17578	//     "$ref": "Ad"
17579	//   },
17580	//   "response": {
17581	//     "$ref": "Ad"
17582	//   },
17583	//   "scopes": [
17584	//     "https://www.googleapis.com/auth/dfatrafficking"
17585	//   ]
17586	// }
17587
17588}
17589
17590// method id "dfareporting.ads.update":
17591
17592type AdsUpdateCall struct {
17593	s          *Service
17594	profileId  int64
17595	ad         *Ad
17596	urlParams_ gensupport.URLParams
17597	ctx_       context.Context
17598	header_    http.Header
17599}
17600
17601// Update: Updates an existing ad.
17602func (r *AdsService) Update(profileId int64, ad *Ad) *AdsUpdateCall {
17603	c := &AdsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17604	c.profileId = profileId
17605	c.ad = ad
17606	return c
17607}
17608
17609// Fields allows partial responses to be retrieved. See
17610// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17611// for more information.
17612func (c *AdsUpdateCall) Fields(s ...googleapi.Field) *AdsUpdateCall {
17613	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17614	return c
17615}
17616
17617// Context sets the context to be used in this call's Do method. Any
17618// pending HTTP request will be aborted if the provided context is
17619// canceled.
17620func (c *AdsUpdateCall) Context(ctx context.Context) *AdsUpdateCall {
17621	c.ctx_ = ctx
17622	return c
17623}
17624
17625// Header returns an http.Header that can be modified by the caller to
17626// add HTTP headers to the request.
17627func (c *AdsUpdateCall) Header() http.Header {
17628	if c.header_ == nil {
17629		c.header_ = make(http.Header)
17630	}
17631	return c.header_
17632}
17633
17634func (c *AdsUpdateCall) doRequest(alt string) (*http.Response, error) {
17635	reqHeaders := make(http.Header)
17636	for k, v := range c.header_ {
17637		reqHeaders[k] = v
17638	}
17639	reqHeaders.Set("User-Agent", c.s.userAgent())
17640	var body io.Reader = nil
17641	body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
17642	if err != nil {
17643		return nil, err
17644	}
17645	reqHeaders.Set("Content-Type", "application/json")
17646	c.urlParams_.Set("alt", alt)
17647	c.urlParams_.Set("prettyPrint", "false")
17648	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17649	urls += "?" + c.urlParams_.Encode()
17650	req, err := http.NewRequest("PUT", urls, body)
17651	if err != nil {
17652		return nil, err
17653	}
17654	req.Header = reqHeaders
17655	googleapi.Expand(req.URL, map[string]string{
17656		"profileId": strconv.FormatInt(c.profileId, 10),
17657	})
17658	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17659}
17660
17661// Do executes the "dfareporting.ads.update" call.
17662// Exactly one of *Ad or error will be non-nil. Any non-2xx status code
17663// is an error. Response headers are in either *Ad.ServerResponse.Header
17664// or (if a response was returned at all) in
17665// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
17666// whether the returned error was because http.StatusNotModified was
17667// returned.
17668func (c *AdsUpdateCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
17669	gensupport.SetOptions(c.urlParams_, opts...)
17670	res, err := c.doRequest("json")
17671	if res != nil && res.StatusCode == http.StatusNotModified {
17672		if res.Body != nil {
17673			res.Body.Close()
17674		}
17675		return nil, &googleapi.Error{
17676			Code:   res.StatusCode,
17677			Header: res.Header,
17678		}
17679	}
17680	if err != nil {
17681		return nil, err
17682	}
17683	defer googleapi.CloseBody(res)
17684	if err := googleapi.CheckResponse(res); err != nil {
17685		return nil, err
17686	}
17687	ret := &Ad{
17688		ServerResponse: googleapi.ServerResponse{
17689			Header:         res.Header,
17690			HTTPStatusCode: res.StatusCode,
17691		},
17692	}
17693	target := &ret
17694	if err := gensupport.DecodeResponse(target, res); err != nil {
17695		return nil, err
17696	}
17697	return ret, nil
17698	// {
17699	//   "description": "Updates an existing ad.",
17700	//   "httpMethod": "PUT",
17701	//   "id": "dfareporting.ads.update",
17702	//   "parameterOrder": [
17703	//     "profileId"
17704	//   ],
17705	//   "parameters": {
17706	//     "profileId": {
17707	//       "description": "User profile ID associated with this request.",
17708	//       "format": "int64",
17709	//       "location": "path",
17710	//       "required": true,
17711	//       "type": "string"
17712	//     }
17713	//   },
17714	//   "path": "userprofiles/{profileId}/ads",
17715	//   "request": {
17716	//     "$ref": "Ad"
17717	//   },
17718	//   "response": {
17719	//     "$ref": "Ad"
17720	//   },
17721	//   "scopes": [
17722	//     "https://www.googleapis.com/auth/dfatrafficking"
17723	//   ]
17724	// }
17725
17726}
17727
17728// method id "dfareporting.advertiserGroups.delete":
17729
17730type AdvertiserGroupsDeleteCall struct {
17731	s          *Service
17732	profileId  int64
17733	id         int64
17734	urlParams_ gensupport.URLParams
17735	ctx_       context.Context
17736	header_    http.Header
17737}
17738
17739// Delete: Deletes an existing advertiser group.
17740func (r *AdvertiserGroupsService) Delete(profileId int64, id int64) *AdvertiserGroupsDeleteCall {
17741	c := &AdvertiserGroupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17742	c.profileId = profileId
17743	c.id = id
17744	return c
17745}
17746
17747// Fields allows partial responses to be retrieved. See
17748// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17749// for more information.
17750func (c *AdvertiserGroupsDeleteCall) Fields(s ...googleapi.Field) *AdvertiserGroupsDeleteCall {
17751	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17752	return c
17753}
17754
17755// Context sets the context to be used in this call's Do method. Any
17756// pending HTTP request will be aborted if the provided context is
17757// canceled.
17758func (c *AdvertiserGroupsDeleteCall) Context(ctx context.Context) *AdvertiserGroupsDeleteCall {
17759	c.ctx_ = ctx
17760	return c
17761}
17762
17763// Header returns an http.Header that can be modified by the caller to
17764// add HTTP headers to the request.
17765func (c *AdvertiserGroupsDeleteCall) Header() http.Header {
17766	if c.header_ == nil {
17767		c.header_ = make(http.Header)
17768	}
17769	return c.header_
17770}
17771
17772func (c *AdvertiserGroupsDeleteCall) doRequest(alt string) (*http.Response, error) {
17773	reqHeaders := make(http.Header)
17774	for k, v := range c.header_ {
17775		reqHeaders[k] = v
17776	}
17777	reqHeaders.Set("User-Agent", c.s.userAgent())
17778	var body io.Reader = nil
17779	c.urlParams_.Set("alt", alt)
17780	c.urlParams_.Set("prettyPrint", "false")
17781	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups/{id}")
17782	urls += "?" + c.urlParams_.Encode()
17783	req, err := http.NewRequest("DELETE", urls, body)
17784	if err != nil {
17785		return nil, err
17786	}
17787	req.Header = reqHeaders
17788	googleapi.Expand(req.URL, map[string]string{
17789		"profileId": strconv.FormatInt(c.profileId, 10),
17790		"id":        strconv.FormatInt(c.id, 10),
17791	})
17792	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17793}
17794
17795// Do executes the "dfareporting.advertiserGroups.delete" call.
17796func (c *AdvertiserGroupsDeleteCall) Do(opts ...googleapi.CallOption) error {
17797	gensupport.SetOptions(c.urlParams_, opts...)
17798	res, err := c.doRequest("json")
17799	if err != nil {
17800		return err
17801	}
17802	defer googleapi.CloseBody(res)
17803	if err := googleapi.CheckResponse(res); err != nil {
17804		return err
17805	}
17806	return nil
17807	// {
17808	//   "description": "Deletes an existing advertiser group.",
17809	//   "httpMethod": "DELETE",
17810	//   "id": "dfareporting.advertiserGroups.delete",
17811	//   "parameterOrder": [
17812	//     "profileId",
17813	//     "id"
17814	//   ],
17815	//   "parameters": {
17816	//     "id": {
17817	//       "description": "Advertiser group ID.",
17818	//       "format": "int64",
17819	//       "location": "path",
17820	//       "required": true,
17821	//       "type": "string"
17822	//     },
17823	//     "profileId": {
17824	//       "description": "User profile ID associated with this request.",
17825	//       "format": "int64",
17826	//       "location": "path",
17827	//       "required": true,
17828	//       "type": "string"
17829	//     }
17830	//   },
17831	//   "path": "userprofiles/{profileId}/advertiserGroups/{id}",
17832	//   "scopes": [
17833	//     "https://www.googleapis.com/auth/dfatrafficking"
17834	//   ]
17835	// }
17836
17837}
17838
17839// method id "dfareporting.advertiserGroups.get":
17840
17841type AdvertiserGroupsGetCall struct {
17842	s            *Service
17843	profileId    int64
17844	id           int64
17845	urlParams_   gensupport.URLParams
17846	ifNoneMatch_ string
17847	ctx_         context.Context
17848	header_      http.Header
17849}
17850
17851// Get: Gets one advertiser group by ID.
17852func (r *AdvertiserGroupsService) Get(profileId int64, id int64) *AdvertiserGroupsGetCall {
17853	c := &AdvertiserGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17854	c.profileId = profileId
17855	c.id = id
17856	return c
17857}
17858
17859// Fields allows partial responses to be retrieved. See
17860// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17861// for more information.
17862func (c *AdvertiserGroupsGetCall) Fields(s ...googleapi.Field) *AdvertiserGroupsGetCall {
17863	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17864	return c
17865}
17866
17867// IfNoneMatch sets the optional parameter which makes the operation
17868// fail if the object's ETag matches the given value. This is useful for
17869// getting updates only after the object has changed since the last
17870// request. Use googleapi.IsNotModified to check whether the response
17871// error from Do is the result of In-None-Match.
17872func (c *AdvertiserGroupsGetCall) IfNoneMatch(entityTag string) *AdvertiserGroupsGetCall {
17873	c.ifNoneMatch_ = entityTag
17874	return c
17875}
17876
17877// Context sets the context to be used in this call's Do method. Any
17878// pending HTTP request will be aborted if the provided context is
17879// canceled.
17880func (c *AdvertiserGroupsGetCall) Context(ctx context.Context) *AdvertiserGroupsGetCall {
17881	c.ctx_ = ctx
17882	return c
17883}
17884
17885// Header returns an http.Header that can be modified by the caller to
17886// add HTTP headers to the request.
17887func (c *AdvertiserGroupsGetCall) Header() http.Header {
17888	if c.header_ == nil {
17889		c.header_ = make(http.Header)
17890	}
17891	return c.header_
17892}
17893
17894func (c *AdvertiserGroupsGetCall) doRequest(alt string) (*http.Response, error) {
17895	reqHeaders := make(http.Header)
17896	for k, v := range c.header_ {
17897		reqHeaders[k] = v
17898	}
17899	reqHeaders.Set("User-Agent", c.s.userAgent())
17900	if c.ifNoneMatch_ != "" {
17901		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17902	}
17903	var body io.Reader = nil
17904	c.urlParams_.Set("alt", alt)
17905	c.urlParams_.Set("prettyPrint", "false")
17906	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups/{id}")
17907	urls += "?" + c.urlParams_.Encode()
17908	req, err := http.NewRequest("GET", urls, body)
17909	if err != nil {
17910		return nil, err
17911	}
17912	req.Header = reqHeaders
17913	googleapi.Expand(req.URL, map[string]string{
17914		"profileId": strconv.FormatInt(c.profileId, 10),
17915		"id":        strconv.FormatInt(c.id, 10),
17916	})
17917	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17918}
17919
17920// Do executes the "dfareporting.advertiserGroups.get" call.
17921// Exactly one of *AdvertiserGroup or error will be non-nil. Any non-2xx
17922// status code is an error. Response headers are in either
17923// *AdvertiserGroup.ServerResponse.Header or (if a response was returned
17924// at all) in error.(*googleapi.Error).Header. Use
17925// googleapi.IsNotModified to check whether the returned error was
17926// because http.StatusNotModified was returned.
17927func (c *AdvertiserGroupsGetCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
17928	gensupport.SetOptions(c.urlParams_, opts...)
17929	res, err := c.doRequest("json")
17930	if res != nil && res.StatusCode == http.StatusNotModified {
17931		if res.Body != nil {
17932			res.Body.Close()
17933		}
17934		return nil, &googleapi.Error{
17935			Code:   res.StatusCode,
17936			Header: res.Header,
17937		}
17938	}
17939	if err != nil {
17940		return nil, err
17941	}
17942	defer googleapi.CloseBody(res)
17943	if err := googleapi.CheckResponse(res); err != nil {
17944		return nil, err
17945	}
17946	ret := &AdvertiserGroup{
17947		ServerResponse: googleapi.ServerResponse{
17948			Header:         res.Header,
17949			HTTPStatusCode: res.StatusCode,
17950		},
17951	}
17952	target := &ret
17953	if err := gensupport.DecodeResponse(target, res); err != nil {
17954		return nil, err
17955	}
17956	return ret, nil
17957	// {
17958	//   "description": "Gets one advertiser group by ID.",
17959	//   "httpMethod": "GET",
17960	//   "id": "dfareporting.advertiserGroups.get",
17961	//   "parameterOrder": [
17962	//     "profileId",
17963	//     "id"
17964	//   ],
17965	//   "parameters": {
17966	//     "id": {
17967	//       "description": "Advertiser group ID.",
17968	//       "format": "int64",
17969	//       "location": "path",
17970	//       "required": true,
17971	//       "type": "string"
17972	//     },
17973	//     "profileId": {
17974	//       "description": "User profile ID associated with this request.",
17975	//       "format": "int64",
17976	//       "location": "path",
17977	//       "required": true,
17978	//       "type": "string"
17979	//     }
17980	//   },
17981	//   "path": "userprofiles/{profileId}/advertiserGroups/{id}",
17982	//   "response": {
17983	//     "$ref": "AdvertiserGroup"
17984	//   },
17985	//   "scopes": [
17986	//     "https://www.googleapis.com/auth/dfatrafficking"
17987	//   ]
17988	// }
17989
17990}
17991
17992// method id "dfareporting.advertiserGroups.insert":
17993
17994type AdvertiserGroupsInsertCall struct {
17995	s               *Service
17996	profileId       int64
17997	advertisergroup *AdvertiserGroup
17998	urlParams_      gensupport.URLParams
17999	ctx_            context.Context
18000	header_         http.Header
18001}
18002
18003// Insert: Inserts a new advertiser group.
18004func (r *AdvertiserGroupsService) Insert(profileId int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsInsertCall {
18005	c := &AdvertiserGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18006	c.profileId = profileId
18007	c.advertisergroup = advertisergroup
18008	return c
18009}
18010
18011// Fields allows partial responses to be retrieved. See
18012// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18013// for more information.
18014func (c *AdvertiserGroupsInsertCall) Fields(s ...googleapi.Field) *AdvertiserGroupsInsertCall {
18015	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18016	return c
18017}
18018
18019// Context sets the context to be used in this call's Do method. Any
18020// pending HTTP request will be aborted if the provided context is
18021// canceled.
18022func (c *AdvertiserGroupsInsertCall) Context(ctx context.Context) *AdvertiserGroupsInsertCall {
18023	c.ctx_ = ctx
18024	return c
18025}
18026
18027// Header returns an http.Header that can be modified by the caller to
18028// add HTTP headers to the request.
18029func (c *AdvertiserGroupsInsertCall) Header() http.Header {
18030	if c.header_ == nil {
18031		c.header_ = make(http.Header)
18032	}
18033	return c.header_
18034}
18035
18036func (c *AdvertiserGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
18037	reqHeaders := make(http.Header)
18038	for k, v := range c.header_ {
18039		reqHeaders[k] = v
18040	}
18041	reqHeaders.Set("User-Agent", c.s.userAgent())
18042	var body io.Reader = nil
18043	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18044	if err != nil {
18045		return nil, err
18046	}
18047	reqHeaders.Set("Content-Type", "application/json")
18048	c.urlParams_.Set("alt", alt)
18049	c.urlParams_.Set("prettyPrint", "false")
18050	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18051	urls += "?" + c.urlParams_.Encode()
18052	req, err := http.NewRequest("POST", urls, body)
18053	if err != nil {
18054		return nil, err
18055	}
18056	req.Header = reqHeaders
18057	googleapi.Expand(req.URL, map[string]string{
18058		"profileId": strconv.FormatInt(c.profileId, 10),
18059	})
18060	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18061}
18062
18063// Do executes the "dfareporting.advertiserGroups.insert" call.
18064// Exactly one of *AdvertiserGroup or error will be non-nil. Any non-2xx
18065// status code is an error. Response headers are in either
18066// *AdvertiserGroup.ServerResponse.Header or (if a response was returned
18067// at all) in error.(*googleapi.Error).Header. Use
18068// googleapi.IsNotModified to check whether the returned error was
18069// because http.StatusNotModified was returned.
18070func (c *AdvertiserGroupsInsertCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18071	gensupport.SetOptions(c.urlParams_, opts...)
18072	res, err := c.doRequest("json")
18073	if res != nil && res.StatusCode == http.StatusNotModified {
18074		if res.Body != nil {
18075			res.Body.Close()
18076		}
18077		return nil, &googleapi.Error{
18078			Code:   res.StatusCode,
18079			Header: res.Header,
18080		}
18081	}
18082	if err != nil {
18083		return nil, err
18084	}
18085	defer googleapi.CloseBody(res)
18086	if err := googleapi.CheckResponse(res); err != nil {
18087		return nil, err
18088	}
18089	ret := &AdvertiserGroup{
18090		ServerResponse: googleapi.ServerResponse{
18091			Header:         res.Header,
18092			HTTPStatusCode: res.StatusCode,
18093		},
18094	}
18095	target := &ret
18096	if err := gensupport.DecodeResponse(target, res); err != nil {
18097		return nil, err
18098	}
18099	return ret, nil
18100	// {
18101	//   "description": "Inserts a new advertiser group.",
18102	//   "httpMethod": "POST",
18103	//   "id": "dfareporting.advertiserGroups.insert",
18104	//   "parameterOrder": [
18105	//     "profileId"
18106	//   ],
18107	//   "parameters": {
18108	//     "profileId": {
18109	//       "description": "User profile ID associated with this request.",
18110	//       "format": "int64",
18111	//       "location": "path",
18112	//       "required": true,
18113	//       "type": "string"
18114	//     }
18115	//   },
18116	//   "path": "userprofiles/{profileId}/advertiserGroups",
18117	//   "request": {
18118	//     "$ref": "AdvertiserGroup"
18119	//   },
18120	//   "response": {
18121	//     "$ref": "AdvertiserGroup"
18122	//   },
18123	//   "scopes": [
18124	//     "https://www.googleapis.com/auth/dfatrafficking"
18125	//   ]
18126	// }
18127
18128}
18129
18130// method id "dfareporting.advertiserGroups.list":
18131
18132type AdvertiserGroupsListCall struct {
18133	s            *Service
18134	profileId    int64
18135	urlParams_   gensupport.URLParams
18136	ifNoneMatch_ string
18137	ctx_         context.Context
18138	header_      http.Header
18139}
18140
18141// List: Retrieves a list of advertiser groups, possibly filtered. This
18142// method supports paging.
18143func (r *AdvertiserGroupsService) List(profileId int64) *AdvertiserGroupsListCall {
18144	c := &AdvertiserGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18145	c.profileId = profileId
18146	return c
18147}
18148
18149// Ids sets the optional parameter "ids": Select only advertiser groups
18150// with these IDs.
18151func (c *AdvertiserGroupsListCall) Ids(ids ...int64) *AdvertiserGroupsListCall {
18152	var ids_ []string
18153	for _, v := range ids {
18154		ids_ = append(ids_, fmt.Sprint(v))
18155	}
18156	c.urlParams_.SetMulti("ids", ids_)
18157	return c
18158}
18159
18160// MaxResults sets the optional parameter "maxResults": Maximum number
18161// of results to return.
18162func (c *AdvertiserGroupsListCall) MaxResults(maxResults int64) *AdvertiserGroupsListCall {
18163	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
18164	return c
18165}
18166
18167// PageToken sets the optional parameter "pageToken": Value of the
18168// nextPageToken from the previous result page.
18169func (c *AdvertiserGroupsListCall) PageToken(pageToken string) *AdvertiserGroupsListCall {
18170	c.urlParams_.Set("pageToken", pageToken)
18171	return c
18172}
18173
18174// SearchString sets the optional parameter "searchString": Allows
18175// searching for objects by name or ID. Wildcards (*) are allowed. For
18176// example, "advertiser*2015" will return objects with names like
18177// "advertiser group June 2015", "advertiser group April 2015", or
18178// simply "advertiser group 2015". Most of the searches also add
18179// wildcards implicitly at the start and the end of the search string.
18180// For example, a search string of "advertisergroup" will match objects
18181// with name "my advertisergroup", "advertisergroup 2015", or simply
18182// "advertisergroup".
18183func (c *AdvertiserGroupsListCall) SearchString(searchString string) *AdvertiserGroupsListCall {
18184	c.urlParams_.Set("searchString", searchString)
18185	return c
18186}
18187
18188// SortField sets the optional parameter "sortField": Field by which to
18189// sort the list.
18190//
18191// Possible values:
18192//   "ID" (default)
18193//   "NAME"
18194func (c *AdvertiserGroupsListCall) SortField(sortField string) *AdvertiserGroupsListCall {
18195	c.urlParams_.Set("sortField", sortField)
18196	return c
18197}
18198
18199// SortOrder sets the optional parameter "sortOrder": Order of sorted
18200// results.
18201//
18202// Possible values:
18203//   "ASCENDING" (default)
18204//   "DESCENDING"
18205func (c *AdvertiserGroupsListCall) SortOrder(sortOrder string) *AdvertiserGroupsListCall {
18206	c.urlParams_.Set("sortOrder", sortOrder)
18207	return c
18208}
18209
18210// Fields allows partial responses to be retrieved. See
18211// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18212// for more information.
18213func (c *AdvertiserGroupsListCall) Fields(s ...googleapi.Field) *AdvertiserGroupsListCall {
18214	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18215	return c
18216}
18217
18218// IfNoneMatch sets the optional parameter which makes the operation
18219// fail if the object's ETag matches the given value. This is useful for
18220// getting updates only after the object has changed since the last
18221// request. Use googleapi.IsNotModified to check whether the response
18222// error from Do is the result of In-None-Match.
18223func (c *AdvertiserGroupsListCall) IfNoneMatch(entityTag string) *AdvertiserGroupsListCall {
18224	c.ifNoneMatch_ = entityTag
18225	return c
18226}
18227
18228// Context sets the context to be used in this call's Do method. Any
18229// pending HTTP request will be aborted if the provided context is
18230// canceled.
18231func (c *AdvertiserGroupsListCall) Context(ctx context.Context) *AdvertiserGroupsListCall {
18232	c.ctx_ = ctx
18233	return c
18234}
18235
18236// Header returns an http.Header that can be modified by the caller to
18237// add HTTP headers to the request.
18238func (c *AdvertiserGroupsListCall) Header() http.Header {
18239	if c.header_ == nil {
18240		c.header_ = make(http.Header)
18241	}
18242	return c.header_
18243}
18244
18245func (c *AdvertiserGroupsListCall) doRequest(alt string) (*http.Response, error) {
18246	reqHeaders := make(http.Header)
18247	for k, v := range c.header_ {
18248		reqHeaders[k] = v
18249	}
18250	reqHeaders.Set("User-Agent", c.s.userAgent())
18251	if c.ifNoneMatch_ != "" {
18252		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18253	}
18254	var body io.Reader = nil
18255	c.urlParams_.Set("alt", alt)
18256	c.urlParams_.Set("prettyPrint", "false")
18257	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18258	urls += "?" + c.urlParams_.Encode()
18259	req, err := http.NewRequest("GET", urls, body)
18260	if err != nil {
18261		return nil, err
18262	}
18263	req.Header = reqHeaders
18264	googleapi.Expand(req.URL, map[string]string{
18265		"profileId": strconv.FormatInt(c.profileId, 10),
18266	})
18267	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18268}
18269
18270// Do executes the "dfareporting.advertiserGroups.list" call.
18271// Exactly one of *AdvertiserGroupsListResponse or error will be
18272// non-nil. Any non-2xx status code is an error. Response headers are in
18273// either *AdvertiserGroupsListResponse.ServerResponse.Header or (if a
18274// response was returned at all) in error.(*googleapi.Error).Header. Use
18275// googleapi.IsNotModified to check whether the returned error was
18276// because http.StatusNotModified was returned.
18277func (c *AdvertiserGroupsListCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroupsListResponse, error) {
18278	gensupport.SetOptions(c.urlParams_, opts...)
18279	res, err := c.doRequest("json")
18280	if res != nil && res.StatusCode == http.StatusNotModified {
18281		if res.Body != nil {
18282			res.Body.Close()
18283		}
18284		return nil, &googleapi.Error{
18285			Code:   res.StatusCode,
18286			Header: res.Header,
18287		}
18288	}
18289	if err != nil {
18290		return nil, err
18291	}
18292	defer googleapi.CloseBody(res)
18293	if err := googleapi.CheckResponse(res); err != nil {
18294		return nil, err
18295	}
18296	ret := &AdvertiserGroupsListResponse{
18297		ServerResponse: googleapi.ServerResponse{
18298			Header:         res.Header,
18299			HTTPStatusCode: res.StatusCode,
18300		},
18301	}
18302	target := &ret
18303	if err := gensupport.DecodeResponse(target, res); err != nil {
18304		return nil, err
18305	}
18306	return ret, nil
18307	// {
18308	//   "description": "Retrieves a list of advertiser groups, possibly filtered. This method supports paging.",
18309	//   "httpMethod": "GET",
18310	//   "id": "dfareporting.advertiserGroups.list",
18311	//   "parameterOrder": [
18312	//     "profileId"
18313	//   ],
18314	//   "parameters": {
18315	//     "ids": {
18316	//       "description": "Select only advertiser groups with these IDs.",
18317	//       "format": "int64",
18318	//       "location": "query",
18319	//       "repeated": true,
18320	//       "type": "string"
18321	//     },
18322	//     "maxResults": {
18323	//       "default": "1000",
18324	//       "description": "Maximum number of results to return.",
18325	//       "format": "int32",
18326	//       "location": "query",
18327	//       "maximum": "1000",
18328	//       "minimum": "0",
18329	//       "type": "integer"
18330	//     },
18331	//     "pageToken": {
18332	//       "description": "Value of the nextPageToken from the previous result page.",
18333	//       "location": "query",
18334	//       "type": "string"
18335	//     },
18336	//     "profileId": {
18337	//       "description": "User profile ID associated with this request.",
18338	//       "format": "int64",
18339	//       "location": "path",
18340	//       "required": true,
18341	//       "type": "string"
18342	//     },
18343	//     "searchString": {
18344	//       "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\".",
18345	//       "location": "query",
18346	//       "type": "string"
18347	//     },
18348	//     "sortField": {
18349	//       "default": "ID",
18350	//       "description": "Field by which to sort the list.",
18351	//       "enum": [
18352	//         "ID",
18353	//         "NAME"
18354	//       ],
18355	//       "enumDescriptions": [
18356	//         "",
18357	//         ""
18358	//       ],
18359	//       "location": "query",
18360	//       "type": "string"
18361	//     },
18362	//     "sortOrder": {
18363	//       "default": "ASCENDING",
18364	//       "description": "Order of sorted results.",
18365	//       "enum": [
18366	//         "ASCENDING",
18367	//         "DESCENDING"
18368	//       ],
18369	//       "enumDescriptions": [
18370	//         "",
18371	//         ""
18372	//       ],
18373	//       "location": "query",
18374	//       "type": "string"
18375	//     }
18376	//   },
18377	//   "path": "userprofiles/{profileId}/advertiserGroups",
18378	//   "response": {
18379	//     "$ref": "AdvertiserGroupsListResponse"
18380	//   },
18381	//   "scopes": [
18382	//     "https://www.googleapis.com/auth/dfatrafficking"
18383	//   ]
18384	// }
18385
18386}
18387
18388// Pages invokes f for each page of results.
18389// A non-nil error returned from f will halt the iteration.
18390// The provided context supersedes any context provided to the Context method.
18391func (c *AdvertiserGroupsListCall) Pages(ctx context.Context, f func(*AdvertiserGroupsListResponse) error) error {
18392	c.ctx_ = ctx
18393	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
18394	for {
18395		x, err := c.Do()
18396		if err != nil {
18397			return err
18398		}
18399		if err := f(x); err != nil {
18400			return err
18401		}
18402		if x.NextPageToken == "" {
18403			return nil
18404		}
18405		c.PageToken(x.NextPageToken)
18406	}
18407}
18408
18409// method id "dfareporting.advertiserGroups.patch":
18410
18411type AdvertiserGroupsPatchCall struct {
18412	s               *Service
18413	profileId       int64
18414	advertisergroup *AdvertiserGroup
18415	urlParams_      gensupport.URLParams
18416	ctx_            context.Context
18417	header_         http.Header
18418}
18419
18420// Patch: Updates an existing advertiser group. This method supports
18421// patch semantics.
18422func (r *AdvertiserGroupsService) Patch(profileId int64, id int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsPatchCall {
18423	c := &AdvertiserGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18424	c.profileId = profileId
18425	c.urlParams_.Set("id", fmt.Sprint(id))
18426	c.advertisergroup = advertisergroup
18427	return c
18428}
18429
18430// Fields allows partial responses to be retrieved. See
18431// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18432// for more information.
18433func (c *AdvertiserGroupsPatchCall) Fields(s ...googleapi.Field) *AdvertiserGroupsPatchCall {
18434	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18435	return c
18436}
18437
18438// Context sets the context to be used in this call's Do method. Any
18439// pending HTTP request will be aborted if the provided context is
18440// canceled.
18441func (c *AdvertiserGroupsPatchCall) Context(ctx context.Context) *AdvertiserGroupsPatchCall {
18442	c.ctx_ = ctx
18443	return c
18444}
18445
18446// Header returns an http.Header that can be modified by the caller to
18447// add HTTP headers to the request.
18448func (c *AdvertiserGroupsPatchCall) Header() http.Header {
18449	if c.header_ == nil {
18450		c.header_ = make(http.Header)
18451	}
18452	return c.header_
18453}
18454
18455func (c *AdvertiserGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
18456	reqHeaders := make(http.Header)
18457	for k, v := range c.header_ {
18458		reqHeaders[k] = v
18459	}
18460	reqHeaders.Set("User-Agent", c.s.userAgent())
18461	var body io.Reader = nil
18462	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18463	if err != nil {
18464		return nil, err
18465	}
18466	reqHeaders.Set("Content-Type", "application/json")
18467	c.urlParams_.Set("alt", alt)
18468	c.urlParams_.Set("prettyPrint", "false")
18469	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18470	urls += "?" + c.urlParams_.Encode()
18471	req, err := http.NewRequest("PATCH", urls, body)
18472	if err != nil {
18473		return nil, err
18474	}
18475	req.Header = reqHeaders
18476	googleapi.Expand(req.URL, map[string]string{
18477		"profileId": strconv.FormatInt(c.profileId, 10),
18478	})
18479	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18480}
18481
18482// Do executes the "dfareporting.advertiserGroups.patch" call.
18483// Exactly one of *AdvertiserGroup or error will be non-nil. Any non-2xx
18484// status code is an error. Response headers are in either
18485// *AdvertiserGroup.ServerResponse.Header or (if a response was returned
18486// at all) in error.(*googleapi.Error).Header. Use
18487// googleapi.IsNotModified to check whether the returned error was
18488// because http.StatusNotModified was returned.
18489func (c *AdvertiserGroupsPatchCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18490	gensupport.SetOptions(c.urlParams_, opts...)
18491	res, err := c.doRequest("json")
18492	if res != nil && res.StatusCode == http.StatusNotModified {
18493		if res.Body != nil {
18494			res.Body.Close()
18495		}
18496		return nil, &googleapi.Error{
18497			Code:   res.StatusCode,
18498			Header: res.Header,
18499		}
18500	}
18501	if err != nil {
18502		return nil, err
18503	}
18504	defer googleapi.CloseBody(res)
18505	if err := googleapi.CheckResponse(res); err != nil {
18506		return nil, err
18507	}
18508	ret := &AdvertiserGroup{
18509		ServerResponse: googleapi.ServerResponse{
18510			Header:         res.Header,
18511			HTTPStatusCode: res.StatusCode,
18512		},
18513	}
18514	target := &ret
18515	if err := gensupport.DecodeResponse(target, res); err != nil {
18516		return nil, err
18517	}
18518	return ret, nil
18519	// {
18520	//   "description": "Updates an existing advertiser group. This method supports patch semantics.",
18521	//   "httpMethod": "PATCH",
18522	//   "id": "dfareporting.advertiserGroups.patch",
18523	//   "parameterOrder": [
18524	//     "profileId",
18525	//     "id"
18526	//   ],
18527	//   "parameters": {
18528	//     "id": {
18529	//       "description": "Advertiser group ID.",
18530	//       "format": "int64",
18531	//       "location": "query",
18532	//       "required": true,
18533	//       "type": "string"
18534	//     },
18535	//     "profileId": {
18536	//       "description": "User profile ID associated with this request.",
18537	//       "format": "int64",
18538	//       "location": "path",
18539	//       "required": true,
18540	//       "type": "string"
18541	//     }
18542	//   },
18543	//   "path": "userprofiles/{profileId}/advertiserGroups",
18544	//   "request": {
18545	//     "$ref": "AdvertiserGroup"
18546	//   },
18547	//   "response": {
18548	//     "$ref": "AdvertiserGroup"
18549	//   },
18550	//   "scopes": [
18551	//     "https://www.googleapis.com/auth/dfatrafficking"
18552	//   ]
18553	// }
18554
18555}
18556
18557// method id "dfareporting.advertiserGroups.update":
18558
18559type AdvertiserGroupsUpdateCall struct {
18560	s               *Service
18561	profileId       int64
18562	advertisergroup *AdvertiserGroup
18563	urlParams_      gensupport.URLParams
18564	ctx_            context.Context
18565	header_         http.Header
18566}
18567
18568// Update: Updates an existing advertiser group.
18569func (r *AdvertiserGroupsService) Update(profileId int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsUpdateCall {
18570	c := &AdvertiserGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18571	c.profileId = profileId
18572	c.advertisergroup = advertisergroup
18573	return c
18574}
18575
18576// Fields allows partial responses to be retrieved. See
18577// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18578// for more information.
18579func (c *AdvertiserGroupsUpdateCall) Fields(s ...googleapi.Field) *AdvertiserGroupsUpdateCall {
18580	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18581	return c
18582}
18583
18584// Context sets the context to be used in this call's Do method. Any
18585// pending HTTP request will be aborted if the provided context is
18586// canceled.
18587func (c *AdvertiserGroupsUpdateCall) Context(ctx context.Context) *AdvertiserGroupsUpdateCall {
18588	c.ctx_ = ctx
18589	return c
18590}
18591
18592// Header returns an http.Header that can be modified by the caller to
18593// add HTTP headers to the request.
18594func (c *AdvertiserGroupsUpdateCall) Header() http.Header {
18595	if c.header_ == nil {
18596		c.header_ = make(http.Header)
18597	}
18598	return c.header_
18599}
18600
18601func (c *AdvertiserGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
18602	reqHeaders := make(http.Header)
18603	for k, v := range c.header_ {
18604		reqHeaders[k] = v
18605	}
18606	reqHeaders.Set("User-Agent", c.s.userAgent())
18607	var body io.Reader = nil
18608	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18609	if err != nil {
18610		return nil, err
18611	}
18612	reqHeaders.Set("Content-Type", "application/json")
18613	c.urlParams_.Set("alt", alt)
18614	c.urlParams_.Set("prettyPrint", "false")
18615	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18616	urls += "?" + c.urlParams_.Encode()
18617	req, err := http.NewRequest("PUT", urls, body)
18618	if err != nil {
18619		return nil, err
18620	}
18621	req.Header = reqHeaders
18622	googleapi.Expand(req.URL, map[string]string{
18623		"profileId": strconv.FormatInt(c.profileId, 10),
18624	})
18625	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18626}
18627
18628// Do executes the "dfareporting.advertiserGroups.update" call.
18629// Exactly one of *AdvertiserGroup or error will be non-nil. Any non-2xx
18630// status code is an error. Response headers are in either
18631// *AdvertiserGroup.ServerResponse.Header or (if a response was returned
18632// at all) in error.(*googleapi.Error).Header. Use
18633// googleapi.IsNotModified to check whether the returned error was
18634// because http.StatusNotModified was returned.
18635func (c *AdvertiserGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18636	gensupport.SetOptions(c.urlParams_, opts...)
18637	res, err := c.doRequest("json")
18638	if res != nil && res.StatusCode == http.StatusNotModified {
18639		if res.Body != nil {
18640			res.Body.Close()
18641		}
18642		return nil, &googleapi.Error{
18643			Code:   res.StatusCode,
18644			Header: res.Header,
18645		}
18646	}
18647	if err != nil {
18648		return nil, err
18649	}
18650	defer googleapi.CloseBody(res)
18651	if err := googleapi.CheckResponse(res); err != nil {
18652		return nil, err
18653	}
18654	ret := &AdvertiserGroup{
18655		ServerResponse: googleapi.ServerResponse{
18656			Header:         res.Header,
18657			HTTPStatusCode: res.StatusCode,
18658		},
18659	}
18660	target := &ret
18661	if err := gensupport.DecodeResponse(target, res); err != nil {
18662		return nil, err
18663	}
18664	return ret, nil
18665	// {
18666	//   "description": "Updates an existing advertiser group.",
18667	//   "httpMethod": "PUT",
18668	//   "id": "dfareporting.advertiserGroups.update",
18669	//   "parameterOrder": [
18670	//     "profileId"
18671	//   ],
18672	//   "parameters": {
18673	//     "profileId": {
18674	//       "description": "User profile ID associated with this request.",
18675	//       "format": "int64",
18676	//       "location": "path",
18677	//       "required": true,
18678	//       "type": "string"
18679	//     }
18680	//   },
18681	//   "path": "userprofiles/{profileId}/advertiserGroups",
18682	//   "request": {
18683	//     "$ref": "AdvertiserGroup"
18684	//   },
18685	//   "response": {
18686	//     "$ref": "AdvertiserGroup"
18687	//   },
18688	//   "scopes": [
18689	//     "https://www.googleapis.com/auth/dfatrafficking"
18690	//   ]
18691	// }
18692
18693}
18694
18695// method id "dfareporting.advertiserLandingPages.get":
18696
18697type AdvertiserLandingPagesGetCall struct {
18698	s            *Service
18699	profileId    int64
18700	id           int64
18701	urlParams_   gensupport.URLParams
18702	ifNoneMatch_ string
18703	ctx_         context.Context
18704	header_      http.Header
18705}
18706
18707// Get: Gets one landing page by ID.
18708func (r *AdvertiserLandingPagesService) Get(profileId int64, id int64) *AdvertiserLandingPagesGetCall {
18709	c := &AdvertiserLandingPagesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18710	c.profileId = profileId
18711	c.id = id
18712	return c
18713}
18714
18715// Fields allows partial responses to be retrieved. See
18716// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18717// for more information.
18718func (c *AdvertiserLandingPagesGetCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesGetCall {
18719	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18720	return c
18721}
18722
18723// IfNoneMatch sets the optional parameter which makes the operation
18724// fail if the object's ETag matches the given value. This is useful for
18725// getting updates only after the object has changed since the last
18726// request. Use googleapi.IsNotModified to check whether the response
18727// error from Do is the result of In-None-Match.
18728func (c *AdvertiserLandingPagesGetCall) IfNoneMatch(entityTag string) *AdvertiserLandingPagesGetCall {
18729	c.ifNoneMatch_ = entityTag
18730	return c
18731}
18732
18733// Context sets the context to be used in this call's Do method. Any
18734// pending HTTP request will be aborted if the provided context is
18735// canceled.
18736func (c *AdvertiserLandingPagesGetCall) Context(ctx context.Context) *AdvertiserLandingPagesGetCall {
18737	c.ctx_ = ctx
18738	return c
18739}
18740
18741// Header returns an http.Header that can be modified by the caller to
18742// add HTTP headers to the request.
18743func (c *AdvertiserLandingPagesGetCall) Header() http.Header {
18744	if c.header_ == nil {
18745		c.header_ = make(http.Header)
18746	}
18747	return c.header_
18748}
18749
18750func (c *AdvertiserLandingPagesGetCall) doRequest(alt string) (*http.Response, error) {
18751	reqHeaders := make(http.Header)
18752	for k, v := range c.header_ {
18753		reqHeaders[k] = v
18754	}
18755	reqHeaders.Set("User-Agent", c.s.userAgent())
18756	if c.ifNoneMatch_ != "" {
18757		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18758	}
18759	var body io.Reader = nil
18760	c.urlParams_.Set("alt", alt)
18761	c.urlParams_.Set("prettyPrint", "false")
18762	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages/{id}")
18763	urls += "?" + c.urlParams_.Encode()
18764	req, err := http.NewRequest("GET", urls, body)
18765	if err != nil {
18766		return nil, err
18767	}
18768	req.Header = reqHeaders
18769	googleapi.Expand(req.URL, map[string]string{
18770		"profileId": strconv.FormatInt(c.profileId, 10),
18771		"id":        strconv.FormatInt(c.id, 10),
18772	})
18773	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18774}
18775
18776// Do executes the "dfareporting.advertiserLandingPages.get" call.
18777// Exactly one of *LandingPage or error will be non-nil. Any non-2xx
18778// status code is an error. Response headers are in either
18779// *LandingPage.ServerResponse.Header or (if a response was returned at
18780// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
18781// to check whether the returned error was because
18782// http.StatusNotModified was returned.
18783func (c *AdvertiserLandingPagesGetCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
18784	gensupport.SetOptions(c.urlParams_, opts...)
18785	res, err := c.doRequest("json")
18786	if res != nil && res.StatusCode == http.StatusNotModified {
18787		if res.Body != nil {
18788			res.Body.Close()
18789		}
18790		return nil, &googleapi.Error{
18791			Code:   res.StatusCode,
18792			Header: res.Header,
18793		}
18794	}
18795	if err != nil {
18796		return nil, err
18797	}
18798	defer googleapi.CloseBody(res)
18799	if err := googleapi.CheckResponse(res); err != nil {
18800		return nil, err
18801	}
18802	ret := &LandingPage{
18803		ServerResponse: googleapi.ServerResponse{
18804			Header:         res.Header,
18805			HTTPStatusCode: res.StatusCode,
18806		},
18807	}
18808	target := &ret
18809	if err := gensupport.DecodeResponse(target, res); err != nil {
18810		return nil, err
18811	}
18812	return ret, nil
18813	// {
18814	//   "description": "Gets one landing page by ID.",
18815	//   "httpMethod": "GET",
18816	//   "id": "dfareporting.advertiserLandingPages.get",
18817	//   "parameterOrder": [
18818	//     "profileId",
18819	//     "id"
18820	//   ],
18821	//   "parameters": {
18822	//     "id": {
18823	//       "description": "Landing page ID.",
18824	//       "format": "int64",
18825	//       "location": "path",
18826	//       "required": true,
18827	//       "type": "string"
18828	//     },
18829	//     "profileId": {
18830	//       "description": "User profile ID associated with this request.",
18831	//       "format": "int64",
18832	//       "location": "path",
18833	//       "required": true,
18834	//       "type": "string"
18835	//     }
18836	//   },
18837	//   "path": "userprofiles/{profileId}/advertiserLandingPages/{id}",
18838	//   "response": {
18839	//     "$ref": "LandingPage"
18840	//   },
18841	//   "scopes": [
18842	//     "https://www.googleapis.com/auth/dfatrafficking"
18843	//   ]
18844	// }
18845
18846}
18847
18848// method id "dfareporting.advertiserLandingPages.insert":
18849
18850type AdvertiserLandingPagesInsertCall struct {
18851	s           *Service
18852	profileId   int64
18853	landingpage *LandingPage
18854	urlParams_  gensupport.URLParams
18855	ctx_        context.Context
18856	header_     http.Header
18857}
18858
18859// Insert: Inserts a new landing page.
18860func (r *AdvertiserLandingPagesService) Insert(profileId int64, landingpage *LandingPage) *AdvertiserLandingPagesInsertCall {
18861	c := &AdvertiserLandingPagesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18862	c.profileId = profileId
18863	c.landingpage = landingpage
18864	return c
18865}
18866
18867// Fields allows partial responses to be retrieved. See
18868// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18869// for more information.
18870func (c *AdvertiserLandingPagesInsertCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesInsertCall {
18871	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18872	return c
18873}
18874
18875// Context sets the context to be used in this call's Do method. Any
18876// pending HTTP request will be aborted if the provided context is
18877// canceled.
18878func (c *AdvertiserLandingPagesInsertCall) Context(ctx context.Context) *AdvertiserLandingPagesInsertCall {
18879	c.ctx_ = ctx
18880	return c
18881}
18882
18883// Header returns an http.Header that can be modified by the caller to
18884// add HTTP headers to the request.
18885func (c *AdvertiserLandingPagesInsertCall) Header() http.Header {
18886	if c.header_ == nil {
18887		c.header_ = make(http.Header)
18888	}
18889	return c.header_
18890}
18891
18892func (c *AdvertiserLandingPagesInsertCall) doRequest(alt string) (*http.Response, error) {
18893	reqHeaders := make(http.Header)
18894	for k, v := range c.header_ {
18895		reqHeaders[k] = v
18896	}
18897	reqHeaders.Set("User-Agent", c.s.userAgent())
18898	var body io.Reader = nil
18899	body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
18900	if err != nil {
18901		return nil, err
18902	}
18903	reqHeaders.Set("Content-Type", "application/json")
18904	c.urlParams_.Set("alt", alt)
18905	c.urlParams_.Set("prettyPrint", "false")
18906	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
18907	urls += "?" + c.urlParams_.Encode()
18908	req, err := http.NewRequest("POST", urls, body)
18909	if err != nil {
18910		return nil, err
18911	}
18912	req.Header = reqHeaders
18913	googleapi.Expand(req.URL, map[string]string{
18914		"profileId": strconv.FormatInt(c.profileId, 10),
18915	})
18916	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18917}
18918
18919// Do executes the "dfareporting.advertiserLandingPages.insert" call.
18920// Exactly one of *LandingPage or error will be non-nil. Any non-2xx
18921// status code is an error. Response headers are in either
18922// *LandingPage.ServerResponse.Header or (if a response was returned at
18923// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
18924// to check whether the returned error was because
18925// http.StatusNotModified was returned.
18926func (c *AdvertiserLandingPagesInsertCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
18927	gensupport.SetOptions(c.urlParams_, opts...)
18928	res, err := c.doRequest("json")
18929	if res != nil && res.StatusCode == http.StatusNotModified {
18930		if res.Body != nil {
18931			res.Body.Close()
18932		}
18933		return nil, &googleapi.Error{
18934			Code:   res.StatusCode,
18935			Header: res.Header,
18936		}
18937	}
18938	if err != nil {
18939		return nil, err
18940	}
18941	defer googleapi.CloseBody(res)
18942	if err := googleapi.CheckResponse(res); err != nil {
18943		return nil, err
18944	}
18945	ret := &LandingPage{
18946		ServerResponse: googleapi.ServerResponse{
18947			Header:         res.Header,
18948			HTTPStatusCode: res.StatusCode,
18949		},
18950	}
18951	target := &ret
18952	if err := gensupport.DecodeResponse(target, res); err != nil {
18953		return nil, err
18954	}
18955	return ret, nil
18956	// {
18957	//   "description": "Inserts a new landing page.",
18958	//   "httpMethod": "POST",
18959	//   "id": "dfareporting.advertiserLandingPages.insert",
18960	//   "parameterOrder": [
18961	//     "profileId"
18962	//   ],
18963	//   "parameters": {
18964	//     "profileId": {
18965	//       "description": "User profile ID associated with this request.",
18966	//       "format": "int64",
18967	//       "location": "path",
18968	//       "required": true,
18969	//       "type": "string"
18970	//     }
18971	//   },
18972	//   "path": "userprofiles/{profileId}/advertiserLandingPages",
18973	//   "request": {
18974	//     "$ref": "LandingPage"
18975	//   },
18976	//   "response": {
18977	//     "$ref": "LandingPage"
18978	//   },
18979	//   "scopes": [
18980	//     "https://www.googleapis.com/auth/dfatrafficking"
18981	//   ]
18982	// }
18983
18984}
18985
18986// method id "dfareporting.advertiserLandingPages.list":
18987
18988type AdvertiserLandingPagesListCall struct {
18989	s            *Service
18990	profileId    int64
18991	urlParams_   gensupport.URLParams
18992	ifNoneMatch_ string
18993	ctx_         context.Context
18994	header_      http.Header
18995}
18996
18997// List: Retrieves a list of landing pages.
18998func (r *AdvertiserLandingPagesService) List(profileId int64) *AdvertiserLandingPagesListCall {
18999	c := &AdvertiserLandingPagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19000	c.profileId = profileId
19001	return c
19002}
19003
19004// AdvertiserIds sets the optional parameter "advertiserIds": Select
19005// only landing pages that belong to these advertisers.
19006func (c *AdvertiserLandingPagesListCall) AdvertiserIds(advertiserIds ...int64) *AdvertiserLandingPagesListCall {
19007	var advertiserIds_ []string
19008	for _, v := range advertiserIds {
19009		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
19010	}
19011	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
19012	return c
19013}
19014
19015// Archived sets the optional parameter "archived": Select only archived
19016// landing pages. Don't set this field to select both archived and
19017// non-archived landing pages.
19018func (c *AdvertiserLandingPagesListCall) Archived(archived bool) *AdvertiserLandingPagesListCall {
19019	c.urlParams_.Set("archived", fmt.Sprint(archived))
19020	return c
19021}
19022
19023// Ids sets the optional parameter "ids": Select only landing pages with
19024// these IDs.
19025func (c *AdvertiserLandingPagesListCall) Ids(ids ...int64) *AdvertiserLandingPagesListCall {
19026	var ids_ []string
19027	for _, v := range ids {
19028		ids_ = append(ids_, fmt.Sprint(v))
19029	}
19030	c.urlParams_.SetMulti("ids", ids_)
19031	return c
19032}
19033
19034// MaxResults sets the optional parameter "maxResults": Maximum number
19035// of results to return.
19036func (c *AdvertiserLandingPagesListCall) MaxResults(maxResults int64) *AdvertiserLandingPagesListCall {
19037	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
19038	return c
19039}
19040
19041// PageToken sets the optional parameter "pageToken": Value of the
19042// nextPageToken from the previous result page.
19043func (c *AdvertiserLandingPagesListCall) PageToken(pageToken string) *AdvertiserLandingPagesListCall {
19044	c.urlParams_.Set("pageToken", pageToken)
19045	return c
19046}
19047
19048// SearchString sets the optional parameter "searchString": Allows
19049// searching for landing pages by name or ID. Wildcards (*) are allowed.
19050// For example, "landingpage*2017" will return landing pages with names
19051// like "landingpage July 2017", "landingpage March 2017", or simply
19052// "landingpage 2017". Most of the searches also add wildcards
19053// implicitly at the start and the end of the search string. For
19054// example, a search string of "landingpage" will match campaigns with
19055// name "my landingpage", "landingpage 2015", or simply "landingpage".
19056func (c *AdvertiserLandingPagesListCall) SearchString(searchString string) *AdvertiserLandingPagesListCall {
19057	c.urlParams_.Set("searchString", searchString)
19058	return c
19059}
19060
19061// SortField sets the optional parameter "sortField": Field by which to
19062// sort the list.
19063//
19064// Possible values:
19065//   "ID" (default)
19066//   "NAME"
19067func (c *AdvertiserLandingPagesListCall) SortField(sortField string) *AdvertiserLandingPagesListCall {
19068	c.urlParams_.Set("sortField", sortField)
19069	return c
19070}
19071
19072// SortOrder sets the optional parameter "sortOrder": Order of sorted
19073// results.
19074//
19075// Possible values:
19076//   "ASCENDING" (default)
19077//   "DESCENDING"
19078func (c *AdvertiserLandingPagesListCall) SortOrder(sortOrder string) *AdvertiserLandingPagesListCall {
19079	c.urlParams_.Set("sortOrder", sortOrder)
19080	return c
19081}
19082
19083// SubaccountId sets the optional parameter "subaccountId": Select only
19084// landing pages that belong to this subaccount.
19085func (c *AdvertiserLandingPagesListCall) SubaccountId(subaccountId int64) *AdvertiserLandingPagesListCall {
19086	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
19087	return c
19088}
19089
19090// Fields allows partial responses to be retrieved. See
19091// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19092// for more information.
19093func (c *AdvertiserLandingPagesListCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesListCall {
19094	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19095	return c
19096}
19097
19098// IfNoneMatch sets the optional parameter which makes the operation
19099// fail if the object's ETag matches the given value. This is useful for
19100// getting updates only after the object has changed since the last
19101// request. Use googleapi.IsNotModified to check whether the response
19102// error from Do is the result of In-None-Match.
19103func (c *AdvertiserLandingPagesListCall) IfNoneMatch(entityTag string) *AdvertiserLandingPagesListCall {
19104	c.ifNoneMatch_ = entityTag
19105	return c
19106}
19107
19108// Context sets the context to be used in this call's Do method. Any
19109// pending HTTP request will be aborted if the provided context is
19110// canceled.
19111func (c *AdvertiserLandingPagesListCall) Context(ctx context.Context) *AdvertiserLandingPagesListCall {
19112	c.ctx_ = ctx
19113	return c
19114}
19115
19116// Header returns an http.Header that can be modified by the caller to
19117// add HTTP headers to the request.
19118func (c *AdvertiserLandingPagesListCall) Header() http.Header {
19119	if c.header_ == nil {
19120		c.header_ = make(http.Header)
19121	}
19122	return c.header_
19123}
19124
19125func (c *AdvertiserLandingPagesListCall) doRequest(alt string) (*http.Response, error) {
19126	reqHeaders := make(http.Header)
19127	for k, v := range c.header_ {
19128		reqHeaders[k] = v
19129	}
19130	reqHeaders.Set("User-Agent", c.s.userAgent())
19131	if c.ifNoneMatch_ != "" {
19132		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19133	}
19134	var body io.Reader = nil
19135	c.urlParams_.Set("alt", alt)
19136	c.urlParams_.Set("prettyPrint", "false")
19137	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19138	urls += "?" + c.urlParams_.Encode()
19139	req, err := http.NewRequest("GET", urls, body)
19140	if err != nil {
19141		return nil, err
19142	}
19143	req.Header = reqHeaders
19144	googleapi.Expand(req.URL, map[string]string{
19145		"profileId": strconv.FormatInt(c.profileId, 10),
19146	})
19147	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19148}
19149
19150// Do executes the "dfareporting.advertiserLandingPages.list" call.
19151// Exactly one of *AdvertiserLandingPagesListResponse or error will be
19152// non-nil. Any non-2xx status code is an error. Response headers are in
19153// either *AdvertiserLandingPagesListResponse.ServerResponse.Header or
19154// (if a response was returned at all) in
19155// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
19156// whether the returned error was because http.StatusNotModified was
19157// returned.
19158func (c *AdvertiserLandingPagesListCall) Do(opts ...googleapi.CallOption) (*AdvertiserLandingPagesListResponse, error) {
19159	gensupport.SetOptions(c.urlParams_, opts...)
19160	res, err := c.doRequest("json")
19161	if res != nil && res.StatusCode == http.StatusNotModified {
19162		if res.Body != nil {
19163			res.Body.Close()
19164		}
19165		return nil, &googleapi.Error{
19166			Code:   res.StatusCode,
19167			Header: res.Header,
19168		}
19169	}
19170	if err != nil {
19171		return nil, err
19172	}
19173	defer googleapi.CloseBody(res)
19174	if err := googleapi.CheckResponse(res); err != nil {
19175		return nil, err
19176	}
19177	ret := &AdvertiserLandingPagesListResponse{
19178		ServerResponse: googleapi.ServerResponse{
19179			Header:         res.Header,
19180			HTTPStatusCode: res.StatusCode,
19181		},
19182	}
19183	target := &ret
19184	if err := gensupport.DecodeResponse(target, res); err != nil {
19185		return nil, err
19186	}
19187	return ret, nil
19188	// {
19189	//   "description": "Retrieves a list of landing pages.",
19190	//   "httpMethod": "GET",
19191	//   "id": "dfareporting.advertiserLandingPages.list",
19192	//   "parameterOrder": [
19193	//     "profileId"
19194	//   ],
19195	//   "parameters": {
19196	//     "advertiserIds": {
19197	//       "description": "Select only landing pages that belong to these advertisers.",
19198	//       "format": "int64",
19199	//       "location": "query",
19200	//       "repeated": true,
19201	//       "type": "string"
19202	//     },
19203	//     "archived": {
19204	//       "description": "Select only archived landing pages. Don't set this field to select both archived and non-archived landing pages.",
19205	//       "location": "query",
19206	//       "type": "boolean"
19207	//     },
19208	//     "ids": {
19209	//       "description": "Select only landing pages with these IDs.",
19210	//       "format": "int64",
19211	//       "location": "query",
19212	//       "repeated": true,
19213	//       "type": "string"
19214	//     },
19215	//     "maxResults": {
19216	//       "default": "1000",
19217	//       "description": "Maximum number of results to return.",
19218	//       "format": "int32",
19219	//       "location": "query",
19220	//       "maximum": "1000",
19221	//       "minimum": "0",
19222	//       "type": "integer"
19223	//     },
19224	//     "pageToken": {
19225	//       "description": "Value of the nextPageToken from the previous result page.",
19226	//       "location": "query",
19227	//       "type": "string"
19228	//     },
19229	//     "profileId": {
19230	//       "description": "User profile ID associated with this request.",
19231	//       "format": "int64",
19232	//       "location": "path",
19233	//       "required": true,
19234	//       "type": "string"
19235	//     },
19236	//     "searchString": {
19237	//       "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\".",
19238	//       "location": "query",
19239	//       "type": "string"
19240	//     },
19241	//     "sortField": {
19242	//       "default": "ID",
19243	//       "description": "Field by which to sort the list.",
19244	//       "enum": [
19245	//         "ID",
19246	//         "NAME"
19247	//       ],
19248	//       "enumDescriptions": [
19249	//         "",
19250	//         ""
19251	//       ],
19252	//       "location": "query",
19253	//       "type": "string"
19254	//     },
19255	//     "sortOrder": {
19256	//       "default": "ASCENDING",
19257	//       "description": "Order of sorted results.",
19258	//       "enum": [
19259	//         "ASCENDING",
19260	//         "DESCENDING"
19261	//       ],
19262	//       "enumDescriptions": [
19263	//         "",
19264	//         ""
19265	//       ],
19266	//       "location": "query",
19267	//       "type": "string"
19268	//     },
19269	//     "subaccountId": {
19270	//       "description": "Select only landing pages that belong to this subaccount.",
19271	//       "format": "int64",
19272	//       "location": "query",
19273	//       "type": "string"
19274	//     }
19275	//   },
19276	//   "path": "userprofiles/{profileId}/advertiserLandingPages",
19277	//   "response": {
19278	//     "$ref": "AdvertiserLandingPagesListResponse"
19279	//   },
19280	//   "scopes": [
19281	//     "https://www.googleapis.com/auth/dfatrafficking"
19282	//   ]
19283	// }
19284
19285}
19286
19287// Pages invokes f for each page of results.
19288// A non-nil error returned from f will halt the iteration.
19289// The provided context supersedes any context provided to the Context method.
19290func (c *AdvertiserLandingPagesListCall) Pages(ctx context.Context, f func(*AdvertiserLandingPagesListResponse) error) error {
19291	c.ctx_ = ctx
19292	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
19293	for {
19294		x, err := c.Do()
19295		if err != nil {
19296			return err
19297		}
19298		if err := f(x); err != nil {
19299			return err
19300		}
19301		if x.NextPageToken == "" {
19302			return nil
19303		}
19304		c.PageToken(x.NextPageToken)
19305	}
19306}
19307
19308// method id "dfareporting.advertiserLandingPages.patch":
19309
19310type AdvertiserLandingPagesPatchCall struct {
19311	s           *Service
19312	profileId   int64
19313	landingpage *LandingPage
19314	urlParams_  gensupport.URLParams
19315	ctx_        context.Context
19316	header_     http.Header
19317}
19318
19319// Patch: Updates an existing landing page. This method supports patch
19320// semantics.
19321func (r *AdvertiserLandingPagesService) Patch(profileId int64, id int64, landingpage *LandingPage) *AdvertiserLandingPagesPatchCall {
19322	c := &AdvertiserLandingPagesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19323	c.profileId = profileId
19324	c.urlParams_.Set("id", fmt.Sprint(id))
19325	c.landingpage = landingpage
19326	return c
19327}
19328
19329// Fields allows partial responses to be retrieved. See
19330// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19331// for more information.
19332func (c *AdvertiserLandingPagesPatchCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesPatchCall {
19333	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19334	return c
19335}
19336
19337// Context sets the context to be used in this call's Do method. Any
19338// pending HTTP request will be aborted if the provided context is
19339// canceled.
19340func (c *AdvertiserLandingPagesPatchCall) Context(ctx context.Context) *AdvertiserLandingPagesPatchCall {
19341	c.ctx_ = ctx
19342	return c
19343}
19344
19345// Header returns an http.Header that can be modified by the caller to
19346// add HTTP headers to the request.
19347func (c *AdvertiserLandingPagesPatchCall) Header() http.Header {
19348	if c.header_ == nil {
19349		c.header_ = make(http.Header)
19350	}
19351	return c.header_
19352}
19353
19354func (c *AdvertiserLandingPagesPatchCall) doRequest(alt string) (*http.Response, error) {
19355	reqHeaders := make(http.Header)
19356	for k, v := range c.header_ {
19357		reqHeaders[k] = v
19358	}
19359	reqHeaders.Set("User-Agent", c.s.userAgent())
19360	var body io.Reader = nil
19361	body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
19362	if err != nil {
19363		return nil, err
19364	}
19365	reqHeaders.Set("Content-Type", "application/json")
19366	c.urlParams_.Set("alt", alt)
19367	c.urlParams_.Set("prettyPrint", "false")
19368	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19369	urls += "?" + c.urlParams_.Encode()
19370	req, err := http.NewRequest("PATCH", urls, body)
19371	if err != nil {
19372		return nil, err
19373	}
19374	req.Header = reqHeaders
19375	googleapi.Expand(req.URL, map[string]string{
19376		"profileId": strconv.FormatInt(c.profileId, 10),
19377	})
19378	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19379}
19380
19381// Do executes the "dfareporting.advertiserLandingPages.patch" call.
19382// Exactly one of *LandingPage or error will be non-nil. Any non-2xx
19383// status code is an error. Response headers are in either
19384// *LandingPage.ServerResponse.Header or (if a response was returned at
19385// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
19386// to check whether the returned error was because
19387// http.StatusNotModified was returned.
19388func (c *AdvertiserLandingPagesPatchCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
19389	gensupport.SetOptions(c.urlParams_, opts...)
19390	res, err := c.doRequest("json")
19391	if res != nil && res.StatusCode == http.StatusNotModified {
19392		if res.Body != nil {
19393			res.Body.Close()
19394		}
19395		return nil, &googleapi.Error{
19396			Code:   res.StatusCode,
19397			Header: res.Header,
19398		}
19399	}
19400	if err != nil {
19401		return nil, err
19402	}
19403	defer googleapi.CloseBody(res)
19404	if err := googleapi.CheckResponse(res); err != nil {
19405		return nil, err
19406	}
19407	ret := &LandingPage{
19408		ServerResponse: googleapi.ServerResponse{
19409			Header:         res.Header,
19410			HTTPStatusCode: res.StatusCode,
19411		},
19412	}
19413	target := &ret
19414	if err := gensupport.DecodeResponse(target, res); err != nil {
19415		return nil, err
19416	}
19417	return ret, nil
19418	// {
19419	//   "description": "Updates an existing landing page. This method supports patch semantics.",
19420	//   "httpMethod": "PATCH",
19421	//   "id": "dfareporting.advertiserLandingPages.patch",
19422	//   "parameterOrder": [
19423	//     "profileId",
19424	//     "id"
19425	//   ],
19426	//   "parameters": {
19427	//     "id": {
19428	//       "description": "Landing page ID.",
19429	//       "format": "int64",
19430	//       "location": "query",
19431	//       "required": true,
19432	//       "type": "string"
19433	//     },
19434	//     "profileId": {
19435	//       "description": "User profile ID associated with this request.",
19436	//       "format": "int64",
19437	//       "location": "path",
19438	//       "required": true,
19439	//       "type": "string"
19440	//     }
19441	//   },
19442	//   "path": "userprofiles/{profileId}/advertiserLandingPages",
19443	//   "request": {
19444	//     "$ref": "LandingPage"
19445	//   },
19446	//   "response": {
19447	//     "$ref": "LandingPage"
19448	//   },
19449	//   "scopes": [
19450	//     "https://www.googleapis.com/auth/dfatrafficking"
19451	//   ]
19452	// }
19453
19454}
19455
19456// method id "dfareporting.advertiserLandingPages.update":
19457
19458type AdvertiserLandingPagesUpdateCall struct {
19459	s           *Service
19460	profileId   int64
19461	landingpage *LandingPage
19462	urlParams_  gensupport.URLParams
19463	ctx_        context.Context
19464	header_     http.Header
19465}
19466
19467// Update: Updates an existing landing page.
19468func (r *AdvertiserLandingPagesService) Update(profileId int64, landingpage *LandingPage) *AdvertiserLandingPagesUpdateCall {
19469	c := &AdvertiserLandingPagesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19470	c.profileId = profileId
19471	c.landingpage = landingpage
19472	return c
19473}
19474
19475// Fields allows partial responses to be retrieved. See
19476// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19477// for more information.
19478func (c *AdvertiserLandingPagesUpdateCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesUpdateCall {
19479	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19480	return c
19481}
19482
19483// Context sets the context to be used in this call's Do method. Any
19484// pending HTTP request will be aborted if the provided context is
19485// canceled.
19486func (c *AdvertiserLandingPagesUpdateCall) Context(ctx context.Context) *AdvertiserLandingPagesUpdateCall {
19487	c.ctx_ = ctx
19488	return c
19489}
19490
19491// Header returns an http.Header that can be modified by the caller to
19492// add HTTP headers to the request.
19493func (c *AdvertiserLandingPagesUpdateCall) Header() http.Header {
19494	if c.header_ == nil {
19495		c.header_ = make(http.Header)
19496	}
19497	return c.header_
19498}
19499
19500func (c *AdvertiserLandingPagesUpdateCall) doRequest(alt string) (*http.Response, error) {
19501	reqHeaders := make(http.Header)
19502	for k, v := range c.header_ {
19503		reqHeaders[k] = v
19504	}
19505	reqHeaders.Set("User-Agent", c.s.userAgent())
19506	var body io.Reader = nil
19507	body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
19508	if err != nil {
19509		return nil, err
19510	}
19511	reqHeaders.Set("Content-Type", "application/json")
19512	c.urlParams_.Set("alt", alt)
19513	c.urlParams_.Set("prettyPrint", "false")
19514	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19515	urls += "?" + c.urlParams_.Encode()
19516	req, err := http.NewRequest("PUT", urls, body)
19517	if err != nil {
19518		return nil, err
19519	}
19520	req.Header = reqHeaders
19521	googleapi.Expand(req.URL, map[string]string{
19522		"profileId": strconv.FormatInt(c.profileId, 10),
19523	})
19524	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19525}
19526
19527// Do executes the "dfareporting.advertiserLandingPages.update" call.
19528// Exactly one of *LandingPage or error will be non-nil. Any non-2xx
19529// status code is an error. Response headers are in either
19530// *LandingPage.ServerResponse.Header or (if a response was returned at
19531// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
19532// to check whether the returned error was because
19533// http.StatusNotModified was returned.
19534func (c *AdvertiserLandingPagesUpdateCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
19535	gensupport.SetOptions(c.urlParams_, opts...)
19536	res, err := c.doRequest("json")
19537	if res != nil && res.StatusCode == http.StatusNotModified {
19538		if res.Body != nil {
19539			res.Body.Close()
19540		}
19541		return nil, &googleapi.Error{
19542			Code:   res.StatusCode,
19543			Header: res.Header,
19544		}
19545	}
19546	if err != nil {
19547		return nil, err
19548	}
19549	defer googleapi.CloseBody(res)
19550	if err := googleapi.CheckResponse(res); err != nil {
19551		return nil, err
19552	}
19553	ret := &LandingPage{
19554		ServerResponse: googleapi.ServerResponse{
19555			Header:         res.Header,
19556			HTTPStatusCode: res.StatusCode,
19557		},
19558	}
19559	target := &ret
19560	if err := gensupport.DecodeResponse(target, res); err != nil {
19561		return nil, err
19562	}
19563	return ret, nil
19564	// {
19565	//   "description": "Updates an existing landing page.",
19566	//   "httpMethod": "PUT",
19567	//   "id": "dfareporting.advertiserLandingPages.update",
19568	//   "parameterOrder": [
19569	//     "profileId"
19570	//   ],
19571	//   "parameters": {
19572	//     "profileId": {
19573	//       "description": "User profile ID associated with this request.",
19574	//       "format": "int64",
19575	//       "location": "path",
19576	//       "required": true,
19577	//       "type": "string"
19578	//     }
19579	//   },
19580	//   "path": "userprofiles/{profileId}/advertiserLandingPages",
19581	//   "request": {
19582	//     "$ref": "LandingPage"
19583	//   },
19584	//   "response": {
19585	//     "$ref": "LandingPage"
19586	//   },
19587	//   "scopes": [
19588	//     "https://www.googleapis.com/auth/dfatrafficking"
19589	//   ]
19590	// }
19591
19592}
19593
19594// method id "dfareporting.advertisers.get":
19595
19596type AdvertisersGetCall struct {
19597	s            *Service
19598	profileId    int64
19599	id           int64
19600	urlParams_   gensupport.URLParams
19601	ifNoneMatch_ string
19602	ctx_         context.Context
19603	header_      http.Header
19604}
19605
19606// Get: Gets one advertiser by ID.
19607func (r *AdvertisersService) Get(profileId int64, id int64) *AdvertisersGetCall {
19608	c := &AdvertisersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19609	c.profileId = profileId
19610	c.id = id
19611	return c
19612}
19613
19614// Fields allows partial responses to be retrieved. See
19615// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19616// for more information.
19617func (c *AdvertisersGetCall) Fields(s ...googleapi.Field) *AdvertisersGetCall {
19618	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19619	return c
19620}
19621
19622// IfNoneMatch sets the optional parameter which makes the operation
19623// fail if the object's ETag matches the given value. This is useful for
19624// getting updates only after the object has changed since the last
19625// request. Use googleapi.IsNotModified to check whether the response
19626// error from Do is the result of In-None-Match.
19627func (c *AdvertisersGetCall) IfNoneMatch(entityTag string) *AdvertisersGetCall {
19628	c.ifNoneMatch_ = entityTag
19629	return c
19630}
19631
19632// Context sets the context to be used in this call's Do method. Any
19633// pending HTTP request will be aborted if the provided context is
19634// canceled.
19635func (c *AdvertisersGetCall) Context(ctx context.Context) *AdvertisersGetCall {
19636	c.ctx_ = ctx
19637	return c
19638}
19639
19640// Header returns an http.Header that can be modified by the caller to
19641// add HTTP headers to the request.
19642func (c *AdvertisersGetCall) Header() http.Header {
19643	if c.header_ == nil {
19644		c.header_ = make(http.Header)
19645	}
19646	return c.header_
19647}
19648
19649func (c *AdvertisersGetCall) doRequest(alt string) (*http.Response, error) {
19650	reqHeaders := make(http.Header)
19651	for k, v := range c.header_ {
19652		reqHeaders[k] = v
19653	}
19654	reqHeaders.Set("User-Agent", c.s.userAgent())
19655	if c.ifNoneMatch_ != "" {
19656		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19657	}
19658	var body io.Reader = nil
19659	c.urlParams_.Set("alt", alt)
19660	c.urlParams_.Set("prettyPrint", "false")
19661	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers/{id}")
19662	urls += "?" + c.urlParams_.Encode()
19663	req, err := http.NewRequest("GET", urls, body)
19664	if err != nil {
19665		return nil, err
19666	}
19667	req.Header = reqHeaders
19668	googleapi.Expand(req.URL, map[string]string{
19669		"profileId": strconv.FormatInt(c.profileId, 10),
19670		"id":        strconv.FormatInt(c.id, 10),
19671	})
19672	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19673}
19674
19675// Do executes the "dfareporting.advertisers.get" call.
19676// Exactly one of *Advertiser or error will be non-nil. Any non-2xx
19677// status code is an error. Response headers are in either
19678// *Advertiser.ServerResponse.Header or (if a response was returned at
19679// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
19680// to check whether the returned error was because
19681// http.StatusNotModified was returned.
19682func (c *AdvertisersGetCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
19683	gensupport.SetOptions(c.urlParams_, opts...)
19684	res, err := c.doRequest("json")
19685	if res != nil && res.StatusCode == http.StatusNotModified {
19686		if res.Body != nil {
19687			res.Body.Close()
19688		}
19689		return nil, &googleapi.Error{
19690			Code:   res.StatusCode,
19691			Header: res.Header,
19692		}
19693	}
19694	if err != nil {
19695		return nil, err
19696	}
19697	defer googleapi.CloseBody(res)
19698	if err := googleapi.CheckResponse(res); err != nil {
19699		return nil, err
19700	}
19701	ret := &Advertiser{
19702		ServerResponse: googleapi.ServerResponse{
19703			Header:         res.Header,
19704			HTTPStatusCode: res.StatusCode,
19705		},
19706	}
19707	target := &ret
19708	if err := gensupport.DecodeResponse(target, res); err != nil {
19709		return nil, err
19710	}
19711	return ret, nil
19712	// {
19713	//   "description": "Gets one advertiser by ID.",
19714	//   "httpMethod": "GET",
19715	//   "id": "dfareporting.advertisers.get",
19716	//   "parameterOrder": [
19717	//     "profileId",
19718	//     "id"
19719	//   ],
19720	//   "parameters": {
19721	//     "id": {
19722	//       "description": "Advertiser ID.",
19723	//       "format": "int64",
19724	//       "location": "path",
19725	//       "required": true,
19726	//       "type": "string"
19727	//     },
19728	//     "profileId": {
19729	//       "description": "User profile ID associated with this request.",
19730	//       "format": "int64",
19731	//       "location": "path",
19732	//       "required": true,
19733	//       "type": "string"
19734	//     }
19735	//   },
19736	//   "path": "userprofiles/{profileId}/advertisers/{id}",
19737	//   "response": {
19738	//     "$ref": "Advertiser"
19739	//   },
19740	//   "scopes": [
19741	//     "https://www.googleapis.com/auth/dfatrafficking"
19742	//   ]
19743	// }
19744
19745}
19746
19747// method id "dfareporting.advertisers.insert":
19748
19749type AdvertisersInsertCall struct {
19750	s          *Service
19751	profileId  int64
19752	advertiser *Advertiser
19753	urlParams_ gensupport.URLParams
19754	ctx_       context.Context
19755	header_    http.Header
19756}
19757
19758// Insert: Inserts a new advertiser.
19759func (r *AdvertisersService) Insert(profileId int64, advertiser *Advertiser) *AdvertisersInsertCall {
19760	c := &AdvertisersInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19761	c.profileId = profileId
19762	c.advertiser = advertiser
19763	return c
19764}
19765
19766// Fields allows partial responses to be retrieved. See
19767// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19768// for more information.
19769func (c *AdvertisersInsertCall) Fields(s ...googleapi.Field) *AdvertisersInsertCall {
19770	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19771	return c
19772}
19773
19774// Context sets the context to be used in this call's Do method. Any
19775// pending HTTP request will be aborted if the provided context is
19776// canceled.
19777func (c *AdvertisersInsertCall) Context(ctx context.Context) *AdvertisersInsertCall {
19778	c.ctx_ = ctx
19779	return c
19780}
19781
19782// Header returns an http.Header that can be modified by the caller to
19783// add HTTP headers to the request.
19784func (c *AdvertisersInsertCall) Header() http.Header {
19785	if c.header_ == nil {
19786		c.header_ = make(http.Header)
19787	}
19788	return c.header_
19789}
19790
19791func (c *AdvertisersInsertCall) doRequest(alt string) (*http.Response, error) {
19792	reqHeaders := make(http.Header)
19793	for k, v := range c.header_ {
19794		reqHeaders[k] = v
19795	}
19796	reqHeaders.Set("User-Agent", c.s.userAgent())
19797	var body io.Reader = nil
19798	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
19799	if err != nil {
19800		return nil, err
19801	}
19802	reqHeaders.Set("Content-Type", "application/json")
19803	c.urlParams_.Set("alt", alt)
19804	c.urlParams_.Set("prettyPrint", "false")
19805	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
19806	urls += "?" + c.urlParams_.Encode()
19807	req, err := http.NewRequest("POST", urls, body)
19808	if err != nil {
19809		return nil, err
19810	}
19811	req.Header = reqHeaders
19812	googleapi.Expand(req.URL, map[string]string{
19813		"profileId": strconv.FormatInt(c.profileId, 10),
19814	})
19815	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19816}
19817
19818// Do executes the "dfareporting.advertisers.insert" call.
19819// Exactly one of *Advertiser or error will be non-nil. Any non-2xx
19820// status code is an error. Response headers are in either
19821// *Advertiser.ServerResponse.Header or (if a response was returned at
19822// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
19823// to check whether the returned error was because
19824// http.StatusNotModified was returned.
19825func (c *AdvertisersInsertCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
19826	gensupport.SetOptions(c.urlParams_, opts...)
19827	res, err := c.doRequest("json")
19828	if res != nil && res.StatusCode == http.StatusNotModified {
19829		if res.Body != nil {
19830			res.Body.Close()
19831		}
19832		return nil, &googleapi.Error{
19833			Code:   res.StatusCode,
19834			Header: res.Header,
19835		}
19836	}
19837	if err != nil {
19838		return nil, err
19839	}
19840	defer googleapi.CloseBody(res)
19841	if err := googleapi.CheckResponse(res); err != nil {
19842		return nil, err
19843	}
19844	ret := &Advertiser{
19845		ServerResponse: googleapi.ServerResponse{
19846			Header:         res.Header,
19847			HTTPStatusCode: res.StatusCode,
19848		},
19849	}
19850	target := &ret
19851	if err := gensupport.DecodeResponse(target, res); err != nil {
19852		return nil, err
19853	}
19854	return ret, nil
19855	// {
19856	//   "description": "Inserts a new advertiser.",
19857	//   "httpMethod": "POST",
19858	//   "id": "dfareporting.advertisers.insert",
19859	//   "parameterOrder": [
19860	//     "profileId"
19861	//   ],
19862	//   "parameters": {
19863	//     "profileId": {
19864	//       "description": "User profile ID associated with this request.",
19865	//       "format": "int64",
19866	//       "location": "path",
19867	//       "required": true,
19868	//       "type": "string"
19869	//     }
19870	//   },
19871	//   "path": "userprofiles/{profileId}/advertisers",
19872	//   "request": {
19873	//     "$ref": "Advertiser"
19874	//   },
19875	//   "response": {
19876	//     "$ref": "Advertiser"
19877	//   },
19878	//   "scopes": [
19879	//     "https://www.googleapis.com/auth/dfatrafficking"
19880	//   ]
19881	// }
19882
19883}
19884
19885// method id "dfareporting.advertisers.list":
19886
19887type AdvertisersListCall struct {
19888	s            *Service
19889	profileId    int64
19890	urlParams_   gensupport.URLParams
19891	ifNoneMatch_ string
19892	ctx_         context.Context
19893	header_      http.Header
19894}
19895
19896// List: Retrieves a list of advertisers, possibly filtered. This method
19897// supports paging.
19898func (r *AdvertisersService) List(profileId int64) *AdvertisersListCall {
19899	c := &AdvertisersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19900	c.profileId = profileId
19901	return c
19902}
19903
19904// AdvertiserGroupIds sets the optional parameter "advertiserGroupIds":
19905// Select only advertisers with these advertiser group IDs.
19906func (c *AdvertisersListCall) AdvertiserGroupIds(advertiserGroupIds ...int64) *AdvertisersListCall {
19907	var advertiserGroupIds_ []string
19908	for _, v := range advertiserGroupIds {
19909		advertiserGroupIds_ = append(advertiserGroupIds_, fmt.Sprint(v))
19910	}
19911	c.urlParams_.SetMulti("advertiserGroupIds", advertiserGroupIds_)
19912	return c
19913}
19914
19915// FloodlightConfigurationIds sets the optional parameter
19916// "floodlightConfigurationIds": Select only advertisers with these
19917// floodlight configuration IDs.
19918func (c *AdvertisersListCall) FloodlightConfigurationIds(floodlightConfigurationIds ...int64) *AdvertisersListCall {
19919	var floodlightConfigurationIds_ []string
19920	for _, v := range floodlightConfigurationIds {
19921		floodlightConfigurationIds_ = append(floodlightConfigurationIds_, fmt.Sprint(v))
19922	}
19923	c.urlParams_.SetMulti("floodlightConfigurationIds", floodlightConfigurationIds_)
19924	return c
19925}
19926
19927// Ids sets the optional parameter "ids": Select only advertisers with
19928// these IDs.
19929func (c *AdvertisersListCall) Ids(ids ...int64) *AdvertisersListCall {
19930	var ids_ []string
19931	for _, v := range ids {
19932		ids_ = append(ids_, fmt.Sprint(v))
19933	}
19934	c.urlParams_.SetMulti("ids", ids_)
19935	return c
19936}
19937
19938// IncludeAdvertisersWithoutGroupsOnly sets the optional parameter
19939// "includeAdvertisersWithoutGroupsOnly": Select only advertisers which
19940// do not belong to any advertiser group.
19941func (c *AdvertisersListCall) IncludeAdvertisersWithoutGroupsOnly(includeAdvertisersWithoutGroupsOnly bool) *AdvertisersListCall {
19942	c.urlParams_.Set("includeAdvertisersWithoutGroupsOnly", fmt.Sprint(includeAdvertisersWithoutGroupsOnly))
19943	return c
19944}
19945
19946// MaxResults sets the optional parameter "maxResults": Maximum number
19947// of results to return.
19948func (c *AdvertisersListCall) MaxResults(maxResults int64) *AdvertisersListCall {
19949	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
19950	return c
19951}
19952
19953// OnlyParent sets the optional parameter "onlyParent": Select only
19954// advertisers which use another advertiser's floodlight configuration.
19955func (c *AdvertisersListCall) OnlyParent(onlyParent bool) *AdvertisersListCall {
19956	c.urlParams_.Set("onlyParent", fmt.Sprint(onlyParent))
19957	return c
19958}
19959
19960// PageToken sets the optional parameter "pageToken": Value of the
19961// nextPageToken from the previous result page.
19962func (c *AdvertisersListCall) PageToken(pageToken string) *AdvertisersListCall {
19963	c.urlParams_.Set("pageToken", pageToken)
19964	return c
19965}
19966
19967// SearchString sets the optional parameter "searchString": Allows
19968// searching for objects by name or ID. Wildcards (*) are allowed. For
19969// example, "advertiser*2015" will return objects with names like
19970// "advertiser June 2015", "advertiser April 2015", or simply
19971// "advertiser 2015". Most of the searches also add wildcards implicitly
19972// at the start and the end of the search string. For example, a search
19973// string of "advertiser" will match objects with name "my advertiser",
19974// "advertiser 2015", or simply "advertiser".
19975func (c *AdvertisersListCall) SearchString(searchString string) *AdvertisersListCall {
19976	c.urlParams_.Set("searchString", searchString)
19977	return c
19978}
19979
19980// SortField sets the optional parameter "sortField": Field by which to
19981// sort the list.
19982//
19983// Possible values:
19984//   "ID" (default)
19985//   "NAME"
19986func (c *AdvertisersListCall) SortField(sortField string) *AdvertisersListCall {
19987	c.urlParams_.Set("sortField", sortField)
19988	return c
19989}
19990
19991// SortOrder sets the optional parameter "sortOrder": Order of sorted
19992// results.
19993//
19994// Possible values:
19995//   "ASCENDING" (default)
19996//   "DESCENDING"
19997func (c *AdvertisersListCall) SortOrder(sortOrder string) *AdvertisersListCall {
19998	c.urlParams_.Set("sortOrder", sortOrder)
19999	return c
20000}
20001
20002// Status sets the optional parameter "status": Select only advertisers
20003// with the specified status.
20004//
20005// Possible values:
20006//   "APPROVED"
20007//   "ON_HOLD"
20008func (c *AdvertisersListCall) Status(status string) *AdvertisersListCall {
20009	c.urlParams_.Set("status", status)
20010	return c
20011}
20012
20013// SubaccountId sets the optional parameter "subaccountId": Select only
20014// advertisers with these subaccount IDs.
20015func (c *AdvertisersListCall) SubaccountId(subaccountId int64) *AdvertisersListCall {
20016	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
20017	return c
20018}
20019
20020// Fields allows partial responses to be retrieved. See
20021// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20022// for more information.
20023func (c *AdvertisersListCall) Fields(s ...googleapi.Field) *AdvertisersListCall {
20024	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20025	return c
20026}
20027
20028// IfNoneMatch sets the optional parameter which makes the operation
20029// fail if the object's ETag matches the given value. This is useful for
20030// getting updates only after the object has changed since the last
20031// request. Use googleapi.IsNotModified to check whether the response
20032// error from Do is the result of In-None-Match.
20033func (c *AdvertisersListCall) IfNoneMatch(entityTag string) *AdvertisersListCall {
20034	c.ifNoneMatch_ = entityTag
20035	return c
20036}
20037
20038// Context sets the context to be used in this call's Do method. Any
20039// pending HTTP request will be aborted if the provided context is
20040// canceled.
20041func (c *AdvertisersListCall) Context(ctx context.Context) *AdvertisersListCall {
20042	c.ctx_ = ctx
20043	return c
20044}
20045
20046// Header returns an http.Header that can be modified by the caller to
20047// add HTTP headers to the request.
20048func (c *AdvertisersListCall) Header() http.Header {
20049	if c.header_ == nil {
20050		c.header_ = make(http.Header)
20051	}
20052	return c.header_
20053}
20054
20055func (c *AdvertisersListCall) doRequest(alt string) (*http.Response, error) {
20056	reqHeaders := make(http.Header)
20057	for k, v := range c.header_ {
20058		reqHeaders[k] = v
20059	}
20060	reqHeaders.Set("User-Agent", c.s.userAgent())
20061	if c.ifNoneMatch_ != "" {
20062		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20063	}
20064	var body io.Reader = nil
20065	c.urlParams_.Set("alt", alt)
20066	c.urlParams_.Set("prettyPrint", "false")
20067	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20068	urls += "?" + c.urlParams_.Encode()
20069	req, err := http.NewRequest("GET", urls, body)
20070	if err != nil {
20071		return nil, err
20072	}
20073	req.Header = reqHeaders
20074	googleapi.Expand(req.URL, map[string]string{
20075		"profileId": strconv.FormatInt(c.profileId, 10),
20076	})
20077	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20078}
20079
20080// Do executes the "dfareporting.advertisers.list" call.
20081// Exactly one of *AdvertisersListResponse or error will be non-nil. Any
20082// non-2xx status code is an error. Response headers are in either
20083// *AdvertisersListResponse.ServerResponse.Header or (if a response was
20084// returned at all) in error.(*googleapi.Error).Header. Use
20085// googleapi.IsNotModified to check whether the returned error was
20086// because http.StatusNotModified was returned.
20087func (c *AdvertisersListCall) Do(opts ...googleapi.CallOption) (*AdvertisersListResponse, error) {
20088	gensupport.SetOptions(c.urlParams_, opts...)
20089	res, err := c.doRequest("json")
20090	if res != nil && res.StatusCode == http.StatusNotModified {
20091		if res.Body != nil {
20092			res.Body.Close()
20093		}
20094		return nil, &googleapi.Error{
20095			Code:   res.StatusCode,
20096			Header: res.Header,
20097		}
20098	}
20099	if err != nil {
20100		return nil, err
20101	}
20102	defer googleapi.CloseBody(res)
20103	if err := googleapi.CheckResponse(res); err != nil {
20104		return nil, err
20105	}
20106	ret := &AdvertisersListResponse{
20107		ServerResponse: googleapi.ServerResponse{
20108			Header:         res.Header,
20109			HTTPStatusCode: res.StatusCode,
20110		},
20111	}
20112	target := &ret
20113	if err := gensupport.DecodeResponse(target, res); err != nil {
20114		return nil, err
20115	}
20116	return ret, nil
20117	// {
20118	//   "description": "Retrieves a list of advertisers, possibly filtered. This method supports paging.",
20119	//   "httpMethod": "GET",
20120	//   "id": "dfareporting.advertisers.list",
20121	//   "parameterOrder": [
20122	//     "profileId"
20123	//   ],
20124	//   "parameters": {
20125	//     "advertiserGroupIds": {
20126	//       "description": "Select only advertisers with these advertiser group IDs.",
20127	//       "format": "int64",
20128	//       "location": "query",
20129	//       "repeated": true,
20130	//       "type": "string"
20131	//     },
20132	//     "floodlightConfigurationIds": {
20133	//       "description": "Select only advertisers with these floodlight configuration IDs.",
20134	//       "format": "int64",
20135	//       "location": "query",
20136	//       "repeated": true,
20137	//       "type": "string"
20138	//     },
20139	//     "ids": {
20140	//       "description": "Select only advertisers with these IDs.",
20141	//       "format": "int64",
20142	//       "location": "query",
20143	//       "repeated": true,
20144	//       "type": "string"
20145	//     },
20146	//     "includeAdvertisersWithoutGroupsOnly": {
20147	//       "description": "Select only advertisers which do not belong to any advertiser group.",
20148	//       "location": "query",
20149	//       "type": "boolean"
20150	//     },
20151	//     "maxResults": {
20152	//       "default": "1000",
20153	//       "description": "Maximum number of results to return.",
20154	//       "format": "int32",
20155	//       "location": "query",
20156	//       "maximum": "1000",
20157	//       "minimum": "0",
20158	//       "type": "integer"
20159	//     },
20160	//     "onlyParent": {
20161	//       "description": "Select only advertisers which use another advertiser's floodlight configuration.",
20162	//       "location": "query",
20163	//       "type": "boolean"
20164	//     },
20165	//     "pageToken": {
20166	//       "description": "Value of the nextPageToken from the previous result page.",
20167	//       "location": "query",
20168	//       "type": "string"
20169	//     },
20170	//     "profileId": {
20171	//       "description": "User profile ID associated with this request.",
20172	//       "format": "int64",
20173	//       "location": "path",
20174	//       "required": true,
20175	//       "type": "string"
20176	//     },
20177	//     "searchString": {
20178	//       "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\".",
20179	//       "location": "query",
20180	//       "type": "string"
20181	//     },
20182	//     "sortField": {
20183	//       "default": "ID",
20184	//       "description": "Field by which to sort the list.",
20185	//       "enum": [
20186	//         "ID",
20187	//         "NAME"
20188	//       ],
20189	//       "enumDescriptions": [
20190	//         "",
20191	//         ""
20192	//       ],
20193	//       "location": "query",
20194	//       "type": "string"
20195	//     },
20196	//     "sortOrder": {
20197	//       "default": "ASCENDING",
20198	//       "description": "Order of sorted results.",
20199	//       "enum": [
20200	//         "ASCENDING",
20201	//         "DESCENDING"
20202	//       ],
20203	//       "enumDescriptions": [
20204	//         "",
20205	//         ""
20206	//       ],
20207	//       "location": "query",
20208	//       "type": "string"
20209	//     },
20210	//     "status": {
20211	//       "description": "Select only advertisers with the specified status.",
20212	//       "enum": [
20213	//         "APPROVED",
20214	//         "ON_HOLD"
20215	//       ],
20216	//       "enumDescriptions": [
20217	//         "",
20218	//         ""
20219	//       ],
20220	//       "location": "query",
20221	//       "type": "string"
20222	//     },
20223	//     "subaccountId": {
20224	//       "description": "Select only advertisers with these subaccount IDs.",
20225	//       "format": "int64",
20226	//       "location": "query",
20227	//       "type": "string"
20228	//     }
20229	//   },
20230	//   "path": "userprofiles/{profileId}/advertisers",
20231	//   "response": {
20232	//     "$ref": "AdvertisersListResponse"
20233	//   },
20234	//   "scopes": [
20235	//     "https://www.googleapis.com/auth/dfatrafficking"
20236	//   ]
20237	// }
20238
20239}
20240
20241// Pages invokes f for each page of results.
20242// A non-nil error returned from f will halt the iteration.
20243// The provided context supersedes any context provided to the Context method.
20244func (c *AdvertisersListCall) Pages(ctx context.Context, f func(*AdvertisersListResponse) error) error {
20245	c.ctx_ = ctx
20246	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
20247	for {
20248		x, err := c.Do()
20249		if err != nil {
20250			return err
20251		}
20252		if err := f(x); err != nil {
20253			return err
20254		}
20255		if x.NextPageToken == "" {
20256			return nil
20257		}
20258		c.PageToken(x.NextPageToken)
20259	}
20260}
20261
20262// method id "dfareporting.advertisers.patch":
20263
20264type AdvertisersPatchCall struct {
20265	s          *Service
20266	profileId  int64
20267	advertiser *Advertiser
20268	urlParams_ gensupport.URLParams
20269	ctx_       context.Context
20270	header_    http.Header
20271}
20272
20273// Patch: Updates an existing advertiser. This method supports patch
20274// semantics.
20275func (r *AdvertisersService) Patch(profileId int64, id int64, advertiser *Advertiser) *AdvertisersPatchCall {
20276	c := &AdvertisersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20277	c.profileId = profileId
20278	c.urlParams_.Set("id", fmt.Sprint(id))
20279	c.advertiser = advertiser
20280	return c
20281}
20282
20283// Fields allows partial responses to be retrieved. See
20284// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20285// for more information.
20286func (c *AdvertisersPatchCall) Fields(s ...googleapi.Field) *AdvertisersPatchCall {
20287	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20288	return c
20289}
20290
20291// Context sets the context to be used in this call's Do method. Any
20292// pending HTTP request will be aborted if the provided context is
20293// canceled.
20294func (c *AdvertisersPatchCall) Context(ctx context.Context) *AdvertisersPatchCall {
20295	c.ctx_ = ctx
20296	return c
20297}
20298
20299// Header returns an http.Header that can be modified by the caller to
20300// add HTTP headers to the request.
20301func (c *AdvertisersPatchCall) Header() http.Header {
20302	if c.header_ == nil {
20303		c.header_ = make(http.Header)
20304	}
20305	return c.header_
20306}
20307
20308func (c *AdvertisersPatchCall) doRequest(alt string) (*http.Response, error) {
20309	reqHeaders := make(http.Header)
20310	for k, v := range c.header_ {
20311		reqHeaders[k] = v
20312	}
20313	reqHeaders.Set("User-Agent", c.s.userAgent())
20314	var body io.Reader = nil
20315	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
20316	if err != nil {
20317		return nil, err
20318	}
20319	reqHeaders.Set("Content-Type", "application/json")
20320	c.urlParams_.Set("alt", alt)
20321	c.urlParams_.Set("prettyPrint", "false")
20322	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20323	urls += "?" + c.urlParams_.Encode()
20324	req, err := http.NewRequest("PATCH", urls, body)
20325	if err != nil {
20326		return nil, err
20327	}
20328	req.Header = reqHeaders
20329	googleapi.Expand(req.URL, map[string]string{
20330		"profileId": strconv.FormatInt(c.profileId, 10),
20331	})
20332	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20333}
20334
20335// Do executes the "dfareporting.advertisers.patch" call.
20336// Exactly one of *Advertiser or error will be non-nil. Any non-2xx
20337// status code is an error. Response headers are in either
20338// *Advertiser.ServerResponse.Header or (if a response was returned at
20339// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
20340// to check whether the returned error was because
20341// http.StatusNotModified was returned.
20342func (c *AdvertisersPatchCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
20343	gensupport.SetOptions(c.urlParams_, opts...)
20344	res, err := c.doRequest("json")
20345	if res != nil && res.StatusCode == http.StatusNotModified {
20346		if res.Body != nil {
20347			res.Body.Close()
20348		}
20349		return nil, &googleapi.Error{
20350			Code:   res.StatusCode,
20351			Header: res.Header,
20352		}
20353	}
20354	if err != nil {
20355		return nil, err
20356	}
20357	defer googleapi.CloseBody(res)
20358	if err := googleapi.CheckResponse(res); err != nil {
20359		return nil, err
20360	}
20361	ret := &Advertiser{
20362		ServerResponse: googleapi.ServerResponse{
20363			Header:         res.Header,
20364			HTTPStatusCode: res.StatusCode,
20365		},
20366	}
20367	target := &ret
20368	if err := gensupport.DecodeResponse(target, res); err != nil {
20369		return nil, err
20370	}
20371	return ret, nil
20372	// {
20373	//   "description": "Updates an existing advertiser. This method supports patch semantics.",
20374	//   "httpMethod": "PATCH",
20375	//   "id": "dfareporting.advertisers.patch",
20376	//   "parameterOrder": [
20377	//     "profileId",
20378	//     "id"
20379	//   ],
20380	//   "parameters": {
20381	//     "id": {
20382	//       "description": "Advertiser ID.",
20383	//       "format": "int64",
20384	//       "location": "query",
20385	//       "required": true,
20386	//       "type": "string"
20387	//     },
20388	//     "profileId": {
20389	//       "description": "User profile ID associated with this request.",
20390	//       "format": "int64",
20391	//       "location": "path",
20392	//       "required": true,
20393	//       "type": "string"
20394	//     }
20395	//   },
20396	//   "path": "userprofiles/{profileId}/advertisers",
20397	//   "request": {
20398	//     "$ref": "Advertiser"
20399	//   },
20400	//   "response": {
20401	//     "$ref": "Advertiser"
20402	//   },
20403	//   "scopes": [
20404	//     "https://www.googleapis.com/auth/dfatrafficking"
20405	//   ]
20406	// }
20407
20408}
20409
20410// method id "dfareporting.advertisers.update":
20411
20412type AdvertisersUpdateCall struct {
20413	s          *Service
20414	profileId  int64
20415	advertiser *Advertiser
20416	urlParams_ gensupport.URLParams
20417	ctx_       context.Context
20418	header_    http.Header
20419}
20420
20421// Update: Updates an existing advertiser.
20422func (r *AdvertisersService) Update(profileId int64, advertiser *Advertiser) *AdvertisersUpdateCall {
20423	c := &AdvertisersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20424	c.profileId = profileId
20425	c.advertiser = advertiser
20426	return c
20427}
20428
20429// Fields allows partial responses to be retrieved. See
20430// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20431// for more information.
20432func (c *AdvertisersUpdateCall) Fields(s ...googleapi.Field) *AdvertisersUpdateCall {
20433	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20434	return c
20435}
20436
20437// Context sets the context to be used in this call's Do method. Any
20438// pending HTTP request will be aborted if the provided context is
20439// canceled.
20440func (c *AdvertisersUpdateCall) Context(ctx context.Context) *AdvertisersUpdateCall {
20441	c.ctx_ = ctx
20442	return c
20443}
20444
20445// Header returns an http.Header that can be modified by the caller to
20446// add HTTP headers to the request.
20447func (c *AdvertisersUpdateCall) Header() http.Header {
20448	if c.header_ == nil {
20449		c.header_ = make(http.Header)
20450	}
20451	return c.header_
20452}
20453
20454func (c *AdvertisersUpdateCall) doRequest(alt string) (*http.Response, error) {
20455	reqHeaders := make(http.Header)
20456	for k, v := range c.header_ {
20457		reqHeaders[k] = v
20458	}
20459	reqHeaders.Set("User-Agent", c.s.userAgent())
20460	var body io.Reader = nil
20461	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
20462	if err != nil {
20463		return nil, err
20464	}
20465	reqHeaders.Set("Content-Type", "application/json")
20466	c.urlParams_.Set("alt", alt)
20467	c.urlParams_.Set("prettyPrint", "false")
20468	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20469	urls += "?" + c.urlParams_.Encode()
20470	req, err := http.NewRequest("PUT", urls, body)
20471	if err != nil {
20472		return nil, err
20473	}
20474	req.Header = reqHeaders
20475	googleapi.Expand(req.URL, map[string]string{
20476		"profileId": strconv.FormatInt(c.profileId, 10),
20477	})
20478	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20479}
20480
20481// Do executes the "dfareporting.advertisers.update" call.
20482// Exactly one of *Advertiser or error will be non-nil. Any non-2xx
20483// status code is an error. Response headers are in either
20484// *Advertiser.ServerResponse.Header or (if a response was returned at
20485// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
20486// to check whether the returned error was because
20487// http.StatusNotModified was returned.
20488func (c *AdvertisersUpdateCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
20489	gensupport.SetOptions(c.urlParams_, opts...)
20490	res, err := c.doRequest("json")
20491	if res != nil && res.StatusCode == http.StatusNotModified {
20492		if res.Body != nil {
20493			res.Body.Close()
20494		}
20495		return nil, &googleapi.Error{
20496			Code:   res.StatusCode,
20497			Header: res.Header,
20498		}
20499	}
20500	if err != nil {
20501		return nil, err
20502	}
20503	defer googleapi.CloseBody(res)
20504	if err := googleapi.CheckResponse(res); err != nil {
20505		return nil, err
20506	}
20507	ret := &Advertiser{
20508		ServerResponse: googleapi.ServerResponse{
20509			Header:         res.Header,
20510			HTTPStatusCode: res.StatusCode,
20511		},
20512	}
20513	target := &ret
20514	if err := gensupport.DecodeResponse(target, res); err != nil {
20515		return nil, err
20516	}
20517	return ret, nil
20518	// {
20519	//   "description": "Updates an existing advertiser.",
20520	//   "httpMethod": "PUT",
20521	//   "id": "dfareporting.advertisers.update",
20522	//   "parameterOrder": [
20523	//     "profileId"
20524	//   ],
20525	//   "parameters": {
20526	//     "profileId": {
20527	//       "description": "User profile ID associated with this request.",
20528	//       "format": "int64",
20529	//       "location": "path",
20530	//       "required": true,
20531	//       "type": "string"
20532	//     }
20533	//   },
20534	//   "path": "userprofiles/{profileId}/advertisers",
20535	//   "request": {
20536	//     "$ref": "Advertiser"
20537	//   },
20538	//   "response": {
20539	//     "$ref": "Advertiser"
20540	//   },
20541	//   "scopes": [
20542	//     "https://www.googleapis.com/auth/dfatrafficking"
20543	//   ]
20544	// }
20545
20546}
20547
20548// method id "dfareporting.browsers.list":
20549
20550type BrowsersListCall struct {
20551	s            *Service
20552	profileId    int64
20553	urlParams_   gensupport.URLParams
20554	ifNoneMatch_ string
20555	ctx_         context.Context
20556	header_      http.Header
20557}
20558
20559// List: Retrieves a list of browsers.
20560func (r *BrowsersService) List(profileId int64) *BrowsersListCall {
20561	c := &BrowsersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20562	c.profileId = profileId
20563	return c
20564}
20565
20566// Fields allows partial responses to be retrieved. See
20567// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20568// for more information.
20569func (c *BrowsersListCall) Fields(s ...googleapi.Field) *BrowsersListCall {
20570	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20571	return c
20572}
20573
20574// IfNoneMatch sets the optional parameter which makes the operation
20575// fail if the object's ETag matches the given value. This is useful for
20576// getting updates only after the object has changed since the last
20577// request. Use googleapi.IsNotModified to check whether the response
20578// error from Do is the result of In-None-Match.
20579func (c *BrowsersListCall) IfNoneMatch(entityTag string) *BrowsersListCall {
20580	c.ifNoneMatch_ = entityTag
20581	return c
20582}
20583
20584// Context sets the context to be used in this call's Do method. Any
20585// pending HTTP request will be aborted if the provided context is
20586// canceled.
20587func (c *BrowsersListCall) Context(ctx context.Context) *BrowsersListCall {
20588	c.ctx_ = ctx
20589	return c
20590}
20591
20592// Header returns an http.Header that can be modified by the caller to
20593// add HTTP headers to the request.
20594func (c *BrowsersListCall) Header() http.Header {
20595	if c.header_ == nil {
20596		c.header_ = make(http.Header)
20597	}
20598	return c.header_
20599}
20600
20601func (c *BrowsersListCall) doRequest(alt string) (*http.Response, error) {
20602	reqHeaders := make(http.Header)
20603	for k, v := range c.header_ {
20604		reqHeaders[k] = v
20605	}
20606	reqHeaders.Set("User-Agent", c.s.userAgent())
20607	if c.ifNoneMatch_ != "" {
20608		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20609	}
20610	var body io.Reader = nil
20611	c.urlParams_.Set("alt", alt)
20612	c.urlParams_.Set("prettyPrint", "false")
20613	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/browsers")
20614	urls += "?" + c.urlParams_.Encode()
20615	req, err := http.NewRequest("GET", urls, body)
20616	if err != nil {
20617		return nil, err
20618	}
20619	req.Header = reqHeaders
20620	googleapi.Expand(req.URL, map[string]string{
20621		"profileId": strconv.FormatInt(c.profileId, 10),
20622	})
20623	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20624}
20625
20626// Do executes the "dfareporting.browsers.list" call.
20627// Exactly one of *BrowsersListResponse or error will be non-nil. Any
20628// non-2xx status code is an error. Response headers are in either
20629// *BrowsersListResponse.ServerResponse.Header or (if a response was
20630// returned at all) in error.(*googleapi.Error).Header. Use
20631// googleapi.IsNotModified to check whether the returned error was
20632// because http.StatusNotModified was returned.
20633func (c *BrowsersListCall) Do(opts ...googleapi.CallOption) (*BrowsersListResponse, error) {
20634	gensupport.SetOptions(c.urlParams_, opts...)
20635	res, err := c.doRequest("json")
20636	if res != nil && res.StatusCode == http.StatusNotModified {
20637		if res.Body != nil {
20638			res.Body.Close()
20639		}
20640		return nil, &googleapi.Error{
20641			Code:   res.StatusCode,
20642			Header: res.Header,
20643		}
20644	}
20645	if err != nil {
20646		return nil, err
20647	}
20648	defer googleapi.CloseBody(res)
20649	if err := googleapi.CheckResponse(res); err != nil {
20650		return nil, err
20651	}
20652	ret := &BrowsersListResponse{
20653		ServerResponse: googleapi.ServerResponse{
20654			Header:         res.Header,
20655			HTTPStatusCode: res.StatusCode,
20656		},
20657	}
20658	target := &ret
20659	if err := gensupport.DecodeResponse(target, res); err != nil {
20660		return nil, err
20661	}
20662	return ret, nil
20663	// {
20664	//   "description": "Retrieves a list of browsers.",
20665	//   "httpMethod": "GET",
20666	//   "id": "dfareporting.browsers.list",
20667	//   "parameterOrder": [
20668	//     "profileId"
20669	//   ],
20670	//   "parameters": {
20671	//     "profileId": {
20672	//       "description": "User profile ID associated with this request.",
20673	//       "format": "int64",
20674	//       "location": "path",
20675	//       "required": true,
20676	//       "type": "string"
20677	//     }
20678	//   },
20679	//   "path": "userprofiles/{profileId}/browsers",
20680	//   "response": {
20681	//     "$ref": "BrowsersListResponse"
20682	//   },
20683	//   "scopes": [
20684	//     "https://www.googleapis.com/auth/dfatrafficking"
20685	//   ]
20686	// }
20687
20688}
20689
20690// method id "dfareporting.campaignCreativeAssociations.insert":
20691
20692type CampaignCreativeAssociationsInsertCall struct {
20693	s                           *Service
20694	profileId                   int64
20695	campaignId                  int64
20696	campaigncreativeassociation *CampaignCreativeAssociation
20697	urlParams_                  gensupport.URLParams
20698	ctx_                        context.Context
20699	header_                     http.Header
20700}
20701
20702// Insert: Associates a creative with the specified campaign. This
20703// method creates a default ad with dimensions matching the creative in
20704// the campaign if such a default ad does not exist already.
20705func (r *CampaignCreativeAssociationsService) Insert(profileId int64, campaignId int64, campaigncreativeassociation *CampaignCreativeAssociation) *CampaignCreativeAssociationsInsertCall {
20706	c := &CampaignCreativeAssociationsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20707	c.profileId = profileId
20708	c.campaignId = campaignId
20709	c.campaigncreativeassociation = campaigncreativeassociation
20710	return c
20711}
20712
20713// Fields allows partial responses to be retrieved. See
20714// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20715// for more information.
20716func (c *CampaignCreativeAssociationsInsertCall) Fields(s ...googleapi.Field) *CampaignCreativeAssociationsInsertCall {
20717	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20718	return c
20719}
20720
20721// Context sets the context to be used in this call's Do method. Any
20722// pending HTTP request will be aborted if the provided context is
20723// canceled.
20724func (c *CampaignCreativeAssociationsInsertCall) Context(ctx context.Context) *CampaignCreativeAssociationsInsertCall {
20725	c.ctx_ = ctx
20726	return c
20727}
20728
20729// Header returns an http.Header that can be modified by the caller to
20730// add HTTP headers to the request.
20731func (c *CampaignCreativeAssociationsInsertCall) Header() http.Header {
20732	if c.header_ == nil {
20733		c.header_ = make(http.Header)
20734	}
20735	return c.header_
20736}
20737
20738func (c *CampaignCreativeAssociationsInsertCall) doRequest(alt string) (*http.Response, error) {
20739	reqHeaders := make(http.Header)
20740	for k, v := range c.header_ {
20741		reqHeaders[k] = v
20742	}
20743	reqHeaders.Set("User-Agent", c.s.userAgent())
20744	var body io.Reader = nil
20745	body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaigncreativeassociation)
20746	if err != nil {
20747		return nil, err
20748	}
20749	reqHeaders.Set("Content-Type", "application/json")
20750	c.urlParams_.Set("alt", alt)
20751	c.urlParams_.Set("prettyPrint", "false")
20752	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations")
20753	urls += "?" + c.urlParams_.Encode()
20754	req, err := http.NewRequest("POST", urls, body)
20755	if err != nil {
20756		return nil, err
20757	}
20758	req.Header = reqHeaders
20759	googleapi.Expand(req.URL, map[string]string{
20760		"profileId":  strconv.FormatInt(c.profileId, 10),
20761		"campaignId": strconv.FormatInt(c.campaignId, 10),
20762	})
20763	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20764}
20765
20766// Do executes the "dfareporting.campaignCreativeAssociations.insert" call.
20767// Exactly one of *CampaignCreativeAssociation or error will be non-nil.
20768// Any non-2xx status code is an error. Response headers are in either
20769// *CampaignCreativeAssociation.ServerResponse.Header or (if a response
20770// was returned at all) in error.(*googleapi.Error).Header. Use
20771// googleapi.IsNotModified to check whether the returned error was
20772// because http.StatusNotModified was returned.
20773func (c *CampaignCreativeAssociationsInsertCall) Do(opts ...googleapi.CallOption) (*CampaignCreativeAssociation, error) {
20774	gensupport.SetOptions(c.urlParams_, opts...)
20775	res, err := c.doRequest("json")
20776	if res != nil && res.StatusCode == http.StatusNotModified {
20777		if res.Body != nil {
20778			res.Body.Close()
20779		}
20780		return nil, &googleapi.Error{
20781			Code:   res.StatusCode,
20782			Header: res.Header,
20783		}
20784	}
20785	if err != nil {
20786		return nil, err
20787	}
20788	defer googleapi.CloseBody(res)
20789	if err := googleapi.CheckResponse(res); err != nil {
20790		return nil, err
20791	}
20792	ret := &CampaignCreativeAssociation{
20793		ServerResponse: googleapi.ServerResponse{
20794			Header:         res.Header,
20795			HTTPStatusCode: res.StatusCode,
20796		},
20797	}
20798	target := &ret
20799	if err := gensupport.DecodeResponse(target, res); err != nil {
20800		return nil, err
20801	}
20802	return ret, nil
20803	// {
20804	//   "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.",
20805	//   "httpMethod": "POST",
20806	//   "id": "dfareporting.campaignCreativeAssociations.insert",
20807	//   "parameterOrder": [
20808	//     "profileId",
20809	//     "campaignId"
20810	//   ],
20811	//   "parameters": {
20812	//     "campaignId": {
20813	//       "description": "Campaign ID in this association.",
20814	//       "format": "int64",
20815	//       "location": "path",
20816	//       "required": true,
20817	//       "type": "string"
20818	//     },
20819	//     "profileId": {
20820	//       "description": "User profile ID associated with this request.",
20821	//       "format": "int64",
20822	//       "location": "path",
20823	//       "required": true,
20824	//       "type": "string"
20825	//     }
20826	//   },
20827	//   "path": "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations",
20828	//   "request": {
20829	//     "$ref": "CampaignCreativeAssociation"
20830	//   },
20831	//   "response": {
20832	//     "$ref": "CampaignCreativeAssociation"
20833	//   },
20834	//   "scopes": [
20835	//     "https://www.googleapis.com/auth/dfatrafficking"
20836	//   ]
20837	// }
20838
20839}
20840
20841// method id "dfareporting.campaignCreativeAssociations.list":
20842
20843type CampaignCreativeAssociationsListCall struct {
20844	s            *Service
20845	profileId    int64
20846	campaignId   int64
20847	urlParams_   gensupport.URLParams
20848	ifNoneMatch_ string
20849	ctx_         context.Context
20850	header_      http.Header
20851}
20852
20853// List: Retrieves the list of creative IDs associated with the
20854// specified campaign. This method supports paging.
20855func (r *CampaignCreativeAssociationsService) List(profileId int64, campaignId int64) *CampaignCreativeAssociationsListCall {
20856	c := &CampaignCreativeAssociationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20857	c.profileId = profileId
20858	c.campaignId = campaignId
20859	return c
20860}
20861
20862// MaxResults sets the optional parameter "maxResults": Maximum number
20863// of results to return.
20864func (c *CampaignCreativeAssociationsListCall) MaxResults(maxResults int64) *CampaignCreativeAssociationsListCall {
20865	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
20866	return c
20867}
20868
20869// PageToken sets the optional parameter "pageToken": Value of the
20870// nextPageToken from the previous result page.
20871func (c *CampaignCreativeAssociationsListCall) PageToken(pageToken string) *CampaignCreativeAssociationsListCall {
20872	c.urlParams_.Set("pageToken", pageToken)
20873	return c
20874}
20875
20876// SortOrder sets the optional parameter "sortOrder": Order of sorted
20877// results.
20878//
20879// Possible values:
20880//   "ASCENDING" (default)
20881//   "DESCENDING"
20882func (c *CampaignCreativeAssociationsListCall) SortOrder(sortOrder string) *CampaignCreativeAssociationsListCall {
20883	c.urlParams_.Set("sortOrder", sortOrder)
20884	return c
20885}
20886
20887// Fields allows partial responses to be retrieved. See
20888// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20889// for more information.
20890func (c *CampaignCreativeAssociationsListCall) Fields(s ...googleapi.Field) *CampaignCreativeAssociationsListCall {
20891	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20892	return c
20893}
20894
20895// IfNoneMatch sets the optional parameter which makes the operation
20896// fail if the object's ETag matches the given value. This is useful for
20897// getting updates only after the object has changed since the last
20898// request. Use googleapi.IsNotModified to check whether the response
20899// error from Do is the result of In-None-Match.
20900func (c *CampaignCreativeAssociationsListCall) IfNoneMatch(entityTag string) *CampaignCreativeAssociationsListCall {
20901	c.ifNoneMatch_ = entityTag
20902	return c
20903}
20904
20905// Context sets the context to be used in this call's Do method. Any
20906// pending HTTP request will be aborted if the provided context is
20907// canceled.
20908func (c *CampaignCreativeAssociationsListCall) Context(ctx context.Context) *CampaignCreativeAssociationsListCall {
20909	c.ctx_ = ctx
20910	return c
20911}
20912
20913// Header returns an http.Header that can be modified by the caller to
20914// add HTTP headers to the request.
20915func (c *CampaignCreativeAssociationsListCall) Header() http.Header {
20916	if c.header_ == nil {
20917		c.header_ = make(http.Header)
20918	}
20919	return c.header_
20920}
20921
20922func (c *CampaignCreativeAssociationsListCall) doRequest(alt string) (*http.Response, error) {
20923	reqHeaders := make(http.Header)
20924	for k, v := range c.header_ {
20925		reqHeaders[k] = v
20926	}
20927	reqHeaders.Set("User-Agent", c.s.userAgent())
20928	if c.ifNoneMatch_ != "" {
20929		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20930	}
20931	var body io.Reader = nil
20932	c.urlParams_.Set("alt", alt)
20933	c.urlParams_.Set("prettyPrint", "false")
20934	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations")
20935	urls += "?" + c.urlParams_.Encode()
20936	req, err := http.NewRequest("GET", urls, body)
20937	if err != nil {
20938		return nil, err
20939	}
20940	req.Header = reqHeaders
20941	googleapi.Expand(req.URL, map[string]string{
20942		"profileId":  strconv.FormatInt(c.profileId, 10),
20943		"campaignId": strconv.FormatInt(c.campaignId, 10),
20944	})
20945	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20946}
20947
20948// Do executes the "dfareporting.campaignCreativeAssociations.list" call.
20949// Exactly one of *CampaignCreativeAssociationsListResponse or error
20950// will be non-nil. Any non-2xx status code is an error. Response
20951// headers are in either
20952// *CampaignCreativeAssociationsListResponse.ServerResponse.Header or
20953// (if a response was returned at all) in
20954// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20955// whether the returned error was because http.StatusNotModified was
20956// returned.
20957func (c *CampaignCreativeAssociationsListCall) Do(opts ...googleapi.CallOption) (*CampaignCreativeAssociationsListResponse, error) {
20958	gensupport.SetOptions(c.urlParams_, opts...)
20959	res, err := c.doRequest("json")
20960	if res != nil && res.StatusCode == http.StatusNotModified {
20961		if res.Body != nil {
20962			res.Body.Close()
20963		}
20964		return nil, &googleapi.Error{
20965			Code:   res.StatusCode,
20966			Header: res.Header,
20967		}
20968	}
20969	if err != nil {
20970		return nil, err
20971	}
20972	defer googleapi.CloseBody(res)
20973	if err := googleapi.CheckResponse(res); err != nil {
20974		return nil, err
20975	}
20976	ret := &CampaignCreativeAssociationsListResponse{
20977		ServerResponse: googleapi.ServerResponse{
20978			Header:         res.Header,
20979			HTTPStatusCode: res.StatusCode,
20980		},
20981	}
20982	target := &ret
20983	if err := gensupport.DecodeResponse(target, res); err != nil {
20984		return nil, err
20985	}
20986	return ret, nil
20987	// {
20988	//   "description": "Retrieves the list of creative IDs associated with the specified campaign. This method supports paging.",
20989	//   "httpMethod": "GET",
20990	//   "id": "dfareporting.campaignCreativeAssociations.list",
20991	//   "parameterOrder": [
20992	//     "profileId",
20993	//     "campaignId"
20994	//   ],
20995	//   "parameters": {
20996	//     "campaignId": {
20997	//       "description": "Campaign ID in this association.",
20998	//       "format": "int64",
20999	//       "location": "path",
21000	//       "required": true,
21001	//       "type": "string"
21002	//     },
21003	//     "maxResults": {
21004	//       "default": "1000",
21005	//       "description": "Maximum number of results to return.",
21006	//       "format": "int32",
21007	//       "location": "query",
21008	//       "maximum": "1000",
21009	//       "minimum": "0",
21010	//       "type": "integer"
21011	//     },
21012	//     "pageToken": {
21013	//       "description": "Value of the nextPageToken from the previous result page.",
21014	//       "location": "query",
21015	//       "type": "string"
21016	//     },
21017	//     "profileId": {
21018	//       "description": "User profile ID associated with this request.",
21019	//       "format": "int64",
21020	//       "location": "path",
21021	//       "required": true,
21022	//       "type": "string"
21023	//     },
21024	//     "sortOrder": {
21025	//       "default": "ASCENDING",
21026	//       "description": "Order of sorted results.",
21027	//       "enum": [
21028	//         "ASCENDING",
21029	//         "DESCENDING"
21030	//       ],
21031	//       "enumDescriptions": [
21032	//         "",
21033	//         ""
21034	//       ],
21035	//       "location": "query",
21036	//       "type": "string"
21037	//     }
21038	//   },
21039	//   "path": "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations",
21040	//   "response": {
21041	//     "$ref": "CampaignCreativeAssociationsListResponse"
21042	//   },
21043	//   "scopes": [
21044	//     "https://www.googleapis.com/auth/dfatrafficking"
21045	//   ]
21046	// }
21047
21048}
21049
21050// Pages invokes f for each page of results.
21051// A non-nil error returned from f will halt the iteration.
21052// The provided context supersedes any context provided to the Context method.
21053func (c *CampaignCreativeAssociationsListCall) Pages(ctx context.Context, f func(*CampaignCreativeAssociationsListResponse) error) error {
21054	c.ctx_ = ctx
21055	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
21056	for {
21057		x, err := c.Do()
21058		if err != nil {
21059			return err
21060		}
21061		if err := f(x); err != nil {
21062			return err
21063		}
21064		if x.NextPageToken == "" {
21065			return nil
21066		}
21067		c.PageToken(x.NextPageToken)
21068	}
21069}
21070
21071// method id "dfareporting.campaigns.get":
21072
21073type CampaignsGetCall struct {
21074	s            *Service
21075	profileId    int64
21076	id           int64
21077	urlParams_   gensupport.URLParams
21078	ifNoneMatch_ string
21079	ctx_         context.Context
21080	header_      http.Header
21081}
21082
21083// Get: Gets one campaign by ID.
21084func (r *CampaignsService) Get(profileId int64, id int64) *CampaignsGetCall {
21085	c := &CampaignsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21086	c.profileId = profileId
21087	c.id = id
21088	return c
21089}
21090
21091// Fields allows partial responses to be retrieved. See
21092// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21093// for more information.
21094func (c *CampaignsGetCall) Fields(s ...googleapi.Field) *CampaignsGetCall {
21095	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21096	return c
21097}
21098
21099// IfNoneMatch sets the optional parameter which makes the operation
21100// fail if the object's ETag matches the given value. This is useful for
21101// getting updates only after the object has changed since the last
21102// request. Use googleapi.IsNotModified to check whether the response
21103// error from Do is the result of In-None-Match.
21104func (c *CampaignsGetCall) IfNoneMatch(entityTag string) *CampaignsGetCall {
21105	c.ifNoneMatch_ = entityTag
21106	return c
21107}
21108
21109// Context sets the context to be used in this call's Do method. Any
21110// pending HTTP request will be aborted if the provided context is
21111// canceled.
21112func (c *CampaignsGetCall) Context(ctx context.Context) *CampaignsGetCall {
21113	c.ctx_ = ctx
21114	return c
21115}
21116
21117// Header returns an http.Header that can be modified by the caller to
21118// add HTTP headers to the request.
21119func (c *CampaignsGetCall) Header() http.Header {
21120	if c.header_ == nil {
21121		c.header_ = make(http.Header)
21122	}
21123	return c.header_
21124}
21125
21126func (c *CampaignsGetCall) doRequest(alt string) (*http.Response, error) {
21127	reqHeaders := make(http.Header)
21128	for k, v := range c.header_ {
21129		reqHeaders[k] = v
21130	}
21131	reqHeaders.Set("User-Agent", c.s.userAgent())
21132	if c.ifNoneMatch_ != "" {
21133		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21134	}
21135	var body io.Reader = nil
21136	c.urlParams_.Set("alt", alt)
21137	c.urlParams_.Set("prettyPrint", "false")
21138	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{id}")
21139	urls += "?" + c.urlParams_.Encode()
21140	req, err := http.NewRequest("GET", urls, body)
21141	if err != nil {
21142		return nil, err
21143	}
21144	req.Header = reqHeaders
21145	googleapi.Expand(req.URL, map[string]string{
21146		"profileId": strconv.FormatInt(c.profileId, 10),
21147		"id":        strconv.FormatInt(c.id, 10),
21148	})
21149	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21150}
21151
21152// Do executes the "dfareporting.campaigns.get" call.
21153// Exactly one of *Campaign or error will be non-nil. Any non-2xx status
21154// code is an error. Response headers are in either
21155// *Campaign.ServerResponse.Header or (if a response was returned at
21156// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
21157// to check whether the returned error was because
21158// http.StatusNotModified was returned.
21159func (c *CampaignsGetCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21160	gensupport.SetOptions(c.urlParams_, opts...)
21161	res, err := c.doRequest("json")
21162	if res != nil && res.StatusCode == http.StatusNotModified {
21163		if res.Body != nil {
21164			res.Body.Close()
21165		}
21166		return nil, &googleapi.Error{
21167			Code:   res.StatusCode,
21168			Header: res.Header,
21169		}
21170	}
21171	if err != nil {
21172		return nil, err
21173	}
21174	defer googleapi.CloseBody(res)
21175	if err := googleapi.CheckResponse(res); err != nil {
21176		return nil, err
21177	}
21178	ret := &Campaign{
21179		ServerResponse: googleapi.ServerResponse{
21180			Header:         res.Header,
21181			HTTPStatusCode: res.StatusCode,
21182		},
21183	}
21184	target := &ret
21185	if err := gensupport.DecodeResponse(target, res); err != nil {
21186		return nil, err
21187	}
21188	return ret, nil
21189	// {
21190	//   "description": "Gets one campaign by ID.",
21191	//   "httpMethod": "GET",
21192	//   "id": "dfareporting.campaigns.get",
21193	//   "parameterOrder": [
21194	//     "profileId",
21195	//     "id"
21196	//   ],
21197	//   "parameters": {
21198	//     "id": {
21199	//       "description": "Campaign ID.",
21200	//       "format": "int64",
21201	//       "location": "path",
21202	//       "required": true,
21203	//       "type": "string"
21204	//     },
21205	//     "profileId": {
21206	//       "description": "User profile ID associated with this request.",
21207	//       "format": "int64",
21208	//       "location": "path",
21209	//       "required": true,
21210	//       "type": "string"
21211	//     }
21212	//   },
21213	//   "path": "userprofiles/{profileId}/campaigns/{id}",
21214	//   "response": {
21215	//     "$ref": "Campaign"
21216	//   },
21217	//   "scopes": [
21218	//     "https://www.googleapis.com/auth/dfatrafficking"
21219	//   ]
21220	// }
21221
21222}
21223
21224// method id "dfareporting.campaigns.insert":
21225
21226type CampaignsInsertCall struct {
21227	s          *Service
21228	profileId  int64
21229	campaign   *Campaign
21230	urlParams_ gensupport.URLParams
21231	ctx_       context.Context
21232	header_    http.Header
21233}
21234
21235// Insert: Inserts a new campaign.
21236func (r *CampaignsService) Insert(profileId int64, campaign *Campaign) *CampaignsInsertCall {
21237	c := &CampaignsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21238	c.profileId = profileId
21239	c.campaign = campaign
21240	return c
21241}
21242
21243// Fields allows partial responses to be retrieved. See
21244// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21245// for more information.
21246func (c *CampaignsInsertCall) Fields(s ...googleapi.Field) *CampaignsInsertCall {
21247	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21248	return c
21249}
21250
21251// Context sets the context to be used in this call's Do method. Any
21252// pending HTTP request will be aborted if the provided context is
21253// canceled.
21254func (c *CampaignsInsertCall) Context(ctx context.Context) *CampaignsInsertCall {
21255	c.ctx_ = ctx
21256	return c
21257}
21258
21259// Header returns an http.Header that can be modified by the caller to
21260// add HTTP headers to the request.
21261func (c *CampaignsInsertCall) Header() http.Header {
21262	if c.header_ == nil {
21263		c.header_ = make(http.Header)
21264	}
21265	return c.header_
21266}
21267
21268func (c *CampaignsInsertCall) doRequest(alt string) (*http.Response, error) {
21269	reqHeaders := make(http.Header)
21270	for k, v := range c.header_ {
21271		reqHeaders[k] = v
21272	}
21273	reqHeaders.Set("User-Agent", c.s.userAgent())
21274	var body io.Reader = nil
21275	body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
21276	if err != nil {
21277		return nil, err
21278	}
21279	reqHeaders.Set("Content-Type", "application/json")
21280	c.urlParams_.Set("alt", alt)
21281	c.urlParams_.Set("prettyPrint", "false")
21282	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21283	urls += "?" + c.urlParams_.Encode()
21284	req, err := http.NewRequest("POST", urls, body)
21285	if err != nil {
21286		return nil, err
21287	}
21288	req.Header = reqHeaders
21289	googleapi.Expand(req.URL, map[string]string{
21290		"profileId": strconv.FormatInt(c.profileId, 10),
21291	})
21292	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21293}
21294
21295// Do executes the "dfareporting.campaigns.insert" call.
21296// Exactly one of *Campaign or error will be non-nil. Any non-2xx status
21297// code is an error. Response headers are in either
21298// *Campaign.ServerResponse.Header or (if a response was returned at
21299// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
21300// to check whether the returned error was because
21301// http.StatusNotModified was returned.
21302func (c *CampaignsInsertCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21303	gensupport.SetOptions(c.urlParams_, opts...)
21304	res, err := c.doRequest("json")
21305	if res != nil && res.StatusCode == http.StatusNotModified {
21306		if res.Body != nil {
21307			res.Body.Close()
21308		}
21309		return nil, &googleapi.Error{
21310			Code:   res.StatusCode,
21311			Header: res.Header,
21312		}
21313	}
21314	if err != nil {
21315		return nil, err
21316	}
21317	defer googleapi.CloseBody(res)
21318	if err := googleapi.CheckResponse(res); err != nil {
21319		return nil, err
21320	}
21321	ret := &Campaign{
21322		ServerResponse: googleapi.ServerResponse{
21323			Header:         res.Header,
21324			HTTPStatusCode: res.StatusCode,
21325		},
21326	}
21327	target := &ret
21328	if err := gensupport.DecodeResponse(target, res); err != nil {
21329		return nil, err
21330	}
21331	return ret, nil
21332	// {
21333	//   "description": "Inserts a new campaign.",
21334	//   "httpMethod": "POST",
21335	//   "id": "dfareporting.campaigns.insert",
21336	//   "parameterOrder": [
21337	//     "profileId"
21338	//   ],
21339	//   "parameters": {
21340	//     "profileId": {
21341	//       "description": "User profile ID associated with this request.",
21342	//       "format": "int64",
21343	//       "location": "path",
21344	//       "required": true,
21345	//       "type": "string"
21346	//     }
21347	//   },
21348	//   "path": "userprofiles/{profileId}/campaigns",
21349	//   "request": {
21350	//     "$ref": "Campaign"
21351	//   },
21352	//   "response": {
21353	//     "$ref": "Campaign"
21354	//   },
21355	//   "scopes": [
21356	//     "https://www.googleapis.com/auth/dfatrafficking"
21357	//   ]
21358	// }
21359
21360}
21361
21362// method id "dfareporting.campaigns.list":
21363
21364type CampaignsListCall struct {
21365	s            *Service
21366	profileId    int64
21367	urlParams_   gensupport.URLParams
21368	ifNoneMatch_ string
21369	ctx_         context.Context
21370	header_      http.Header
21371}
21372
21373// List: Retrieves a list of campaigns, possibly filtered. This method
21374// supports paging.
21375func (r *CampaignsService) List(profileId int64) *CampaignsListCall {
21376	c := &CampaignsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21377	c.profileId = profileId
21378	return c
21379}
21380
21381// AdvertiserGroupIds sets the optional parameter "advertiserGroupIds":
21382// Select only campaigns whose advertisers belong to these advertiser
21383// groups.
21384func (c *CampaignsListCall) AdvertiserGroupIds(advertiserGroupIds ...int64) *CampaignsListCall {
21385	var advertiserGroupIds_ []string
21386	for _, v := range advertiserGroupIds {
21387		advertiserGroupIds_ = append(advertiserGroupIds_, fmt.Sprint(v))
21388	}
21389	c.urlParams_.SetMulti("advertiserGroupIds", advertiserGroupIds_)
21390	return c
21391}
21392
21393// AdvertiserIds sets the optional parameter "advertiserIds": Select
21394// only campaigns that belong to these advertisers.
21395func (c *CampaignsListCall) AdvertiserIds(advertiserIds ...int64) *CampaignsListCall {
21396	var advertiserIds_ []string
21397	for _, v := range advertiserIds {
21398		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
21399	}
21400	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
21401	return c
21402}
21403
21404// Archived sets the optional parameter "archived": Select only archived
21405// campaigns. Don't set this field to select both archived and
21406// non-archived campaigns.
21407func (c *CampaignsListCall) Archived(archived bool) *CampaignsListCall {
21408	c.urlParams_.Set("archived", fmt.Sprint(archived))
21409	return c
21410}
21411
21412// AtLeastOneOptimizationActivity sets the optional parameter
21413// "atLeastOneOptimizationActivity": Select only campaigns that have at
21414// least one optimization activity.
21415func (c *CampaignsListCall) AtLeastOneOptimizationActivity(atLeastOneOptimizationActivity bool) *CampaignsListCall {
21416	c.urlParams_.Set("atLeastOneOptimizationActivity", fmt.Sprint(atLeastOneOptimizationActivity))
21417	return c
21418}
21419
21420// ExcludedIds sets the optional parameter "excludedIds": Exclude
21421// campaigns with these IDs.
21422func (c *CampaignsListCall) ExcludedIds(excludedIds ...int64) *CampaignsListCall {
21423	var excludedIds_ []string
21424	for _, v := range excludedIds {
21425		excludedIds_ = append(excludedIds_, fmt.Sprint(v))
21426	}
21427	c.urlParams_.SetMulti("excludedIds", excludedIds_)
21428	return c
21429}
21430
21431// Ids sets the optional parameter "ids": Select only campaigns with
21432// these IDs.
21433func (c *CampaignsListCall) Ids(ids ...int64) *CampaignsListCall {
21434	var ids_ []string
21435	for _, v := range ids {
21436		ids_ = append(ids_, fmt.Sprint(v))
21437	}
21438	c.urlParams_.SetMulti("ids", ids_)
21439	return c
21440}
21441
21442// MaxResults sets the optional parameter "maxResults": Maximum number
21443// of results to return.
21444func (c *CampaignsListCall) MaxResults(maxResults int64) *CampaignsListCall {
21445	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
21446	return c
21447}
21448
21449// OverriddenEventTagId sets the optional parameter
21450// "overriddenEventTagId": Select only campaigns that have overridden
21451// this event tag ID.
21452func (c *CampaignsListCall) OverriddenEventTagId(overriddenEventTagId int64) *CampaignsListCall {
21453	c.urlParams_.Set("overriddenEventTagId", fmt.Sprint(overriddenEventTagId))
21454	return c
21455}
21456
21457// PageToken sets the optional parameter "pageToken": Value of the
21458// nextPageToken from the previous result page.
21459func (c *CampaignsListCall) PageToken(pageToken string) *CampaignsListCall {
21460	c.urlParams_.Set("pageToken", pageToken)
21461	return c
21462}
21463
21464// SearchString sets the optional parameter "searchString": Allows
21465// searching for campaigns by name or ID. Wildcards (*) are allowed. For
21466// example, "campaign*2015" will return campaigns with names like
21467// "campaign June 2015", "campaign April 2015", or simply "campaign
21468// 2015". Most of the searches also add wildcards implicitly at the
21469// start and the end of the search string. For example, a search string
21470// of "campaign" will match campaigns with name "my campaign", "campaign
21471// 2015", or simply "campaign".
21472func (c *CampaignsListCall) SearchString(searchString string) *CampaignsListCall {
21473	c.urlParams_.Set("searchString", searchString)
21474	return c
21475}
21476
21477// SortField sets the optional parameter "sortField": Field by which to
21478// sort the list.
21479//
21480// Possible values:
21481//   "ID" (default)
21482//   "NAME"
21483func (c *CampaignsListCall) SortField(sortField string) *CampaignsListCall {
21484	c.urlParams_.Set("sortField", sortField)
21485	return c
21486}
21487
21488// SortOrder sets the optional parameter "sortOrder": Order of sorted
21489// results.
21490//
21491// Possible values:
21492//   "ASCENDING" (default)
21493//   "DESCENDING"
21494func (c *CampaignsListCall) SortOrder(sortOrder string) *CampaignsListCall {
21495	c.urlParams_.Set("sortOrder", sortOrder)
21496	return c
21497}
21498
21499// SubaccountId sets the optional parameter "subaccountId": Select only
21500// campaigns that belong to this subaccount.
21501func (c *CampaignsListCall) SubaccountId(subaccountId int64) *CampaignsListCall {
21502	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
21503	return c
21504}
21505
21506// Fields allows partial responses to be retrieved. See
21507// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21508// for more information.
21509func (c *CampaignsListCall) Fields(s ...googleapi.Field) *CampaignsListCall {
21510	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21511	return c
21512}
21513
21514// IfNoneMatch sets the optional parameter which makes the operation
21515// fail if the object's ETag matches the given value. This is useful for
21516// getting updates only after the object has changed since the last
21517// request. Use googleapi.IsNotModified to check whether the response
21518// error from Do is the result of In-None-Match.
21519func (c *CampaignsListCall) IfNoneMatch(entityTag string) *CampaignsListCall {
21520	c.ifNoneMatch_ = entityTag
21521	return c
21522}
21523
21524// Context sets the context to be used in this call's Do method. Any
21525// pending HTTP request will be aborted if the provided context is
21526// canceled.
21527func (c *CampaignsListCall) Context(ctx context.Context) *CampaignsListCall {
21528	c.ctx_ = ctx
21529	return c
21530}
21531
21532// Header returns an http.Header that can be modified by the caller to
21533// add HTTP headers to the request.
21534func (c *CampaignsListCall) Header() http.Header {
21535	if c.header_ == nil {
21536		c.header_ = make(http.Header)
21537	}
21538	return c.header_
21539}
21540
21541func (c *CampaignsListCall) doRequest(alt string) (*http.Response, error) {
21542	reqHeaders := make(http.Header)
21543	for k, v := range c.header_ {
21544		reqHeaders[k] = v
21545	}
21546	reqHeaders.Set("User-Agent", c.s.userAgent())
21547	if c.ifNoneMatch_ != "" {
21548		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21549	}
21550	var body io.Reader = nil
21551	c.urlParams_.Set("alt", alt)
21552	c.urlParams_.Set("prettyPrint", "false")
21553	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21554	urls += "?" + c.urlParams_.Encode()
21555	req, err := http.NewRequest("GET", urls, body)
21556	if err != nil {
21557		return nil, err
21558	}
21559	req.Header = reqHeaders
21560	googleapi.Expand(req.URL, map[string]string{
21561		"profileId": strconv.FormatInt(c.profileId, 10),
21562	})
21563	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21564}
21565
21566// Do executes the "dfareporting.campaigns.list" call.
21567// Exactly one of *CampaignsListResponse or error will be non-nil. Any
21568// non-2xx status code is an error. Response headers are in either
21569// *CampaignsListResponse.ServerResponse.Header or (if a response was
21570// returned at all) in error.(*googleapi.Error).Header. Use
21571// googleapi.IsNotModified to check whether the returned error was
21572// because http.StatusNotModified was returned.
21573func (c *CampaignsListCall) Do(opts ...googleapi.CallOption) (*CampaignsListResponse, error) {
21574	gensupport.SetOptions(c.urlParams_, opts...)
21575	res, err := c.doRequest("json")
21576	if res != nil && res.StatusCode == http.StatusNotModified {
21577		if res.Body != nil {
21578			res.Body.Close()
21579		}
21580		return nil, &googleapi.Error{
21581			Code:   res.StatusCode,
21582			Header: res.Header,
21583		}
21584	}
21585	if err != nil {
21586		return nil, err
21587	}
21588	defer googleapi.CloseBody(res)
21589	if err := googleapi.CheckResponse(res); err != nil {
21590		return nil, err
21591	}
21592	ret := &CampaignsListResponse{
21593		ServerResponse: googleapi.ServerResponse{
21594			Header:         res.Header,
21595			HTTPStatusCode: res.StatusCode,
21596		},
21597	}
21598	target := &ret
21599	if err := gensupport.DecodeResponse(target, res); err != nil {
21600		return nil, err
21601	}
21602	return ret, nil
21603	// {
21604	//   "description": "Retrieves a list of campaigns, possibly filtered. This method supports paging.",
21605	//   "httpMethod": "GET",
21606	//   "id": "dfareporting.campaigns.list",
21607	//   "parameterOrder": [
21608	//     "profileId"
21609	//   ],
21610	//   "parameters": {
21611	//     "advertiserGroupIds": {
21612	//       "description": "Select only campaigns whose advertisers belong to these advertiser groups.",
21613	//       "format": "int64",
21614	//       "location": "query",
21615	//       "repeated": true,
21616	//       "type": "string"
21617	//     },
21618	//     "advertiserIds": {
21619	//       "description": "Select only campaigns that belong to these advertisers.",
21620	//       "format": "int64",
21621	//       "location": "query",
21622	//       "repeated": true,
21623	//       "type": "string"
21624	//     },
21625	//     "archived": {
21626	//       "description": "Select only archived campaigns. Don't set this field to select both archived and non-archived campaigns.",
21627	//       "location": "query",
21628	//       "type": "boolean"
21629	//     },
21630	//     "atLeastOneOptimizationActivity": {
21631	//       "description": "Select only campaigns that have at least one optimization activity.",
21632	//       "location": "query",
21633	//       "type": "boolean"
21634	//     },
21635	//     "excludedIds": {
21636	//       "description": "Exclude campaigns with these IDs.",
21637	//       "format": "int64",
21638	//       "location": "query",
21639	//       "repeated": true,
21640	//       "type": "string"
21641	//     },
21642	//     "ids": {
21643	//       "description": "Select only campaigns with these IDs.",
21644	//       "format": "int64",
21645	//       "location": "query",
21646	//       "repeated": true,
21647	//       "type": "string"
21648	//     },
21649	//     "maxResults": {
21650	//       "default": "1000",
21651	//       "description": "Maximum number of results to return.",
21652	//       "format": "int32",
21653	//       "location": "query",
21654	//       "maximum": "1000",
21655	//       "minimum": "0",
21656	//       "type": "integer"
21657	//     },
21658	//     "overriddenEventTagId": {
21659	//       "description": "Select only campaigns that have overridden this event tag ID.",
21660	//       "format": "int64",
21661	//       "location": "query",
21662	//       "type": "string"
21663	//     },
21664	//     "pageToken": {
21665	//       "description": "Value of the nextPageToken from the previous result page.",
21666	//       "location": "query",
21667	//       "type": "string"
21668	//     },
21669	//     "profileId": {
21670	//       "description": "User profile ID associated with this request.",
21671	//       "format": "int64",
21672	//       "location": "path",
21673	//       "required": true,
21674	//       "type": "string"
21675	//     },
21676	//     "searchString": {
21677	//       "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\".",
21678	//       "location": "query",
21679	//       "type": "string"
21680	//     },
21681	//     "sortField": {
21682	//       "default": "ID",
21683	//       "description": "Field by which to sort the list.",
21684	//       "enum": [
21685	//         "ID",
21686	//         "NAME"
21687	//       ],
21688	//       "enumDescriptions": [
21689	//         "",
21690	//         ""
21691	//       ],
21692	//       "location": "query",
21693	//       "type": "string"
21694	//     },
21695	//     "sortOrder": {
21696	//       "default": "ASCENDING",
21697	//       "description": "Order of sorted results.",
21698	//       "enum": [
21699	//         "ASCENDING",
21700	//         "DESCENDING"
21701	//       ],
21702	//       "enumDescriptions": [
21703	//         "",
21704	//         ""
21705	//       ],
21706	//       "location": "query",
21707	//       "type": "string"
21708	//     },
21709	//     "subaccountId": {
21710	//       "description": "Select only campaigns that belong to this subaccount.",
21711	//       "format": "int64",
21712	//       "location": "query",
21713	//       "type": "string"
21714	//     }
21715	//   },
21716	//   "path": "userprofiles/{profileId}/campaigns",
21717	//   "response": {
21718	//     "$ref": "CampaignsListResponse"
21719	//   },
21720	//   "scopes": [
21721	//     "https://www.googleapis.com/auth/dfatrafficking"
21722	//   ]
21723	// }
21724
21725}
21726
21727// Pages invokes f for each page of results.
21728// A non-nil error returned from f will halt the iteration.
21729// The provided context supersedes any context provided to the Context method.
21730func (c *CampaignsListCall) Pages(ctx context.Context, f func(*CampaignsListResponse) error) error {
21731	c.ctx_ = ctx
21732	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
21733	for {
21734		x, err := c.Do()
21735		if err != nil {
21736			return err
21737		}
21738		if err := f(x); err != nil {
21739			return err
21740		}
21741		if x.NextPageToken == "" {
21742			return nil
21743		}
21744		c.PageToken(x.NextPageToken)
21745	}
21746}
21747
21748// method id "dfareporting.campaigns.patch":
21749
21750type CampaignsPatchCall struct {
21751	s          *Service
21752	profileId  int64
21753	campaign   *Campaign
21754	urlParams_ gensupport.URLParams
21755	ctx_       context.Context
21756	header_    http.Header
21757}
21758
21759// Patch: Updates an existing campaign. This method supports patch
21760// semantics.
21761func (r *CampaignsService) Patch(profileId int64, id int64, campaign *Campaign) *CampaignsPatchCall {
21762	c := &CampaignsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21763	c.profileId = profileId
21764	c.urlParams_.Set("id", fmt.Sprint(id))
21765	c.campaign = campaign
21766	return c
21767}
21768
21769// Fields allows partial responses to be retrieved. See
21770// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21771// for more information.
21772func (c *CampaignsPatchCall) Fields(s ...googleapi.Field) *CampaignsPatchCall {
21773	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21774	return c
21775}
21776
21777// Context sets the context to be used in this call's Do method. Any
21778// pending HTTP request will be aborted if the provided context is
21779// canceled.
21780func (c *CampaignsPatchCall) Context(ctx context.Context) *CampaignsPatchCall {
21781	c.ctx_ = ctx
21782	return c
21783}
21784
21785// Header returns an http.Header that can be modified by the caller to
21786// add HTTP headers to the request.
21787func (c *CampaignsPatchCall) Header() http.Header {
21788	if c.header_ == nil {
21789		c.header_ = make(http.Header)
21790	}
21791	return c.header_
21792}
21793
21794func (c *CampaignsPatchCall) doRequest(alt string) (*http.Response, error) {
21795	reqHeaders := make(http.Header)
21796	for k, v := range c.header_ {
21797		reqHeaders[k] = v
21798	}
21799	reqHeaders.Set("User-Agent", c.s.userAgent())
21800	var body io.Reader = nil
21801	body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
21802	if err != nil {
21803		return nil, err
21804	}
21805	reqHeaders.Set("Content-Type", "application/json")
21806	c.urlParams_.Set("alt", alt)
21807	c.urlParams_.Set("prettyPrint", "false")
21808	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21809	urls += "?" + c.urlParams_.Encode()
21810	req, err := http.NewRequest("PATCH", urls, body)
21811	if err != nil {
21812		return nil, err
21813	}
21814	req.Header = reqHeaders
21815	googleapi.Expand(req.URL, map[string]string{
21816		"profileId": strconv.FormatInt(c.profileId, 10),
21817	})
21818	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21819}
21820
21821// Do executes the "dfareporting.campaigns.patch" call.
21822// Exactly one of *Campaign or error will be non-nil. Any non-2xx status
21823// code is an error. Response headers are in either
21824// *Campaign.ServerResponse.Header or (if a response was returned at
21825// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
21826// to check whether the returned error was because
21827// http.StatusNotModified was returned.
21828func (c *CampaignsPatchCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21829	gensupport.SetOptions(c.urlParams_, opts...)
21830	res, err := c.doRequest("json")
21831	if res != nil && res.StatusCode == http.StatusNotModified {
21832		if res.Body != nil {
21833			res.Body.Close()
21834		}
21835		return nil, &googleapi.Error{
21836			Code:   res.StatusCode,
21837			Header: res.Header,
21838		}
21839	}
21840	if err != nil {
21841		return nil, err
21842	}
21843	defer googleapi.CloseBody(res)
21844	if err := googleapi.CheckResponse(res); err != nil {
21845		return nil, err
21846	}
21847	ret := &Campaign{
21848		ServerResponse: googleapi.ServerResponse{
21849			Header:         res.Header,
21850			HTTPStatusCode: res.StatusCode,
21851		},
21852	}
21853	target := &ret
21854	if err := gensupport.DecodeResponse(target, res); err != nil {
21855		return nil, err
21856	}
21857	return ret, nil
21858	// {
21859	//   "description": "Updates an existing campaign. This method supports patch semantics.",
21860	//   "httpMethod": "PATCH",
21861	//   "id": "dfareporting.campaigns.patch",
21862	//   "parameterOrder": [
21863	//     "profileId",
21864	//     "id"
21865	//   ],
21866	//   "parameters": {
21867	//     "id": {
21868	//       "description": "Campaign ID.",
21869	//       "format": "int64",
21870	//       "location": "query",
21871	//       "required": true,
21872	//       "type": "string"
21873	//     },
21874	//     "profileId": {
21875	//       "description": "User profile ID associated with this request.",
21876	//       "format": "int64",
21877	//       "location": "path",
21878	//       "required": true,
21879	//       "type": "string"
21880	//     }
21881	//   },
21882	//   "path": "userprofiles/{profileId}/campaigns",
21883	//   "request": {
21884	//     "$ref": "Campaign"
21885	//   },
21886	//   "response": {
21887	//     "$ref": "Campaign"
21888	//   },
21889	//   "scopes": [
21890	//     "https://www.googleapis.com/auth/dfatrafficking"
21891	//   ]
21892	// }
21893
21894}
21895
21896// method id "dfareporting.campaigns.update":
21897
21898type CampaignsUpdateCall struct {
21899	s          *Service
21900	profileId  int64
21901	campaign   *Campaign
21902	urlParams_ gensupport.URLParams
21903	ctx_       context.Context
21904	header_    http.Header
21905}
21906
21907// Update: Updates an existing campaign.
21908func (r *CampaignsService) Update(profileId int64, campaign *Campaign) *CampaignsUpdateCall {
21909	c := &CampaignsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21910	c.profileId = profileId
21911	c.campaign = campaign
21912	return c
21913}
21914
21915// Fields allows partial responses to be retrieved. See
21916// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21917// for more information.
21918func (c *CampaignsUpdateCall) Fields(s ...googleapi.Field) *CampaignsUpdateCall {
21919	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21920	return c
21921}
21922
21923// Context sets the context to be used in this call's Do method. Any
21924// pending HTTP request will be aborted if the provided context is
21925// canceled.
21926func (c *CampaignsUpdateCall) Context(ctx context.Context) *CampaignsUpdateCall {
21927	c.ctx_ = ctx
21928	return c
21929}
21930
21931// Header returns an http.Header that can be modified by the caller to
21932// add HTTP headers to the request.
21933func (c *CampaignsUpdateCall) Header() http.Header {
21934	if c.header_ == nil {
21935		c.header_ = make(http.Header)
21936	}
21937	return c.header_
21938}
21939
21940func (c *CampaignsUpdateCall) doRequest(alt string) (*http.Response, error) {
21941	reqHeaders := make(http.Header)
21942	for k, v := range c.header_ {
21943		reqHeaders[k] = v
21944	}
21945	reqHeaders.Set("User-Agent", c.s.userAgent())
21946	var body io.Reader = nil
21947	body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
21948	if err != nil {
21949		return nil, err
21950	}
21951	reqHeaders.Set("Content-Type", "application/json")
21952	c.urlParams_.Set("alt", alt)
21953	c.urlParams_.Set("prettyPrint", "false")
21954	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21955	urls += "?" + c.urlParams_.Encode()
21956	req, err := http.NewRequest("PUT", urls, body)
21957	if err != nil {
21958		return nil, err
21959	}
21960	req.Header = reqHeaders
21961	googleapi.Expand(req.URL, map[string]string{
21962		"profileId": strconv.FormatInt(c.profileId, 10),
21963	})
21964	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21965}
21966
21967// Do executes the "dfareporting.campaigns.update" call.
21968// Exactly one of *Campaign or error will be non-nil. Any non-2xx status
21969// code is an error. Response headers are in either
21970// *Campaign.ServerResponse.Header or (if a response was returned at
21971// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
21972// to check whether the returned error was because
21973// http.StatusNotModified was returned.
21974func (c *CampaignsUpdateCall) Do(opts ...googleapi.CallOption) (*Campaign, 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 := &Campaign{
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": "Updates an existing campaign.",
22006	//   "httpMethod": "PUT",
22007	//   "id": "dfareporting.campaigns.update",
22008	//   "parameterOrder": [
22009	//     "profileId"
22010	//   ],
22011	//   "parameters": {
22012	//     "profileId": {
22013	//       "description": "User profile ID associated with this request.",
22014	//       "format": "int64",
22015	//       "location": "path",
22016	//       "required": true,
22017	//       "type": "string"
22018	//     }
22019	//   },
22020	//   "path": "userprofiles/{profileId}/campaigns",
22021	//   "request": {
22022	//     "$ref": "Campaign"
22023	//   },
22024	//   "response": {
22025	//     "$ref": "Campaign"
22026	//   },
22027	//   "scopes": [
22028	//     "https://www.googleapis.com/auth/dfatrafficking"
22029	//   ]
22030	// }
22031
22032}
22033
22034// method id "dfareporting.changeLogs.get":
22035
22036type ChangeLogsGetCall struct {
22037	s            *Service
22038	profileId    int64
22039	id           int64
22040	urlParams_   gensupport.URLParams
22041	ifNoneMatch_ string
22042	ctx_         context.Context
22043	header_      http.Header
22044}
22045
22046// Get: Gets one change log by ID.
22047func (r *ChangeLogsService) Get(profileId int64, id int64) *ChangeLogsGetCall {
22048	c := &ChangeLogsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22049	c.profileId = profileId
22050	c.id = id
22051	return c
22052}
22053
22054// Fields allows partial responses to be retrieved. See
22055// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22056// for more information.
22057func (c *ChangeLogsGetCall) Fields(s ...googleapi.Field) *ChangeLogsGetCall {
22058	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22059	return c
22060}
22061
22062// IfNoneMatch sets the optional parameter which makes the operation
22063// fail if the object's ETag matches the given value. This is useful for
22064// getting updates only after the object has changed since the last
22065// request. Use googleapi.IsNotModified to check whether the response
22066// error from Do is the result of In-None-Match.
22067func (c *ChangeLogsGetCall) IfNoneMatch(entityTag string) *ChangeLogsGetCall {
22068	c.ifNoneMatch_ = entityTag
22069	return c
22070}
22071
22072// Context sets the context to be used in this call's Do method. Any
22073// pending HTTP request will be aborted if the provided context is
22074// canceled.
22075func (c *ChangeLogsGetCall) Context(ctx context.Context) *ChangeLogsGetCall {
22076	c.ctx_ = ctx
22077	return c
22078}
22079
22080// Header returns an http.Header that can be modified by the caller to
22081// add HTTP headers to the request.
22082func (c *ChangeLogsGetCall) Header() http.Header {
22083	if c.header_ == nil {
22084		c.header_ = make(http.Header)
22085	}
22086	return c.header_
22087}
22088
22089func (c *ChangeLogsGetCall) doRequest(alt string) (*http.Response, error) {
22090	reqHeaders := make(http.Header)
22091	for k, v := range c.header_ {
22092		reqHeaders[k] = v
22093	}
22094	reqHeaders.Set("User-Agent", c.s.userAgent())
22095	if c.ifNoneMatch_ != "" {
22096		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22097	}
22098	var body io.Reader = nil
22099	c.urlParams_.Set("alt", alt)
22100	c.urlParams_.Set("prettyPrint", "false")
22101	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/changeLogs/{id}")
22102	urls += "?" + c.urlParams_.Encode()
22103	req, err := http.NewRequest("GET", urls, body)
22104	if err != nil {
22105		return nil, err
22106	}
22107	req.Header = reqHeaders
22108	googleapi.Expand(req.URL, map[string]string{
22109		"profileId": strconv.FormatInt(c.profileId, 10),
22110		"id":        strconv.FormatInt(c.id, 10),
22111	})
22112	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22113}
22114
22115// Do executes the "dfareporting.changeLogs.get" call.
22116// Exactly one of *ChangeLog or error will be non-nil. Any non-2xx
22117// status code is an error. Response headers are in either
22118// *ChangeLog.ServerResponse.Header or (if a response was returned at
22119// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
22120// to check whether the returned error was because
22121// http.StatusNotModified was returned.
22122func (c *ChangeLogsGetCall) Do(opts ...googleapi.CallOption) (*ChangeLog, error) {
22123	gensupport.SetOptions(c.urlParams_, opts...)
22124	res, err := c.doRequest("json")
22125	if res != nil && res.StatusCode == http.StatusNotModified {
22126		if res.Body != nil {
22127			res.Body.Close()
22128		}
22129		return nil, &googleapi.Error{
22130			Code:   res.StatusCode,
22131			Header: res.Header,
22132		}
22133	}
22134	if err != nil {
22135		return nil, err
22136	}
22137	defer googleapi.CloseBody(res)
22138	if err := googleapi.CheckResponse(res); err != nil {
22139		return nil, err
22140	}
22141	ret := &ChangeLog{
22142		ServerResponse: googleapi.ServerResponse{
22143			Header:         res.Header,
22144			HTTPStatusCode: res.StatusCode,
22145		},
22146	}
22147	target := &ret
22148	if err := gensupport.DecodeResponse(target, res); err != nil {
22149		return nil, err
22150	}
22151	return ret, nil
22152	// {
22153	//   "description": "Gets one change log by ID.",
22154	//   "httpMethod": "GET",
22155	//   "id": "dfareporting.changeLogs.get",
22156	//   "parameterOrder": [
22157	//     "profileId",
22158	//     "id"
22159	//   ],
22160	//   "parameters": {
22161	//     "id": {
22162	//       "description": "Change log ID.",
22163	//       "format": "int64",
22164	//       "location": "path",
22165	//       "required": true,
22166	//       "type": "string"
22167	//     },
22168	//     "profileId": {
22169	//       "description": "User profile ID associated with this request.",
22170	//       "format": "int64",
22171	//       "location": "path",
22172	//       "required": true,
22173	//       "type": "string"
22174	//     }
22175	//   },
22176	//   "path": "userprofiles/{profileId}/changeLogs/{id}",
22177	//   "response": {
22178	//     "$ref": "ChangeLog"
22179	//   },
22180	//   "scopes": [
22181	//     "https://www.googleapis.com/auth/dfatrafficking"
22182	//   ]
22183	// }
22184
22185}
22186
22187// method id "dfareporting.changeLogs.list":
22188
22189type ChangeLogsListCall struct {
22190	s            *Service
22191	profileId    int64
22192	urlParams_   gensupport.URLParams
22193	ifNoneMatch_ string
22194	ctx_         context.Context
22195	header_      http.Header
22196}
22197
22198// List: Retrieves a list of change logs. This method supports paging.
22199func (r *ChangeLogsService) List(profileId int64) *ChangeLogsListCall {
22200	c := &ChangeLogsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22201	c.profileId = profileId
22202	return c
22203}
22204
22205// Action sets the optional parameter "action": Select only change logs
22206// with the specified action.
22207//
22208// Possible values:
22209//   "ACTION_ADD"
22210//   "ACTION_ASSIGN"
22211//   "ACTION_ASSOCIATE"
22212//   "ACTION_CREATE"
22213//   "ACTION_DELETE"
22214//   "ACTION_DISABLE"
22215//   "ACTION_EMAIL_TAGS"
22216//   "ACTION_ENABLE"
22217//   "ACTION_LINK"
22218//   "ACTION_MARK_AS_DEFAULT"
22219//   "ACTION_PUSH"
22220//   "ACTION_REMOVE"
22221//   "ACTION_SEND"
22222//   "ACTION_SHARE"
22223//   "ACTION_UNASSIGN"
22224//   "ACTION_UNLINK"
22225//   "ACTION_UPDATE"
22226func (c *ChangeLogsListCall) Action(action string) *ChangeLogsListCall {
22227	c.urlParams_.Set("action", action)
22228	return c
22229}
22230
22231// Ids sets the optional parameter "ids": Select only change logs with
22232// these IDs.
22233func (c *ChangeLogsListCall) Ids(ids ...int64) *ChangeLogsListCall {
22234	var ids_ []string
22235	for _, v := range ids {
22236		ids_ = append(ids_, fmt.Sprint(v))
22237	}
22238	c.urlParams_.SetMulti("ids", ids_)
22239	return c
22240}
22241
22242// MaxChangeTime sets the optional parameter "maxChangeTime": Select
22243// only change logs whose change time is before the specified
22244// maxChangeTime.The time should be formatted as an RFC3339 date/time
22245// string. For example, for 10:54 PM on July 18th, 2015, in the
22246// America/New York time zone, the format is
22247// "2015-07-18T22:54:00-04:00". In other words, the year, month, day,
22248// the letter T, the hour (24-hour clock system), minute, second, and
22249// then the time zone offset.
22250func (c *ChangeLogsListCall) MaxChangeTime(maxChangeTime string) *ChangeLogsListCall {
22251	c.urlParams_.Set("maxChangeTime", maxChangeTime)
22252	return c
22253}
22254
22255// MaxResults sets the optional parameter "maxResults": Maximum number
22256// of results to return.
22257func (c *ChangeLogsListCall) MaxResults(maxResults int64) *ChangeLogsListCall {
22258	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
22259	return c
22260}
22261
22262// MinChangeTime sets the optional parameter "minChangeTime": Select
22263// only change logs whose change time is before the specified
22264// minChangeTime.The time should be formatted as an RFC3339 date/time
22265// string. For example, for 10:54 PM on July 18th, 2015, in the
22266// America/New York time zone, the format is
22267// "2015-07-18T22:54:00-04:00". In other words, the year, month, day,
22268// the letter T, the hour (24-hour clock system), minute, second, and
22269// then the time zone offset.
22270func (c *ChangeLogsListCall) MinChangeTime(minChangeTime string) *ChangeLogsListCall {
22271	c.urlParams_.Set("minChangeTime", minChangeTime)
22272	return c
22273}
22274
22275// ObjectIds sets the optional parameter "objectIds": Select only change
22276// logs with these object IDs.
22277func (c *ChangeLogsListCall) ObjectIds(objectIds ...int64) *ChangeLogsListCall {
22278	var objectIds_ []string
22279	for _, v := range objectIds {
22280		objectIds_ = append(objectIds_, fmt.Sprint(v))
22281	}
22282	c.urlParams_.SetMulti("objectIds", objectIds_)
22283	return c
22284}
22285
22286// ObjectType sets the optional parameter "objectType": Select only
22287// change logs with the specified object type.
22288//
22289// Possible values:
22290//   "OBJECT_ACCOUNT"
22291//   "OBJECT_ACCOUNT_BILLING_FEATURE"
22292//   "OBJECT_AD"
22293//   "OBJECT_ADVERTISER"
22294//   "OBJECT_ADVERTISER_GROUP"
22295//   "OBJECT_BILLING_ACCOUNT_GROUP"
22296//   "OBJECT_BILLING_FEATURE"
22297//   "OBJECT_BILLING_MINIMUM_FEE"
22298//   "OBJECT_BILLING_PROFILE"
22299//   "OBJECT_CAMPAIGN"
22300//   "OBJECT_CONTENT_CATEGORY"
22301//   "OBJECT_CREATIVE"
22302//   "OBJECT_CREATIVE_ASSET"
22303//   "OBJECT_CREATIVE_BUNDLE"
22304//   "OBJECT_CREATIVE_FIELD"
22305//   "OBJECT_CREATIVE_GROUP"
22306//   "OBJECT_DFA_SITE"
22307//   "OBJECT_EVENT_TAG"
22308//   "OBJECT_FLOODLIGHT_ACTIVITY_GROUP"
22309//   "OBJECT_FLOODLIGHT_ACTVITY"
22310//   "OBJECT_FLOODLIGHT_CONFIGURATION"
22311//   "OBJECT_INSTREAM_CREATIVE"
22312//   "OBJECT_LANDING_PAGE"
22313//   "OBJECT_MEDIA_ORDER"
22314//   "OBJECT_PLACEMENT"
22315//   "OBJECT_PLACEMENT_STRATEGY"
22316//   "OBJECT_PLAYSTORE_LINK"
22317//   "OBJECT_PROVIDED_LIST_CLIENT"
22318//   "OBJECT_RATE_CARD"
22319//   "OBJECT_REMARKETING_LIST"
22320//   "OBJECT_RICHMEDIA_CREATIVE"
22321//   "OBJECT_SD_SITE"
22322//   "OBJECT_SEARCH_LIFT_STUDY"
22323//   "OBJECT_SIZE"
22324//   "OBJECT_SUBACCOUNT"
22325//   "OBJECT_TARGETING_TEMPLATE"
22326//   "OBJECT_USER_PROFILE"
22327//   "OBJECT_USER_PROFILE_FILTER"
22328//   "OBJECT_USER_ROLE"
22329func (c *ChangeLogsListCall) ObjectType(objectType string) *ChangeLogsListCall {
22330	c.urlParams_.Set("objectType", objectType)
22331	return c
22332}
22333
22334// PageToken sets the optional parameter "pageToken": Value of the
22335// nextPageToken from the previous result page.
22336func (c *ChangeLogsListCall) PageToken(pageToken string) *ChangeLogsListCall {
22337	c.urlParams_.Set("pageToken", pageToken)
22338	return c
22339}
22340
22341// SearchString sets the optional parameter "searchString": Select only
22342// change logs whose object ID, user name, old or new values match the
22343// search string.
22344func (c *ChangeLogsListCall) SearchString(searchString string) *ChangeLogsListCall {
22345	c.urlParams_.Set("searchString", searchString)
22346	return c
22347}
22348
22349// UserProfileIds sets the optional parameter "userProfileIds": Select
22350// only change logs with these user profile IDs.
22351func (c *ChangeLogsListCall) UserProfileIds(userProfileIds ...int64) *ChangeLogsListCall {
22352	var userProfileIds_ []string
22353	for _, v := range userProfileIds {
22354		userProfileIds_ = append(userProfileIds_, fmt.Sprint(v))
22355	}
22356	c.urlParams_.SetMulti("userProfileIds", userProfileIds_)
22357	return c
22358}
22359
22360// Fields allows partial responses to be retrieved. See
22361// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22362// for more information.
22363func (c *ChangeLogsListCall) Fields(s ...googleapi.Field) *ChangeLogsListCall {
22364	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22365	return c
22366}
22367
22368// IfNoneMatch sets the optional parameter which makes the operation
22369// fail if the object's ETag matches the given value. This is useful for
22370// getting updates only after the object has changed since the last
22371// request. Use googleapi.IsNotModified to check whether the response
22372// error from Do is the result of In-None-Match.
22373func (c *ChangeLogsListCall) IfNoneMatch(entityTag string) *ChangeLogsListCall {
22374	c.ifNoneMatch_ = entityTag
22375	return c
22376}
22377
22378// Context sets the context to be used in this call's Do method. Any
22379// pending HTTP request will be aborted if the provided context is
22380// canceled.
22381func (c *ChangeLogsListCall) Context(ctx context.Context) *ChangeLogsListCall {
22382	c.ctx_ = ctx
22383	return c
22384}
22385
22386// Header returns an http.Header that can be modified by the caller to
22387// add HTTP headers to the request.
22388func (c *ChangeLogsListCall) Header() http.Header {
22389	if c.header_ == nil {
22390		c.header_ = make(http.Header)
22391	}
22392	return c.header_
22393}
22394
22395func (c *ChangeLogsListCall) doRequest(alt string) (*http.Response, error) {
22396	reqHeaders := make(http.Header)
22397	for k, v := range c.header_ {
22398		reqHeaders[k] = v
22399	}
22400	reqHeaders.Set("User-Agent", c.s.userAgent())
22401	if c.ifNoneMatch_ != "" {
22402		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22403	}
22404	var body io.Reader = nil
22405	c.urlParams_.Set("alt", alt)
22406	c.urlParams_.Set("prettyPrint", "false")
22407	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/changeLogs")
22408	urls += "?" + c.urlParams_.Encode()
22409	req, err := http.NewRequest("GET", urls, body)
22410	if err != nil {
22411		return nil, err
22412	}
22413	req.Header = reqHeaders
22414	googleapi.Expand(req.URL, map[string]string{
22415		"profileId": strconv.FormatInt(c.profileId, 10),
22416	})
22417	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22418}
22419
22420// Do executes the "dfareporting.changeLogs.list" call.
22421// Exactly one of *ChangeLogsListResponse or error will be non-nil. Any
22422// non-2xx status code is an error. Response headers are in either
22423// *ChangeLogsListResponse.ServerResponse.Header or (if a response was
22424// returned at all) in error.(*googleapi.Error).Header. Use
22425// googleapi.IsNotModified to check whether the returned error was
22426// because http.StatusNotModified was returned.
22427func (c *ChangeLogsListCall) Do(opts ...googleapi.CallOption) (*ChangeLogsListResponse, error) {
22428	gensupport.SetOptions(c.urlParams_, opts...)
22429	res, err := c.doRequest("json")
22430	if res != nil && res.StatusCode == http.StatusNotModified {
22431		if res.Body != nil {
22432			res.Body.Close()
22433		}
22434		return nil, &googleapi.Error{
22435			Code:   res.StatusCode,
22436			Header: res.Header,
22437		}
22438	}
22439	if err != nil {
22440		return nil, err
22441	}
22442	defer googleapi.CloseBody(res)
22443	if err := googleapi.CheckResponse(res); err != nil {
22444		return nil, err
22445	}
22446	ret := &ChangeLogsListResponse{
22447		ServerResponse: googleapi.ServerResponse{
22448			Header:         res.Header,
22449			HTTPStatusCode: res.StatusCode,
22450		},
22451	}
22452	target := &ret
22453	if err := gensupport.DecodeResponse(target, res); err != nil {
22454		return nil, err
22455	}
22456	return ret, nil
22457	// {
22458	//   "description": "Retrieves a list of change logs. This method supports paging.",
22459	//   "httpMethod": "GET",
22460	//   "id": "dfareporting.changeLogs.list",
22461	//   "parameterOrder": [
22462	//     "profileId"
22463	//   ],
22464	//   "parameters": {
22465	//     "action": {
22466	//       "description": "Select only change logs with the specified action.",
22467	//       "enum": [
22468	//         "ACTION_ADD",
22469	//         "ACTION_ASSIGN",
22470	//         "ACTION_ASSOCIATE",
22471	//         "ACTION_CREATE",
22472	//         "ACTION_DELETE",
22473	//         "ACTION_DISABLE",
22474	//         "ACTION_EMAIL_TAGS",
22475	//         "ACTION_ENABLE",
22476	//         "ACTION_LINK",
22477	//         "ACTION_MARK_AS_DEFAULT",
22478	//         "ACTION_PUSH",
22479	//         "ACTION_REMOVE",
22480	//         "ACTION_SEND",
22481	//         "ACTION_SHARE",
22482	//         "ACTION_UNASSIGN",
22483	//         "ACTION_UNLINK",
22484	//         "ACTION_UPDATE"
22485	//       ],
22486	//       "enumDescriptions": [
22487	//         "",
22488	//         "",
22489	//         "",
22490	//         "",
22491	//         "",
22492	//         "",
22493	//         "",
22494	//         "",
22495	//         "",
22496	//         "",
22497	//         "",
22498	//         "",
22499	//         "",
22500	//         "",
22501	//         "",
22502	//         "",
22503	//         ""
22504	//       ],
22505	//       "location": "query",
22506	//       "type": "string"
22507	//     },
22508	//     "ids": {
22509	//       "description": "Select only change logs with these IDs.",
22510	//       "format": "int64",
22511	//       "location": "query",
22512	//       "repeated": true,
22513	//       "type": "string"
22514	//     },
22515	//     "maxChangeTime": {
22516	//       "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.",
22517	//       "location": "query",
22518	//       "type": "string"
22519	//     },
22520	//     "maxResults": {
22521	//       "default": "1000",
22522	//       "description": "Maximum number of results to return.",
22523	//       "format": "int32",
22524	//       "location": "query",
22525	//       "maximum": "1000",
22526	//       "minimum": "0",
22527	//       "type": "integer"
22528	//     },
22529	//     "minChangeTime": {
22530	//       "description": "Select only change logs whose change time is before 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.",
22531	//       "location": "query",
22532	//       "type": "string"
22533	//     },
22534	//     "objectIds": {
22535	//       "description": "Select only change logs with these object IDs.",
22536	//       "format": "int64",
22537	//       "location": "query",
22538	//       "repeated": true,
22539	//       "type": "string"
22540	//     },
22541	//     "objectType": {
22542	//       "description": "Select only change logs with the specified object type.",
22543	//       "enum": [
22544	//         "OBJECT_ACCOUNT",
22545	//         "OBJECT_ACCOUNT_BILLING_FEATURE",
22546	//         "OBJECT_AD",
22547	//         "OBJECT_ADVERTISER",
22548	//         "OBJECT_ADVERTISER_GROUP",
22549	//         "OBJECT_BILLING_ACCOUNT_GROUP",
22550	//         "OBJECT_BILLING_FEATURE",
22551	//         "OBJECT_BILLING_MINIMUM_FEE",
22552	//         "OBJECT_BILLING_PROFILE",
22553	//         "OBJECT_CAMPAIGN",
22554	//         "OBJECT_CONTENT_CATEGORY",
22555	//         "OBJECT_CREATIVE",
22556	//         "OBJECT_CREATIVE_ASSET",
22557	//         "OBJECT_CREATIVE_BUNDLE",
22558	//         "OBJECT_CREATIVE_FIELD",
22559	//         "OBJECT_CREATIVE_GROUP",
22560	//         "OBJECT_DFA_SITE",
22561	//         "OBJECT_EVENT_TAG",
22562	//         "OBJECT_FLOODLIGHT_ACTIVITY_GROUP",
22563	//         "OBJECT_FLOODLIGHT_ACTVITY",
22564	//         "OBJECT_FLOODLIGHT_CONFIGURATION",
22565	//         "OBJECT_INSTREAM_CREATIVE",
22566	//         "OBJECT_LANDING_PAGE",
22567	//         "OBJECT_MEDIA_ORDER",
22568	//         "OBJECT_PLACEMENT",
22569	//         "OBJECT_PLACEMENT_STRATEGY",
22570	//         "OBJECT_PLAYSTORE_LINK",
22571	//         "OBJECT_PROVIDED_LIST_CLIENT",
22572	//         "OBJECT_RATE_CARD",
22573	//         "OBJECT_REMARKETING_LIST",
22574	//         "OBJECT_RICHMEDIA_CREATIVE",
22575	//         "OBJECT_SD_SITE",
22576	//         "OBJECT_SEARCH_LIFT_STUDY",
22577	//         "OBJECT_SIZE",
22578	//         "OBJECT_SUBACCOUNT",
22579	//         "OBJECT_TARGETING_TEMPLATE",
22580	//         "OBJECT_USER_PROFILE",
22581	//         "OBJECT_USER_PROFILE_FILTER",
22582	//         "OBJECT_USER_ROLE"
22583	//       ],
22584	//       "enumDescriptions": [
22585	//         "",
22586	//         "",
22587	//         "",
22588	//         "",
22589	//         "",
22590	//         "",
22591	//         "",
22592	//         "",
22593	//         "",
22594	//         "",
22595	//         "",
22596	//         "",
22597	//         "",
22598	//         "",
22599	//         "",
22600	//         "",
22601	//         "",
22602	//         "",
22603	//         "",
22604	//         "",
22605	//         "",
22606	//         "",
22607	//         "",
22608	//         "",
22609	//         "",
22610	//         "",
22611	//         "",
22612	//         "",
22613	//         "",
22614	//         "",
22615	//         "",
22616	//         "",
22617	//         "",
22618	//         "",
22619	//         "",
22620	//         "",
22621	//         "",
22622	//         "",
22623	//         ""
22624	//       ],
22625	//       "location": "query",
22626	//       "type": "string"
22627	//     },
22628	//     "pageToken": {
22629	//       "description": "Value of the nextPageToken from the previous result page.",
22630	//       "location": "query",
22631	//       "type": "string"
22632	//     },
22633	//     "profileId": {
22634	//       "description": "User profile ID associated with this request.",
22635	//       "format": "int64",
22636	//       "location": "path",
22637	//       "required": true,
22638	//       "type": "string"
22639	//     },
22640	//     "searchString": {
22641	//       "description": "Select only change logs whose object ID, user name, old or new values match the search string.",
22642	//       "location": "query",
22643	//       "type": "string"
22644	//     },
22645	//     "userProfileIds": {
22646	//       "description": "Select only change logs with these user profile IDs.",
22647	//       "format": "int64",
22648	//       "location": "query",
22649	//       "repeated": true,
22650	//       "type": "string"
22651	//     }
22652	//   },
22653	//   "path": "userprofiles/{profileId}/changeLogs",
22654	//   "response": {
22655	//     "$ref": "ChangeLogsListResponse"
22656	//   },
22657	//   "scopes": [
22658	//     "https://www.googleapis.com/auth/dfatrafficking"
22659	//   ]
22660	// }
22661
22662}
22663
22664// Pages invokes f for each page of results.
22665// A non-nil error returned from f will halt the iteration.
22666// The provided context supersedes any context provided to the Context method.
22667func (c *ChangeLogsListCall) Pages(ctx context.Context, f func(*ChangeLogsListResponse) error) error {
22668	c.ctx_ = ctx
22669	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
22670	for {
22671		x, err := c.Do()
22672		if err != nil {
22673			return err
22674		}
22675		if err := f(x); err != nil {
22676			return err
22677		}
22678		if x.NextPageToken == "" {
22679			return nil
22680		}
22681		c.PageToken(x.NextPageToken)
22682	}
22683}
22684
22685// method id "dfareporting.cities.list":
22686
22687type CitiesListCall struct {
22688	s            *Service
22689	profileId    int64
22690	urlParams_   gensupport.URLParams
22691	ifNoneMatch_ string
22692	ctx_         context.Context
22693	header_      http.Header
22694}
22695
22696// List: Retrieves a list of cities, possibly filtered.
22697func (r *CitiesService) List(profileId int64) *CitiesListCall {
22698	c := &CitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22699	c.profileId = profileId
22700	return c
22701}
22702
22703// CountryDartIds sets the optional parameter "countryDartIds": Select
22704// only cities from these countries.
22705func (c *CitiesListCall) CountryDartIds(countryDartIds ...int64) *CitiesListCall {
22706	var countryDartIds_ []string
22707	for _, v := range countryDartIds {
22708		countryDartIds_ = append(countryDartIds_, fmt.Sprint(v))
22709	}
22710	c.urlParams_.SetMulti("countryDartIds", countryDartIds_)
22711	return c
22712}
22713
22714// DartIds sets the optional parameter "dartIds": Select only cities
22715// with these DART IDs.
22716func (c *CitiesListCall) DartIds(dartIds ...int64) *CitiesListCall {
22717	var dartIds_ []string
22718	for _, v := range dartIds {
22719		dartIds_ = append(dartIds_, fmt.Sprint(v))
22720	}
22721	c.urlParams_.SetMulti("dartIds", dartIds_)
22722	return c
22723}
22724
22725// NamePrefix sets the optional parameter "namePrefix": Select only
22726// cities with names starting with this prefix.
22727func (c *CitiesListCall) NamePrefix(namePrefix string) *CitiesListCall {
22728	c.urlParams_.Set("namePrefix", namePrefix)
22729	return c
22730}
22731
22732// RegionDartIds sets the optional parameter "regionDartIds": Select
22733// only cities from these regions.
22734func (c *CitiesListCall) RegionDartIds(regionDartIds ...int64) *CitiesListCall {
22735	var regionDartIds_ []string
22736	for _, v := range regionDartIds {
22737		regionDartIds_ = append(regionDartIds_, fmt.Sprint(v))
22738	}
22739	c.urlParams_.SetMulti("regionDartIds", regionDartIds_)
22740	return c
22741}
22742
22743// Fields allows partial responses to be retrieved. See
22744// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22745// for more information.
22746func (c *CitiesListCall) Fields(s ...googleapi.Field) *CitiesListCall {
22747	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22748	return c
22749}
22750
22751// IfNoneMatch sets the optional parameter which makes the operation
22752// fail if the object's ETag matches the given value. This is useful for
22753// getting updates only after the object has changed since the last
22754// request. Use googleapi.IsNotModified to check whether the response
22755// error from Do is the result of In-None-Match.
22756func (c *CitiesListCall) IfNoneMatch(entityTag string) *CitiesListCall {
22757	c.ifNoneMatch_ = entityTag
22758	return c
22759}
22760
22761// Context sets the context to be used in this call's Do method. Any
22762// pending HTTP request will be aborted if the provided context is
22763// canceled.
22764func (c *CitiesListCall) Context(ctx context.Context) *CitiesListCall {
22765	c.ctx_ = ctx
22766	return c
22767}
22768
22769// Header returns an http.Header that can be modified by the caller to
22770// add HTTP headers to the request.
22771func (c *CitiesListCall) Header() http.Header {
22772	if c.header_ == nil {
22773		c.header_ = make(http.Header)
22774	}
22775	return c.header_
22776}
22777
22778func (c *CitiesListCall) doRequest(alt string) (*http.Response, error) {
22779	reqHeaders := make(http.Header)
22780	for k, v := range c.header_ {
22781		reqHeaders[k] = v
22782	}
22783	reqHeaders.Set("User-Agent", c.s.userAgent())
22784	if c.ifNoneMatch_ != "" {
22785		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22786	}
22787	var body io.Reader = nil
22788	c.urlParams_.Set("alt", alt)
22789	c.urlParams_.Set("prettyPrint", "false")
22790	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/cities")
22791	urls += "?" + c.urlParams_.Encode()
22792	req, err := http.NewRequest("GET", urls, body)
22793	if err != nil {
22794		return nil, err
22795	}
22796	req.Header = reqHeaders
22797	googleapi.Expand(req.URL, map[string]string{
22798		"profileId": strconv.FormatInt(c.profileId, 10),
22799	})
22800	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22801}
22802
22803// Do executes the "dfareporting.cities.list" call.
22804// Exactly one of *CitiesListResponse or error will be non-nil. Any
22805// non-2xx status code is an error. Response headers are in either
22806// *CitiesListResponse.ServerResponse.Header or (if a response was
22807// returned at all) in error.(*googleapi.Error).Header. Use
22808// googleapi.IsNotModified to check whether the returned error was
22809// because http.StatusNotModified was returned.
22810func (c *CitiesListCall) Do(opts ...googleapi.CallOption) (*CitiesListResponse, error) {
22811	gensupport.SetOptions(c.urlParams_, opts...)
22812	res, err := c.doRequest("json")
22813	if res != nil && res.StatusCode == http.StatusNotModified {
22814		if res.Body != nil {
22815			res.Body.Close()
22816		}
22817		return nil, &googleapi.Error{
22818			Code:   res.StatusCode,
22819			Header: res.Header,
22820		}
22821	}
22822	if err != nil {
22823		return nil, err
22824	}
22825	defer googleapi.CloseBody(res)
22826	if err := googleapi.CheckResponse(res); err != nil {
22827		return nil, err
22828	}
22829	ret := &CitiesListResponse{
22830		ServerResponse: googleapi.ServerResponse{
22831			Header:         res.Header,
22832			HTTPStatusCode: res.StatusCode,
22833		},
22834	}
22835	target := &ret
22836	if err := gensupport.DecodeResponse(target, res); err != nil {
22837		return nil, err
22838	}
22839	return ret, nil
22840	// {
22841	//   "description": "Retrieves a list of cities, possibly filtered.",
22842	//   "httpMethod": "GET",
22843	//   "id": "dfareporting.cities.list",
22844	//   "parameterOrder": [
22845	//     "profileId"
22846	//   ],
22847	//   "parameters": {
22848	//     "countryDartIds": {
22849	//       "description": "Select only cities from these countries.",
22850	//       "format": "int64",
22851	//       "location": "query",
22852	//       "repeated": true,
22853	//       "type": "string"
22854	//     },
22855	//     "dartIds": {
22856	//       "description": "Select only cities with these DART IDs.",
22857	//       "format": "int64",
22858	//       "location": "query",
22859	//       "repeated": true,
22860	//       "type": "string"
22861	//     },
22862	//     "namePrefix": {
22863	//       "description": "Select only cities with names starting with this prefix.",
22864	//       "location": "query",
22865	//       "type": "string"
22866	//     },
22867	//     "profileId": {
22868	//       "description": "User profile ID associated with this request.",
22869	//       "format": "int64",
22870	//       "location": "path",
22871	//       "required": true,
22872	//       "type": "string"
22873	//     },
22874	//     "regionDartIds": {
22875	//       "description": "Select only cities from these regions.",
22876	//       "format": "int64",
22877	//       "location": "query",
22878	//       "repeated": true,
22879	//       "type": "string"
22880	//     }
22881	//   },
22882	//   "path": "userprofiles/{profileId}/cities",
22883	//   "response": {
22884	//     "$ref": "CitiesListResponse"
22885	//   },
22886	//   "scopes": [
22887	//     "https://www.googleapis.com/auth/dfatrafficking"
22888	//   ]
22889	// }
22890
22891}
22892
22893// method id "dfareporting.connectionTypes.get":
22894
22895type ConnectionTypesGetCall struct {
22896	s            *Service
22897	profileId    int64
22898	id           int64
22899	urlParams_   gensupport.URLParams
22900	ifNoneMatch_ string
22901	ctx_         context.Context
22902	header_      http.Header
22903}
22904
22905// Get: Gets one connection type by ID.
22906func (r *ConnectionTypesService) Get(profileId int64, id int64) *ConnectionTypesGetCall {
22907	c := &ConnectionTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22908	c.profileId = profileId
22909	c.id = id
22910	return c
22911}
22912
22913// Fields allows partial responses to be retrieved. See
22914// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22915// for more information.
22916func (c *ConnectionTypesGetCall) Fields(s ...googleapi.Field) *ConnectionTypesGetCall {
22917	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22918	return c
22919}
22920
22921// IfNoneMatch sets the optional parameter which makes the operation
22922// fail if the object's ETag matches the given value. This is useful for
22923// getting updates only after the object has changed since the last
22924// request. Use googleapi.IsNotModified to check whether the response
22925// error from Do is the result of In-None-Match.
22926func (c *ConnectionTypesGetCall) IfNoneMatch(entityTag string) *ConnectionTypesGetCall {
22927	c.ifNoneMatch_ = entityTag
22928	return c
22929}
22930
22931// Context sets the context to be used in this call's Do method. Any
22932// pending HTTP request will be aborted if the provided context is
22933// canceled.
22934func (c *ConnectionTypesGetCall) Context(ctx context.Context) *ConnectionTypesGetCall {
22935	c.ctx_ = ctx
22936	return c
22937}
22938
22939// Header returns an http.Header that can be modified by the caller to
22940// add HTTP headers to the request.
22941func (c *ConnectionTypesGetCall) Header() http.Header {
22942	if c.header_ == nil {
22943		c.header_ = make(http.Header)
22944	}
22945	return c.header_
22946}
22947
22948func (c *ConnectionTypesGetCall) doRequest(alt string) (*http.Response, error) {
22949	reqHeaders := make(http.Header)
22950	for k, v := range c.header_ {
22951		reqHeaders[k] = v
22952	}
22953	reqHeaders.Set("User-Agent", c.s.userAgent())
22954	if c.ifNoneMatch_ != "" {
22955		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22956	}
22957	var body io.Reader = nil
22958	c.urlParams_.Set("alt", alt)
22959	c.urlParams_.Set("prettyPrint", "false")
22960	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/connectionTypes/{id}")
22961	urls += "?" + c.urlParams_.Encode()
22962	req, err := http.NewRequest("GET", urls, body)
22963	if err != nil {
22964		return nil, err
22965	}
22966	req.Header = reqHeaders
22967	googleapi.Expand(req.URL, map[string]string{
22968		"profileId": strconv.FormatInt(c.profileId, 10),
22969		"id":        strconv.FormatInt(c.id, 10),
22970	})
22971	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22972}
22973
22974// Do executes the "dfareporting.connectionTypes.get" call.
22975// Exactly one of *ConnectionType or error will be non-nil. Any non-2xx
22976// status code is an error. Response headers are in either
22977// *ConnectionType.ServerResponse.Header or (if a response was returned
22978// at all) in error.(*googleapi.Error).Header. Use
22979// googleapi.IsNotModified to check whether the returned error was
22980// because http.StatusNotModified was returned.
22981func (c *ConnectionTypesGetCall) Do(opts ...googleapi.CallOption) (*ConnectionType, error) {
22982	gensupport.SetOptions(c.urlParams_, opts...)
22983	res, err := c.doRequest("json")
22984	if res != nil && res.StatusCode == http.StatusNotModified {
22985		if res.Body != nil {
22986			res.Body.Close()
22987		}
22988		return nil, &googleapi.Error{
22989			Code:   res.StatusCode,
22990			Header: res.Header,
22991		}
22992	}
22993	if err != nil {
22994		return nil, err
22995	}
22996	defer googleapi.CloseBody(res)
22997	if err := googleapi.CheckResponse(res); err != nil {
22998		return nil, err
22999	}
23000	ret := &ConnectionType{
23001		ServerResponse: googleapi.ServerResponse{
23002			Header:         res.Header,
23003			HTTPStatusCode: res.StatusCode,
23004		},
23005	}
23006	target := &ret
23007	if err := gensupport.DecodeResponse(target, res); err != nil {
23008		return nil, err
23009	}
23010	return ret, nil
23011	// {
23012	//   "description": "Gets one connection type by ID.",
23013	//   "httpMethod": "GET",
23014	//   "id": "dfareporting.connectionTypes.get",
23015	//   "parameterOrder": [
23016	//     "profileId",
23017	//     "id"
23018	//   ],
23019	//   "parameters": {
23020	//     "id": {
23021	//       "description": "Connection type ID.",
23022	//       "format": "int64",
23023	//       "location": "path",
23024	//       "required": true,
23025	//       "type": "string"
23026	//     },
23027	//     "profileId": {
23028	//       "description": "User profile ID associated with this request.",
23029	//       "format": "int64",
23030	//       "location": "path",
23031	//       "required": true,
23032	//       "type": "string"
23033	//     }
23034	//   },
23035	//   "path": "userprofiles/{profileId}/connectionTypes/{id}",
23036	//   "response": {
23037	//     "$ref": "ConnectionType"
23038	//   },
23039	//   "scopes": [
23040	//     "https://www.googleapis.com/auth/dfatrafficking"
23041	//   ]
23042	// }
23043
23044}
23045
23046// method id "dfareporting.connectionTypes.list":
23047
23048type ConnectionTypesListCall struct {
23049	s            *Service
23050	profileId    int64
23051	urlParams_   gensupport.URLParams
23052	ifNoneMatch_ string
23053	ctx_         context.Context
23054	header_      http.Header
23055}
23056
23057// List: Retrieves a list of connection types.
23058func (r *ConnectionTypesService) List(profileId int64) *ConnectionTypesListCall {
23059	c := &ConnectionTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23060	c.profileId = profileId
23061	return c
23062}
23063
23064// Fields allows partial responses to be retrieved. See
23065// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23066// for more information.
23067func (c *ConnectionTypesListCall) Fields(s ...googleapi.Field) *ConnectionTypesListCall {
23068	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23069	return c
23070}
23071
23072// IfNoneMatch sets the optional parameter which makes the operation
23073// fail if the object's ETag matches the given value. This is useful for
23074// getting updates only after the object has changed since the last
23075// request. Use googleapi.IsNotModified to check whether the response
23076// error from Do is the result of In-None-Match.
23077func (c *ConnectionTypesListCall) IfNoneMatch(entityTag string) *ConnectionTypesListCall {
23078	c.ifNoneMatch_ = entityTag
23079	return c
23080}
23081
23082// Context sets the context to be used in this call's Do method. Any
23083// pending HTTP request will be aborted if the provided context is
23084// canceled.
23085func (c *ConnectionTypesListCall) Context(ctx context.Context) *ConnectionTypesListCall {
23086	c.ctx_ = ctx
23087	return c
23088}
23089
23090// Header returns an http.Header that can be modified by the caller to
23091// add HTTP headers to the request.
23092func (c *ConnectionTypesListCall) Header() http.Header {
23093	if c.header_ == nil {
23094		c.header_ = make(http.Header)
23095	}
23096	return c.header_
23097}
23098
23099func (c *ConnectionTypesListCall) doRequest(alt string) (*http.Response, error) {
23100	reqHeaders := make(http.Header)
23101	for k, v := range c.header_ {
23102		reqHeaders[k] = v
23103	}
23104	reqHeaders.Set("User-Agent", c.s.userAgent())
23105	if c.ifNoneMatch_ != "" {
23106		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23107	}
23108	var body io.Reader = nil
23109	c.urlParams_.Set("alt", alt)
23110	c.urlParams_.Set("prettyPrint", "false")
23111	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/connectionTypes")
23112	urls += "?" + c.urlParams_.Encode()
23113	req, err := http.NewRequest("GET", urls, body)
23114	if err != nil {
23115		return nil, err
23116	}
23117	req.Header = reqHeaders
23118	googleapi.Expand(req.URL, map[string]string{
23119		"profileId": strconv.FormatInt(c.profileId, 10),
23120	})
23121	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23122}
23123
23124// Do executes the "dfareporting.connectionTypes.list" call.
23125// Exactly one of *ConnectionTypesListResponse or error will be non-nil.
23126// Any non-2xx status code is an error. Response headers are in either
23127// *ConnectionTypesListResponse.ServerResponse.Header or (if a response
23128// was returned at all) in error.(*googleapi.Error).Header. Use
23129// googleapi.IsNotModified to check whether the returned error was
23130// because http.StatusNotModified was returned.
23131func (c *ConnectionTypesListCall) Do(opts ...googleapi.CallOption) (*ConnectionTypesListResponse, error) {
23132	gensupport.SetOptions(c.urlParams_, opts...)
23133	res, err := c.doRequest("json")
23134	if res != nil && res.StatusCode == http.StatusNotModified {
23135		if res.Body != nil {
23136			res.Body.Close()
23137		}
23138		return nil, &googleapi.Error{
23139			Code:   res.StatusCode,
23140			Header: res.Header,
23141		}
23142	}
23143	if err != nil {
23144		return nil, err
23145	}
23146	defer googleapi.CloseBody(res)
23147	if err := googleapi.CheckResponse(res); err != nil {
23148		return nil, err
23149	}
23150	ret := &ConnectionTypesListResponse{
23151		ServerResponse: googleapi.ServerResponse{
23152			Header:         res.Header,
23153			HTTPStatusCode: res.StatusCode,
23154		},
23155	}
23156	target := &ret
23157	if err := gensupport.DecodeResponse(target, res); err != nil {
23158		return nil, err
23159	}
23160	return ret, nil
23161	// {
23162	//   "description": "Retrieves a list of connection types.",
23163	//   "httpMethod": "GET",
23164	//   "id": "dfareporting.connectionTypes.list",
23165	//   "parameterOrder": [
23166	//     "profileId"
23167	//   ],
23168	//   "parameters": {
23169	//     "profileId": {
23170	//       "description": "User profile ID associated with this request.",
23171	//       "format": "int64",
23172	//       "location": "path",
23173	//       "required": true,
23174	//       "type": "string"
23175	//     }
23176	//   },
23177	//   "path": "userprofiles/{profileId}/connectionTypes",
23178	//   "response": {
23179	//     "$ref": "ConnectionTypesListResponse"
23180	//   },
23181	//   "scopes": [
23182	//     "https://www.googleapis.com/auth/dfatrafficking"
23183	//   ]
23184	// }
23185
23186}
23187
23188// method id "dfareporting.contentCategories.delete":
23189
23190type ContentCategoriesDeleteCall struct {
23191	s          *Service
23192	profileId  int64
23193	id         int64
23194	urlParams_ gensupport.URLParams
23195	ctx_       context.Context
23196	header_    http.Header
23197}
23198
23199// Delete: Deletes an existing content category.
23200func (r *ContentCategoriesService) Delete(profileId int64, id int64) *ContentCategoriesDeleteCall {
23201	c := &ContentCategoriesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23202	c.profileId = profileId
23203	c.id = id
23204	return c
23205}
23206
23207// Fields allows partial responses to be retrieved. See
23208// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23209// for more information.
23210func (c *ContentCategoriesDeleteCall) Fields(s ...googleapi.Field) *ContentCategoriesDeleteCall {
23211	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23212	return c
23213}
23214
23215// Context sets the context to be used in this call's Do method. Any
23216// pending HTTP request will be aborted if the provided context is
23217// canceled.
23218func (c *ContentCategoriesDeleteCall) Context(ctx context.Context) *ContentCategoriesDeleteCall {
23219	c.ctx_ = ctx
23220	return c
23221}
23222
23223// Header returns an http.Header that can be modified by the caller to
23224// add HTTP headers to the request.
23225func (c *ContentCategoriesDeleteCall) Header() http.Header {
23226	if c.header_ == nil {
23227		c.header_ = make(http.Header)
23228	}
23229	return c.header_
23230}
23231
23232func (c *ContentCategoriesDeleteCall) doRequest(alt string) (*http.Response, error) {
23233	reqHeaders := make(http.Header)
23234	for k, v := range c.header_ {
23235		reqHeaders[k] = v
23236	}
23237	reqHeaders.Set("User-Agent", c.s.userAgent())
23238	var body io.Reader = nil
23239	c.urlParams_.Set("alt", alt)
23240	c.urlParams_.Set("prettyPrint", "false")
23241	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories/{id}")
23242	urls += "?" + c.urlParams_.Encode()
23243	req, err := http.NewRequest("DELETE", urls, body)
23244	if err != nil {
23245		return nil, err
23246	}
23247	req.Header = reqHeaders
23248	googleapi.Expand(req.URL, map[string]string{
23249		"profileId": strconv.FormatInt(c.profileId, 10),
23250		"id":        strconv.FormatInt(c.id, 10),
23251	})
23252	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23253}
23254
23255// Do executes the "dfareporting.contentCategories.delete" call.
23256func (c *ContentCategoriesDeleteCall) Do(opts ...googleapi.CallOption) error {
23257	gensupport.SetOptions(c.urlParams_, opts...)
23258	res, err := c.doRequest("json")
23259	if err != nil {
23260		return err
23261	}
23262	defer googleapi.CloseBody(res)
23263	if err := googleapi.CheckResponse(res); err != nil {
23264		return err
23265	}
23266	return nil
23267	// {
23268	//   "description": "Deletes an existing content category.",
23269	//   "httpMethod": "DELETE",
23270	//   "id": "dfareporting.contentCategories.delete",
23271	//   "parameterOrder": [
23272	//     "profileId",
23273	//     "id"
23274	//   ],
23275	//   "parameters": {
23276	//     "id": {
23277	//       "description": "Content category ID.",
23278	//       "format": "int64",
23279	//       "location": "path",
23280	//       "required": true,
23281	//       "type": "string"
23282	//     },
23283	//     "profileId": {
23284	//       "description": "User profile ID associated with this request.",
23285	//       "format": "int64",
23286	//       "location": "path",
23287	//       "required": true,
23288	//       "type": "string"
23289	//     }
23290	//   },
23291	//   "path": "userprofiles/{profileId}/contentCategories/{id}",
23292	//   "scopes": [
23293	//     "https://www.googleapis.com/auth/dfatrafficking"
23294	//   ]
23295	// }
23296
23297}
23298
23299// method id "dfareporting.contentCategories.get":
23300
23301type ContentCategoriesGetCall struct {
23302	s            *Service
23303	profileId    int64
23304	id           int64
23305	urlParams_   gensupport.URLParams
23306	ifNoneMatch_ string
23307	ctx_         context.Context
23308	header_      http.Header
23309}
23310
23311// Get: Gets one content category by ID.
23312func (r *ContentCategoriesService) Get(profileId int64, id int64) *ContentCategoriesGetCall {
23313	c := &ContentCategoriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23314	c.profileId = profileId
23315	c.id = id
23316	return c
23317}
23318
23319// Fields allows partial responses to be retrieved. See
23320// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23321// for more information.
23322func (c *ContentCategoriesGetCall) Fields(s ...googleapi.Field) *ContentCategoriesGetCall {
23323	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23324	return c
23325}
23326
23327// IfNoneMatch sets the optional parameter which makes the operation
23328// fail if the object's ETag matches the given value. This is useful for
23329// getting updates only after the object has changed since the last
23330// request. Use googleapi.IsNotModified to check whether the response
23331// error from Do is the result of In-None-Match.
23332func (c *ContentCategoriesGetCall) IfNoneMatch(entityTag string) *ContentCategoriesGetCall {
23333	c.ifNoneMatch_ = entityTag
23334	return c
23335}
23336
23337// Context sets the context to be used in this call's Do method. Any
23338// pending HTTP request will be aborted if the provided context is
23339// canceled.
23340func (c *ContentCategoriesGetCall) Context(ctx context.Context) *ContentCategoriesGetCall {
23341	c.ctx_ = ctx
23342	return c
23343}
23344
23345// Header returns an http.Header that can be modified by the caller to
23346// add HTTP headers to the request.
23347func (c *ContentCategoriesGetCall) Header() http.Header {
23348	if c.header_ == nil {
23349		c.header_ = make(http.Header)
23350	}
23351	return c.header_
23352}
23353
23354func (c *ContentCategoriesGetCall) doRequest(alt string) (*http.Response, error) {
23355	reqHeaders := make(http.Header)
23356	for k, v := range c.header_ {
23357		reqHeaders[k] = v
23358	}
23359	reqHeaders.Set("User-Agent", c.s.userAgent())
23360	if c.ifNoneMatch_ != "" {
23361		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23362	}
23363	var body io.Reader = nil
23364	c.urlParams_.Set("alt", alt)
23365	c.urlParams_.Set("prettyPrint", "false")
23366	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories/{id}")
23367	urls += "?" + c.urlParams_.Encode()
23368	req, err := http.NewRequest("GET", urls, body)
23369	if err != nil {
23370		return nil, err
23371	}
23372	req.Header = reqHeaders
23373	googleapi.Expand(req.URL, map[string]string{
23374		"profileId": strconv.FormatInt(c.profileId, 10),
23375		"id":        strconv.FormatInt(c.id, 10),
23376	})
23377	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23378}
23379
23380// Do executes the "dfareporting.contentCategories.get" call.
23381// Exactly one of *ContentCategory or error will be non-nil. Any non-2xx
23382// status code is an error. Response headers are in either
23383// *ContentCategory.ServerResponse.Header or (if a response was returned
23384// at all) in error.(*googleapi.Error).Header. Use
23385// googleapi.IsNotModified to check whether the returned error was
23386// because http.StatusNotModified was returned.
23387func (c *ContentCategoriesGetCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
23388	gensupport.SetOptions(c.urlParams_, opts...)
23389	res, err := c.doRequest("json")
23390	if res != nil && res.StatusCode == http.StatusNotModified {
23391		if res.Body != nil {
23392			res.Body.Close()
23393		}
23394		return nil, &googleapi.Error{
23395			Code:   res.StatusCode,
23396			Header: res.Header,
23397		}
23398	}
23399	if err != nil {
23400		return nil, err
23401	}
23402	defer googleapi.CloseBody(res)
23403	if err := googleapi.CheckResponse(res); err != nil {
23404		return nil, err
23405	}
23406	ret := &ContentCategory{
23407		ServerResponse: googleapi.ServerResponse{
23408			Header:         res.Header,
23409			HTTPStatusCode: res.StatusCode,
23410		},
23411	}
23412	target := &ret
23413	if err := gensupport.DecodeResponse(target, res); err != nil {
23414		return nil, err
23415	}
23416	return ret, nil
23417	// {
23418	//   "description": "Gets one content category by ID.",
23419	//   "httpMethod": "GET",
23420	//   "id": "dfareporting.contentCategories.get",
23421	//   "parameterOrder": [
23422	//     "profileId",
23423	//     "id"
23424	//   ],
23425	//   "parameters": {
23426	//     "id": {
23427	//       "description": "Content category ID.",
23428	//       "format": "int64",
23429	//       "location": "path",
23430	//       "required": true,
23431	//       "type": "string"
23432	//     },
23433	//     "profileId": {
23434	//       "description": "User profile ID associated with this request.",
23435	//       "format": "int64",
23436	//       "location": "path",
23437	//       "required": true,
23438	//       "type": "string"
23439	//     }
23440	//   },
23441	//   "path": "userprofiles/{profileId}/contentCategories/{id}",
23442	//   "response": {
23443	//     "$ref": "ContentCategory"
23444	//   },
23445	//   "scopes": [
23446	//     "https://www.googleapis.com/auth/dfatrafficking"
23447	//   ]
23448	// }
23449
23450}
23451
23452// method id "dfareporting.contentCategories.insert":
23453
23454type ContentCategoriesInsertCall struct {
23455	s               *Service
23456	profileId       int64
23457	contentcategory *ContentCategory
23458	urlParams_      gensupport.URLParams
23459	ctx_            context.Context
23460	header_         http.Header
23461}
23462
23463// Insert: Inserts a new content category.
23464func (r *ContentCategoriesService) Insert(profileId int64, contentcategory *ContentCategory) *ContentCategoriesInsertCall {
23465	c := &ContentCategoriesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23466	c.profileId = profileId
23467	c.contentcategory = contentcategory
23468	return c
23469}
23470
23471// Fields allows partial responses to be retrieved. See
23472// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23473// for more information.
23474func (c *ContentCategoriesInsertCall) Fields(s ...googleapi.Field) *ContentCategoriesInsertCall {
23475	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23476	return c
23477}
23478
23479// Context sets the context to be used in this call's Do method. Any
23480// pending HTTP request will be aborted if the provided context is
23481// canceled.
23482func (c *ContentCategoriesInsertCall) Context(ctx context.Context) *ContentCategoriesInsertCall {
23483	c.ctx_ = ctx
23484	return c
23485}
23486
23487// Header returns an http.Header that can be modified by the caller to
23488// add HTTP headers to the request.
23489func (c *ContentCategoriesInsertCall) Header() http.Header {
23490	if c.header_ == nil {
23491		c.header_ = make(http.Header)
23492	}
23493	return c.header_
23494}
23495
23496func (c *ContentCategoriesInsertCall) doRequest(alt string) (*http.Response, error) {
23497	reqHeaders := make(http.Header)
23498	for k, v := range c.header_ {
23499		reqHeaders[k] = v
23500	}
23501	reqHeaders.Set("User-Agent", c.s.userAgent())
23502	var body io.Reader = nil
23503	body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
23504	if err != nil {
23505		return nil, err
23506	}
23507	reqHeaders.Set("Content-Type", "application/json")
23508	c.urlParams_.Set("alt", alt)
23509	c.urlParams_.Set("prettyPrint", "false")
23510	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
23511	urls += "?" + c.urlParams_.Encode()
23512	req, err := http.NewRequest("POST", urls, body)
23513	if err != nil {
23514		return nil, err
23515	}
23516	req.Header = reqHeaders
23517	googleapi.Expand(req.URL, map[string]string{
23518		"profileId": strconv.FormatInt(c.profileId, 10),
23519	})
23520	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23521}
23522
23523// Do executes the "dfareporting.contentCategories.insert" call.
23524// Exactly one of *ContentCategory or error will be non-nil. Any non-2xx
23525// status code is an error. Response headers are in either
23526// *ContentCategory.ServerResponse.Header or (if a response was returned
23527// at all) in error.(*googleapi.Error).Header. Use
23528// googleapi.IsNotModified to check whether the returned error was
23529// because http.StatusNotModified was returned.
23530func (c *ContentCategoriesInsertCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
23531	gensupport.SetOptions(c.urlParams_, opts...)
23532	res, err := c.doRequest("json")
23533	if res != nil && res.StatusCode == http.StatusNotModified {
23534		if res.Body != nil {
23535			res.Body.Close()
23536		}
23537		return nil, &googleapi.Error{
23538			Code:   res.StatusCode,
23539			Header: res.Header,
23540		}
23541	}
23542	if err != nil {
23543		return nil, err
23544	}
23545	defer googleapi.CloseBody(res)
23546	if err := googleapi.CheckResponse(res); err != nil {
23547		return nil, err
23548	}
23549	ret := &ContentCategory{
23550		ServerResponse: googleapi.ServerResponse{
23551			Header:         res.Header,
23552			HTTPStatusCode: res.StatusCode,
23553		},
23554	}
23555	target := &ret
23556	if err := gensupport.DecodeResponse(target, res); err != nil {
23557		return nil, err
23558	}
23559	return ret, nil
23560	// {
23561	//   "description": "Inserts a new content category.",
23562	//   "httpMethod": "POST",
23563	//   "id": "dfareporting.contentCategories.insert",
23564	//   "parameterOrder": [
23565	//     "profileId"
23566	//   ],
23567	//   "parameters": {
23568	//     "profileId": {
23569	//       "description": "User profile ID associated with this request.",
23570	//       "format": "int64",
23571	//       "location": "path",
23572	//       "required": true,
23573	//       "type": "string"
23574	//     }
23575	//   },
23576	//   "path": "userprofiles/{profileId}/contentCategories",
23577	//   "request": {
23578	//     "$ref": "ContentCategory"
23579	//   },
23580	//   "response": {
23581	//     "$ref": "ContentCategory"
23582	//   },
23583	//   "scopes": [
23584	//     "https://www.googleapis.com/auth/dfatrafficking"
23585	//   ]
23586	// }
23587
23588}
23589
23590// method id "dfareporting.contentCategories.list":
23591
23592type ContentCategoriesListCall struct {
23593	s            *Service
23594	profileId    int64
23595	urlParams_   gensupport.URLParams
23596	ifNoneMatch_ string
23597	ctx_         context.Context
23598	header_      http.Header
23599}
23600
23601// List: Retrieves a list of content categories, possibly filtered. This
23602// method supports paging.
23603func (r *ContentCategoriesService) List(profileId int64) *ContentCategoriesListCall {
23604	c := &ContentCategoriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23605	c.profileId = profileId
23606	return c
23607}
23608
23609// Ids sets the optional parameter "ids": Select only content categories
23610// with these IDs.
23611func (c *ContentCategoriesListCall) Ids(ids ...int64) *ContentCategoriesListCall {
23612	var ids_ []string
23613	for _, v := range ids {
23614		ids_ = append(ids_, fmt.Sprint(v))
23615	}
23616	c.urlParams_.SetMulti("ids", ids_)
23617	return c
23618}
23619
23620// MaxResults sets the optional parameter "maxResults": Maximum number
23621// of results to return.
23622func (c *ContentCategoriesListCall) MaxResults(maxResults int64) *ContentCategoriesListCall {
23623	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
23624	return c
23625}
23626
23627// PageToken sets the optional parameter "pageToken": Value of the
23628// nextPageToken from the previous result page.
23629func (c *ContentCategoriesListCall) PageToken(pageToken string) *ContentCategoriesListCall {
23630	c.urlParams_.Set("pageToken", pageToken)
23631	return c
23632}
23633
23634// SearchString sets the optional parameter "searchString": Allows
23635// searching for objects by name or ID. Wildcards (*) are allowed. For
23636// example, "contentcategory*2015" will return objects with names like
23637// "contentcategory June 2015", "contentcategory April 2015", or simply
23638// "contentcategory 2015". Most of the searches also add wildcards
23639// implicitly at the start and the end of the search string. For
23640// example, a search string of "contentcategory" will match objects with
23641// name "my contentcategory", "contentcategory 2015", or simply
23642// "contentcategory".
23643func (c *ContentCategoriesListCall) SearchString(searchString string) *ContentCategoriesListCall {
23644	c.urlParams_.Set("searchString", searchString)
23645	return c
23646}
23647
23648// SortField sets the optional parameter "sortField": Field by which to
23649// sort the list.
23650//
23651// Possible values:
23652//   "ID" (default)
23653//   "NAME"
23654func (c *ContentCategoriesListCall) SortField(sortField string) *ContentCategoriesListCall {
23655	c.urlParams_.Set("sortField", sortField)
23656	return c
23657}
23658
23659// SortOrder sets the optional parameter "sortOrder": Order of sorted
23660// results.
23661//
23662// Possible values:
23663//   "ASCENDING" (default)
23664//   "DESCENDING"
23665func (c *ContentCategoriesListCall) SortOrder(sortOrder string) *ContentCategoriesListCall {
23666	c.urlParams_.Set("sortOrder", sortOrder)
23667	return c
23668}
23669
23670// Fields allows partial responses to be retrieved. See
23671// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23672// for more information.
23673func (c *ContentCategoriesListCall) Fields(s ...googleapi.Field) *ContentCategoriesListCall {
23674	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23675	return c
23676}
23677
23678// IfNoneMatch sets the optional parameter which makes the operation
23679// fail if the object's ETag matches the given value. This is useful for
23680// getting updates only after the object has changed since the last
23681// request. Use googleapi.IsNotModified to check whether the response
23682// error from Do is the result of In-None-Match.
23683func (c *ContentCategoriesListCall) IfNoneMatch(entityTag string) *ContentCategoriesListCall {
23684	c.ifNoneMatch_ = entityTag
23685	return c
23686}
23687
23688// Context sets the context to be used in this call's Do method. Any
23689// pending HTTP request will be aborted if the provided context is
23690// canceled.
23691func (c *ContentCategoriesListCall) Context(ctx context.Context) *ContentCategoriesListCall {
23692	c.ctx_ = ctx
23693	return c
23694}
23695
23696// Header returns an http.Header that can be modified by the caller to
23697// add HTTP headers to the request.
23698func (c *ContentCategoriesListCall) Header() http.Header {
23699	if c.header_ == nil {
23700		c.header_ = make(http.Header)
23701	}
23702	return c.header_
23703}
23704
23705func (c *ContentCategoriesListCall) doRequest(alt string) (*http.Response, error) {
23706	reqHeaders := make(http.Header)
23707	for k, v := range c.header_ {
23708		reqHeaders[k] = v
23709	}
23710	reqHeaders.Set("User-Agent", c.s.userAgent())
23711	if c.ifNoneMatch_ != "" {
23712		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23713	}
23714	var body io.Reader = nil
23715	c.urlParams_.Set("alt", alt)
23716	c.urlParams_.Set("prettyPrint", "false")
23717	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
23718	urls += "?" + c.urlParams_.Encode()
23719	req, err := http.NewRequest("GET", urls, body)
23720	if err != nil {
23721		return nil, err
23722	}
23723	req.Header = reqHeaders
23724	googleapi.Expand(req.URL, map[string]string{
23725		"profileId": strconv.FormatInt(c.profileId, 10),
23726	})
23727	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23728}
23729
23730// Do executes the "dfareporting.contentCategories.list" call.
23731// Exactly one of *ContentCategoriesListResponse or error will be
23732// non-nil. Any non-2xx status code is an error. Response headers are in
23733// either *ContentCategoriesListResponse.ServerResponse.Header or (if a
23734// response was returned at all) in error.(*googleapi.Error).Header. Use
23735// googleapi.IsNotModified to check whether the returned error was
23736// because http.StatusNotModified was returned.
23737func (c *ContentCategoriesListCall) Do(opts ...googleapi.CallOption) (*ContentCategoriesListResponse, error) {
23738	gensupport.SetOptions(c.urlParams_, opts...)
23739	res, err := c.doRequest("json")
23740	if res != nil && res.StatusCode == http.StatusNotModified {
23741		if res.Body != nil {
23742			res.Body.Close()
23743		}
23744		return nil, &googleapi.Error{
23745			Code:   res.StatusCode,
23746			Header: res.Header,
23747		}
23748	}
23749	if err != nil {
23750		return nil, err
23751	}
23752	defer googleapi.CloseBody(res)
23753	if err := googleapi.CheckResponse(res); err != nil {
23754		return nil, err
23755	}
23756	ret := &ContentCategoriesListResponse{
23757		ServerResponse: googleapi.ServerResponse{
23758			Header:         res.Header,
23759			HTTPStatusCode: res.StatusCode,
23760		},
23761	}
23762	target := &ret
23763	if err := gensupport.DecodeResponse(target, res); err != nil {
23764		return nil, err
23765	}
23766	return ret, nil
23767	// {
23768	//   "description": "Retrieves a list of content categories, possibly filtered. This method supports paging.",
23769	//   "httpMethod": "GET",
23770	//   "id": "dfareporting.contentCategories.list",
23771	//   "parameterOrder": [
23772	//     "profileId"
23773	//   ],
23774	//   "parameters": {
23775	//     "ids": {
23776	//       "description": "Select only content categories with these IDs.",
23777	//       "format": "int64",
23778	//       "location": "query",
23779	//       "repeated": true,
23780	//       "type": "string"
23781	//     },
23782	//     "maxResults": {
23783	//       "default": "1000",
23784	//       "description": "Maximum number of results to return.",
23785	//       "format": "int32",
23786	//       "location": "query",
23787	//       "maximum": "1000",
23788	//       "minimum": "0",
23789	//       "type": "integer"
23790	//     },
23791	//     "pageToken": {
23792	//       "description": "Value of the nextPageToken from the previous result page.",
23793	//       "location": "query",
23794	//       "type": "string"
23795	//     },
23796	//     "profileId": {
23797	//       "description": "User profile ID associated with this request.",
23798	//       "format": "int64",
23799	//       "location": "path",
23800	//       "required": true,
23801	//       "type": "string"
23802	//     },
23803	//     "searchString": {
23804	//       "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\".",
23805	//       "location": "query",
23806	//       "type": "string"
23807	//     },
23808	//     "sortField": {
23809	//       "default": "ID",
23810	//       "description": "Field by which to sort the list.",
23811	//       "enum": [
23812	//         "ID",
23813	//         "NAME"
23814	//       ],
23815	//       "enumDescriptions": [
23816	//         "",
23817	//         ""
23818	//       ],
23819	//       "location": "query",
23820	//       "type": "string"
23821	//     },
23822	//     "sortOrder": {
23823	//       "default": "ASCENDING",
23824	//       "description": "Order of sorted results.",
23825	//       "enum": [
23826	//         "ASCENDING",
23827	//         "DESCENDING"
23828	//       ],
23829	//       "enumDescriptions": [
23830	//         "",
23831	//         ""
23832	//       ],
23833	//       "location": "query",
23834	//       "type": "string"
23835	//     }
23836	//   },
23837	//   "path": "userprofiles/{profileId}/contentCategories",
23838	//   "response": {
23839	//     "$ref": "ContentCategoriesListResponse"
23840	//   },
23841	//   "scopes": [
23842	//     "https://www.googleapis.com/auth/dfatrafficking"
23843	//   ]
23844	// }
23845
23846}
23847
23848// Pages invokes f for each page of results.
23849// A non-nil error returned from f will halt the iteration.
23850// The provided context supersedes any context provided to the Context method.
23851func (c *ContentCategoriesListCall) Pages(ctx context.Context, f func(*ContentCategoriesListResponse) error) error {
23852	c.ctx_ = ctx
23853	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
23854	for {
23855		x, err := c.Do()
23856		if err != nil {
23857			return err
23858		}
23859		if err := f(x); err != nil {
23860			return err
23861		}
23862		if x.NextPageToken == "" {
23863			return nil
23864		}
23865		c.PageToken(x.NextPageToken)
23866	}
23867}
23868
23869// method id "dfareporting.contentCategories.patch":
23870
23871type ContentCategoriesPatchCall struct {
23872	s               *Service
23873	profileId       int64
23874	contentcategory *ContentCategory
23875	urlParams_      gensupport.URLParams
23876	ctx_            context.Context
23877	header_         http.Header
23878}
23879
23880// Patch: Updates an existing content category. This method supports
23881// patch semantics.
23882func (r *ContentCategoriesService) Patch(profileId int64, id int64, contentcategory *ContentCategory) *ContentCategoriesPatchCall {
23883	c := &ContentCategoriesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23884	c.profileId = profileId
23885	c.urlParams_.Set("id", fmt.Sprint(id))
23886	c.contentcategory = contentcategory
23887	return c
23888}
23889
23890// Fields allows partial responses to be retrieved. See
23891// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23892// for more information.
23893func (c *ContentCategoriesPatchCall) Fields(s ...googleapi.Field) *ContentCategoriesPatchCall {
23894	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23895	return c
23896}
23897
23898// Context sets the context to be used in this call's Do method. Any
23899// pending HTTP request will be aborted if the provided context is
23900// canceled.
23901func (c *ContentCategoriesPatchCall) Context(ctx context.Context) *ContentCategoriesPatchCall {
23902	c.ctx_ = ctx
23903	return c
23904}
23905
23906// Header returns an http.Header that can be modified by the caller to
23907// add HTTP headers to the request.
23908func (c *ContentCategoriesPatchCall) Header() http.Header {
23909	if c.header_ == nil {
23910		c.header_ = make(http.Header)
23911	}
23912	return c.header_
23913}
23914
23915func (c *ContentCategoriesPatchCall) doRequest(alt string) (*http.Response, error) {
23916	reqHeaders := make(http.Header)
23917	for k, v := range c.header_ {
23918		reqHeaders[k] = v
23919	}
23920	reqHeaders.Set("User-Agent", c.s.userAgent())
23921	var body io.Reader = nil
23922	body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
23923	if err != nil {
23924		return nil, err
23925	}
23926	reqHeaders.Set("Content-Type", "application/json")
23927	c.urlParams_.Set("alt", alt)
23928	c.urlParams_.Set("prettyPrint", "false")
23929	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
23930	urls += "?" + c.urlParams_.Encode()
23931	req, err := http.NewRequest("PATCH", urls, body)
23932	if err != nil {
23933		return nil, err
23934	}
23935	req.Header = reqHeaders
23936	googleapi.Expand(req.URL, map[string]string{
23937		"profileId": strconv.FormatInt(c.profileId, 10),
23938	})
23939	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23940}
23941
23942// Do executes the "dfareporting.contentCategories.patch" call.
23943// Exactly one of *ContentCategory or error will be non-nil. Any non-2xx
23944// status code is an error. Response headers are in either
23945// *ContentCategory.ServerResponse.Header or (if a response was returned
23946// at all) in error.(*googleapi.Error).Header. Use
23947// googleapi.IsNotModified to check whether the returned error was
23948// because http.StatusNotModified was returned.
23949func (c *ContentCategoriesPatchCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
23950	gensupport.SetOptions(c.urlParams_, opts...)
23951	res, err := c.doRequest("json")
23952	if res != nil && res.StatusCode == http.StatusNotModified {
23953		if res.Body != nil {
23954			res.Body.Close()
23955		}
23956		return nil, &googleapi.Error{
23957			Code:   res.StatusCode,
23958			Header: res.Header,
23959		}
23960	}
23961	if err != nil {
23962		return nil, err
23963	}
23964	defer googleapi.CloseBody(res)
23965	if err := googleapi.CheckResponse(res); err != nil {
23966		return nil, err
23967	}
23968	ret := &ContentCategory{
23969		ServerResponse: googleapi.ServerResponse{
23970			Header:         res.Header,
23971			HTTPStatusCode: res.StatusCode,
23972		},
23973	}
23974	target := &ret
23975	if err := gensupport.DecodeResponse(target, res); err != nil {
23976		return nil, err
23977	}
23978	return ret, nil
23979	// {
23980	//   "description": "Updates an existing content category. This method supports patch semantics.",
23981	//   "httpMethod": "PATCH",
23982	//   "id": "dfareporting.contentCategories.patch",
23983	//   "parameterOrder": [
23984	//     "profileId",
23985	//     "id"
23986	//   ],
23987	//   "parameters": {
23988	//     "id": {
23989	//       "description": "Content category ID.",
23990	//       "format": "int64",
23991	//       "location": "query",
23992	//       "required": true,
23993	//       "type": "string"
23994	//     },
23995	//     "profileId": {
23996	//       "description": "User profile ID associated with this request.",
23997	//       "format": "int64",
23998	//       "location": "path",
23999	//       "required": true,
24000	//       "type": "string"
24001	//     }
24002	//   },
24003	//   "path": "userprofiles/{profileId}/contentCategories",
24004	//   "request": {
24005	//     "$ref": "ContentCategory"
24006	//   },
24007	//   "response": {
24008	//     "$ref": "ContentCategory"
24009	//   },
24010	//   "scopes": [
24011	//     "https://www.googleapis.com/auth/dfatrafficking"
24012	//   ]
24013	// }
24014
24015}
24016
24017// method id "dfareporting.contentCategories.update":
24018
24019type ContentCategoriesUpdateCall struct {
24020	s               *Service
24021	profileId       int64
24022	contentcategory *ContentCategory
24023	urlParams_      gensupport.URLParams
24024	ctx_            context.Context
24025	header_         http.Header
24026}
24027
24028// Update: Updates an existing content category.
24029func (r *ContentCategoriesService) Update(profileId int64, contentcategory *ContentCategory) *ContentCategoriesUpdateCall {
24030	c := &ContentCategoriesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24031	c.profileId = profileId
24032	c.contentcategory = contentcategory
24033	return c
24034}
24035
24036// Fields allows partial responses to be retrieved. See
24037// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24038// for more information.
24039func (c *ContentCategoriesUpdateCall) Fields(s ...googleapi.Field) *ContentCategoriesUpdateCall {
24040	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24041	return c
24042}
24043
24044// Context sets the context to be used in this call's Do method. Any
24045// pending HTTP request will be aborted if the provided context is
24046// canceled.
24047func (c *ContentCategoriesUpdateCall) Context(ctx context.Context) *ContentCategoriesUpdateCall {
24048	c.ctx_ = ctx
24049	return c
24050}
24051
24052// Header returns an http.Header that can be modified by the caller to
24053// add HTTP headers to the request.
24054func (c *ContentCategoriesUpdateCall) Header() http.Header {
24055	if c.header_ == nil {
24056		c.header_ = make(http.Header)
24057	}
24058	return c.header_
24059}
24060
24061func (c *ContentCategoriesUpdateCall) doRequest(alt string) (*http.Response, error) {
24062	reqHeaders := make(http.Header)
24063	for k, v := range c.header_ {
24064		reqHeaders[k] = v
24065	}
24066	reqHeaders.Set("User-Agent", c.s.userAgent())
24067	var body io.Reader = nil
24068	body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
24069	if err != nil {
24070		return nil, err
24071	}
24072	reqHeaders.Set("Content-Type", "application/json")
24073	c.urlParams_.Set("alt", alt)
24074	c.urlParams_.Set("prettyPrint", "false")
24075	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
24076	urls += "?" + c.urlParams_.Encode()
24077	req, err := http.NewRequest("PUT", urls, body)
24078	if err != nil {
24079		return nil, err
24080	}
24081	req.Header = reqHeaders
24082	googleapi.Expand(req.URL, map[string]string{
24083		"profileId": strconv.FormatInt(c.profileId, 10),
24084	})
24085	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24086}
24087
24088// Do executes the "dfareporting.contentCategories.update" call.
24089// Exactly one of *ContentCategory or error will be non-nil. Any non-2xx
24090// status code is an error. Response headers are in either
24091// *ContentCategory.ServerResponse.Header or (if a response was returned
24092// at all) in error.(*googleapi.Error).Header. Use
24093// googleapi.IsNotModified to check whether the returned error was
24094// because http.StatusNotModified was returned.
24095func (c *ContentCategoriesUpdateCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
24096	gensupport.SetOptions(c.urlParams_, opts...)
24097	res, err := c.doRequest("json")
24098	if res != nil && res.StatusCode == http.StatusNotModified {
24099		if res.Body != nil {
24100			res.Body.Close()
24101		}
24102		return nil, &googleapi.Error{
24103			Code:   res.StatusCode,
24104			Header: res.Header,
24105		}
24106	}
24107	if err != nil {
24108		return nil, err
24109	}
24110	defer googleapi.CloseBody(res)
24111	if err := googleapi.CheckResponse(res); err != nil {
24112		return nil, err
24113	}
24114	ret := &ContentCategory{
24115		ServerResponse: googleapi.ServerResponse{
24116			Header:         res.Header,
24117			HTTPStatusCode: res.StatusCode,
24118		},
24119	}
24120	target := &ret
24121	if err := gensupport.DecodeResponse(target, res); err != nil {
24122		return nil, err
24123	}
24124	return ret, nil
24125	// {
24126	//   "description": "Updates an existing content category.",
24127	//   "httpMethod": "PUT",
24128	//   "id": "dfareporting.contentCategories.update",
24129	//   "parameterOrder": [
24130	//     "profileId"
24131	//   ],
24132	//   "parameters": {
24133	//     "profileId": {
24134	//       "description": "User profile ID associated with this request.",
24135	//       "format": "int64",
24136	//       "location": "path",
24137	//       "required": true,
24138	//       "type": "string"
24139	//     }
24140	//   },
24141	//   "path": "userprofiles/{profileId}/contentCategories",
24142	//   "request": {
24143	//     "$ref": "ContentCategory"
24144	//   },
24145	//   "response": {
24146	//     "$ref": "ContentCategory"
24147	//   },
24148	//   "scopes": [
24149	//     "https://www.googleapis.com/auth/dfatrafficking"
24150	//   ]
24151	// }
24152
24153}
24154
24155// method id "dfareporting.conversions.batchinsert":
24156
24157type ConversionsBatchinsertCall struct {
24158	s                             *Service
24159	profileId                     int64
24160	conversionsbatchinsertrequest *ConversionsBatchInsertRequest
24161	urlParams_                    gensupport.URLParams
24162	ctx_                          context.Context
24163	header_                       http.Header
24164}
24165
24166// Batchinsert: Inserts conversions.
24167func (r *ConversionsService) Batchinsert(profileId int64, conversionsbatchinsertrequest *ConversionsBatchInsertRequest) *ConversionsBatchinsertCall {
24168	c := &ConversionsBatchinsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24169	c.profileId = profileId
24170	c.conversionsbatchinsertrequest = conversionsbatchinsertrequest
24171	return c
24172}
24173
24174// Fields allows partial responses to be retrieved. See
24175// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24176// for more information.
24177func (c *ConversionsBatchinsertCall) Fields(s ...googleapi.Field) *ConversionsBatchinsertCall {
24178	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24179	return c
24180}
24181
24182// Context sets the context to be used in this call's Do method. Any
24183// pending HTTP request will be aborted if the provided context is
24184// canceled.
24185func (c *ConversionsBatchinsertCall) Context(ctx context.Context) *ConversionsBatchinsertCall {
24186	c.ctx_ = ctx
24187	return c
24188}
24189
24190// Header returns an http.Header that can be modified by the caller to
24191// add HTTP headers to the request.
24192func (c *ConversionsBatchinsertCall) Header() http.Header {
24193	if c.header_ == nil {
24194		c.header_ = make(http.Header)
24195	}
24196	return c.header_
24197}
24198
24199func (c *ConversionsBatchinsertCall) doRequest(alt string) (*http.Response, error) {
24200	reqHeaders := make(http.Header)
24201	for k, v := range c.header_ {
24202		reqHeaders[k] = v
24203	}
24204	reqHeaders.Set("User-Agent", c.s.userAgent())
24205	var body io.Reader = nil
24206	body, err := googleapi.WithoutDataWrapper.JSONReader(c.conversionsbatchinsertrequest)
24207	if err != nil {
24208		return nil, err
24209	}
24210	reqHeaders.Set("Content-Type", "application/json")
24211	c.urlParams_.Set("alt", alt)
24212	c.urlParams_.Set("prettyPrint", "false")
24213	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/conversions/batchinsert")
24214	urls += "?" + c.urlParams_.Encode()
24215	req, err := http.NewRequest("POST", urls, body)
24216	if err != nil {
24217		return nil, err
24218	}
24219	req.Header = reqHeaders
24220	googleapi.Expand(req.URL, map[string]string{
24221		"profileId": strconv.FormatInt(c.profileId, 10),
24222	})
24223	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24224}
24225
24226// Do executes the "dfareporting.conversions.batchinsert" call.
24227// Exactly one of *ConversionsBatchInsertResponse or error will be
24228// non-nil. Any non-2xx status code is an error. Response headers are in
24229// either *ConversionsBatchInsertResponse.ServerResponse.Header or (if a
24230// response was returned at all) in error.(*googleapi.Error).Header. Use
24231// googleapi.IsNotModified to check whether the returned error was
24232// because http.StatusNotModified was returned.
24233func (c *ConversionsBatchinsertCall) Do(opts ...googleapi.CallOption) (*ConversionsBatchInsertResponse, error) {
24234	gensupport.SetOptions(c.urlParams_, opts...)
24235	res, err := c.doRequest("json")
24236	if res != nil && res.StatusCode == http.StatusNotModified {
24237		if res.Body != nil {
24238			res.Body.Close()
24239		}
24240		return nil, &googleapi.Error{
24241			Code:   res.StatusCode,
24242			Header: res.Header,
24243		}
24244	}
24245	if err != nil {
24246		return nil, err
24247	}
24248	defer googleapi.CloseBody(res)
24249	if err := googleapi.CheckResponse(res); err != nil {
24250		return nil, err
24251	}
24252	ret := &ConversionsBatchInsertResponse{
24253		ServerResponse: googleapi.ServerResponse{
24254			Header:         res.Header,
24255			HTTPStatusCode: res.StatusCode,
24256		},
24257	}
24258	target := &ret
24259	if err := gensupport.DecodeResponse(target, res); err != nil {
24260		return nil, err
24261	}
24262	return ret, nil
24263	// {
24264	//   "description": "Inserts conversions.",
24265	//   "httpMethod": "POST",
24266	//   "id": "dfareporting.conversions.batchinsert",
24267	//   "parameterOrder": [
24268	//     "profileId"
24269	//   ],
24270	//   "parameters": {
24271	//     "profileId": {
24272	//       "description": "User profile ID associated with this request.",
24273	//       "format": "int64",
24274	//       "location": "path",
24275	//       "required": true,
24276	//       "type": "string"
24277	//     }
24278	//   },
24279	//   "path": "userprofiles/{profileId}/conversions/batchinsert",
24280	//   "request": {
24281	//     "$ref": "ConversionsBatchInsertRequest"
24282	//   },
24283	//   "response": {
24284	//     "$ref": "ConversionsBatchInsertResponse"
24285	//   },
24286	//   "scopes": [
24287	//     "https://www.googleapis.com/auth/ddmconversions"
24288	//   ]
24289	// }
24290
24291}
24292
24293// method id "dfareporting.conversions.batchupdate":
24294
24295type ConversionsBatchupdateCall struct {
24296	s                             *Service
24297	profileId                     int64
24298	conversionsbatchupdaterequest *ConversionsBatchUpdateRequest
24299	urlParams_                    gensupport.URLParams
24300	ctx_                          context.Context
24301	header_                       http.Header
24302}
24303
24304// Batchupdate: Updates existing conversions.
24305func (r *ConversionsService) Batchupdate(profileId int64, conversionsbatchupdaterequest *ConversionsBatchUpdateRequest) *ConversionsBatchupdateCall {
24306	c := &ConversionsBatchupdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24307	c.profileId = profileId
24308	c.conversionsbatchupdaterequest = conversionsbatchupdaterequest
24309	return c
24310}
24311
24312// Fields allows partial responses to be retrieved. See
24313// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24314// for more information.
24315func (c *ConversionsBatchupdateCall) Fields(s ...googleapi.Field) *ConversionsBatchupdateCall {
24316	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24317	return c
24318}
24319
24320// Context sets the context to be used in this call's Do method. Any
24321// pending HTTP request will be aborted if the provided context is
24322// canceled.
24323func (c *ConversionsBatchupdateCall) Context(ctx context.Context) *ConversionsBatchupdateCall {
24324	c.ctx_ = ctx
24325	return c
24326}
24327
24328// Header returns an http.Header that can be modified by the caller to
24329// add HTTP headers to the request.
24330func (c *ConversionsBatchupdateCall) Header() http.Header {
24331	if c.header_ == nil {
24332		c.header_ = make(http.Header)
24333	}
24334	return c.header_
24335}
24336
24337func (c *ConversionsBatchupdateCall) doRequest(alt string) (*http.Response, error) {
24338	reqHeaders := make(http.Header)
24339	for k, v := range c.header_ {
24340		reqHeaders[k] = v
24341	}
24342	reqHeaders.Set("User-Agent", c.s.userAgent())
24343	var body io.Reader = nil
24344	body, err := googleapi.WithoutDataWrapper.JSONReader(c.conversionsbatchupdaterequest)
24345	if err != nil {
24346		return nil, err
24347	}
24348	reqHeaders.Set("Content-Type", "application/json")
24349	c.urlParams_.Set("alt", alt)
24350	c.urlParams_.Set("prettyPrint", "false")
24351	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/conversions/batchupdate")
24352	urls += "?" + c.urlParams_.Encode()
24353	req, err := http.NewRequest("POST", urls, body)
24354	if err != nil {
24355		return nil, err
24356	}
24357	req.Header = reqHeaders
24358	googleapi.Expand(req.URL, map[string]string{
24359		"profileId": strconv.FormatInt(c.profileId, 10),
24360	})
24361	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24362}
24363
24364// Do executes the "dfareporting.conversions.batchupdate" call.
24365// Exactly one of *ConversionsBatchUpdateResponse or error will be
24366// non-nil. Any non-2xx status code is an error. Response headers are in
24367// either *ConversionsBatchUpdateResponse.ServerResponse.Header or (if a
24368// response was returned at all) in error.(*googleapi.Error).Header. Use
24369// googleapi.IsNotModified to check whether the returned error was
24370// because http.StatusNotModified was returned.
24371func (c *ConversionsBatchupdateCall) Do(opts ...googleapi.CallOption) (*ConversionsBatchUpdateResponse, error) {
24372	gensupport.SetOptions(c.urlParams_, opts...)
24373	res, err := c.doRequest("json")
24374	if res != nil && res.StatusCode == http.StatusNotModified {
24375		if res.Body != nil {
24376			res.Body.Close()
24377		}
24378		return nil, &googleapi.Error{
24379			Code:   res.StatusCode,
24380			Header: res.Header,
24381		}
24382	}
24383	if err != nil {
24384		return nil, err
24385	}
24386	defer googleapi.CloseBody(res)
24387	if err := googleapi.CheckResponse(res); err != nil {
24388		return nil, err
24389	}
24390	ret := &ConversionsBatchUpdateResponse{
24391		ServerResponse: googleapi.ServerResponse{
24392			Header:         res.Header,
24393			HTTPStatusCode: res.StatusCode,
24394		},
24395	}
24396	target := &ret
24397	if err := gensupport.DecodeResponse(target, res); err != nil {
24398		return nil, err
24399	}
24400	return ret, nil
24401	// {
24402	//   "description": "Updates existing conversions.",
24403	//   "httpMethod": "POST",
24404	//   "id": "dfareporting.conversions.batchupdate",
24405	//   "parameterOrder": [
24406	//     "profileId"
24407	//   ],
24408	//   "parameters": {
24409	//     "profileId": {
24410	//       "description": "User profile ID associated with this request.",
24411	//       "format": "int64",
24412	//       "location": "path",
24413	//       "required": true,
24414	//       "type": "string"
24415	//     }
24416	//   },
24417	//   "path": "userprofiles/{profileId}/conversions/batchupdate",
24418	//   "request": {
24419	//     "$ref": "ConversionsBatchUpdateRequest"
24420	//   },
24421	//   "response": {
24422	//     "$ref": "ConversionsBatchUpdateResponse"
24423	//   },
24424	//   "scopes": [
24425	//     "https://www.googleapis.com/auth/ddmconversions"
24426	//   ]
24427	// }
24428
24429}
24430
24431// method id "dfareporting.countries.get":
24432
24433type CountriesGetCall struct {
24434	s            *Service
24435	profileId    int64
24436	dartId       int64
24437	urlParams_   gensupport.URLParams
24438	ifNoneMatch_ string
24439	ctx_         context.Context
24440	header_      http.Header
24441}
24442
24443// Get: Gets one country by ID.
24444func (r *CountriesService) Get(profileId int64, dartId int64) *CountriesGetCall {
24445	c := &CountriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24446	c.profileId = profileId
24447	c.dartId = dartId
24448	return c
24449}
24450
24451// Fields allows partial responses to be retrieved. See
24452// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24453// for more information.
24454func (c *CountriesGetCall) Fields(s ...googleapi.Field) *CountriesGetCall {
24455	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24456	return c
24457}
24458
24459// IfNoneMatch sets the optional parameter which makes the operation
24460// fail if the object's ETag matches the given value. This is useful for
24461// getting updates only after the object has changed since the last
24462// request. Use googleapi.IsNotModified to check whether the response
24463// error from Do is the result of In-None-Match.
24464func (c *CountriesGetCall) IfNoneMatch(entityTag string) *CountriesGetCall {
24465	c.ifNoneMatch_ = entityTag
24466	return c
24467}
24468
24469// Context sets the context to be used in this call's Do method. Any
24470// pending HTTP request will be aborted if the provided context is
24471// canceled.
24472func (c *CountriesGetCall) Context(ctx context.Context) *CountriesGetCall {
24473	c.ctx_ = ctx
24474	return c
24475}
24476
24477// Header returns an http.Header that can be modified by the caller to
24478// add HTTP headers to the request.
24479func (c *CountriesGetCall) Header() http.Header {
24480	if c.header_ == nil {
24481		c.header_ = make(http.Header)
24482	}
24483	return c.header_
24484}
24485
24486func (c *CountriesGetCall) doRequest(alt string) (*http.Response, error) {
24487	reqHeaders := make(http.Header)
24488	for k, v := range c.header_ {
24489		reqHeaders[k] = v
24490	}
24491	reqHeaders.Set("User-Agent", c.s.userAgent())
24492	if c.ifNoneMatch_ != "" {
24493		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24494	}
24495	var body io.Reader = nil
24496	c.urlParams_.Set("alt", alt)
24497	c.urlParams_.Set("prettyPrint", "false")
24498	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/countries/{dartId}")
24499	urls += "?" + c.urlParams_.Encode()
24500	req, err := http.NewRequest("GET", urls, body)
24501	if err != nil {
24502		return nil, err
24503	}
24504	req.Header = reqHeaders
24505	googleapi.Expand(req.URL, map[string]string{
24506		"profileId": strconv.FormatInt(c.profileId, 10),
24507		"dartId":    strconv.FormatInt(c.dartId, 10),
24508	})
24509	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24510}
24511
24512// Do executes the "dfareporting.countries.get" call.
24513// Exactly one of *Country or error will be non-nil. Any non-2xx status
24514// code is an error. Response headers are in either
24515// *Country.ServerResponse.Header or (if a response was returned at all)
24516// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
24517// check whether the returned error was because http.StatusNotModified
24518// was returned.
24519func (c *CountriesGetCall) Do(opts ...googleapi.CallOption) (*Country, error) {
24520	gensupport.SetOptions(c.urlParams_, opts...)
24521	res, err := c.doRequest("json")
24522	if res != nil && res.StatusCode == http.StatusNotModified {
24523		if res.Body != nil {
24524			res.Body.Close()
24525		}
24526		return nil, &googleapi.Error{
24527			Code:   res.StatusCode,
24528			Header: res.Header,
24529		}
24530	}
24531	if err != nil {
24532		return nil, err
24533	}
24534	defer googleapi.CloseBody(res)
24535	if err := googleapi.CheckResponse(res); err != nil {
24536		return nil, err
24537	}
24538	ret := &Country{
24539		ServerResponse: googleapi.ServerResponse{
24540			Header:         res.Header,
24541			HTTPStatusCode: res.StatusCode,
24542		},
24543	}
24544	target := &ret
24545	if err := gensupport.DecodeResponse(target, res); err != nil {
24546		return nil, err
24547	}
24548	return ret, nil
24549	// {
24550	//   "description": "Gets one country by ID.",
24551	//   "httpMethod": "GET",
24552	//   "id": "dfareporting.countries.get",
24553	//   "parameterOrder": [
24554	//     "profileId",
24555	//     "dartId"
24556	//   ],
24557	//   "parameters": {
24558	//     "dartId": {
24559	//       "description": "Country DART ID.",
24560	//       "format": "int64",
24561	//       "location": "path",
24562	//       "required": true,
24563	//       "type": "string"
24564	//     },
24565	//     "profileId": {
24566	//       "description": "User profile ID associated with this request.",
24567	//       "format": "int64",
24568	//       "location": "path",
24569	//       "required": true,
24570	//       "type": "string"
24571	//     }
24572	//   },
24573	//   "path": "userprofiles/{profileId}/countries/{dartId}",
24574	//   "response": {
24575	//     "$ref": "Country"
24576	//   },
24577	//   "scopes": [
24578	//     "https://www.googleapis.com/auth/dfatrafficking"
24579	//   ]
24580	// }
24581
24582}
24583
24584// method id "dfareporting.countries.list":
24585
24586type CountriesListCall struct {
24587	s            *Service
24588	profileId    int64
24589	urlParams_   gensupport.URLParams
24590	ifNoneMatch_ string
24591	ctx_         context.Context
24592	header_      http.Header
24593}
24594
24595// List: Retrieves a list of countries.
24596func (r *CountriesService) List(profileId int64) *CountriesListCall {
24597	c := &CountriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24598	c.profileId = profileId
24599	return c
24600}
24601
24602// Fields allows partial responses to be retrieved. See
24603// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24604// for more information.
24605func (c *CountriesListCall) Fields(s ...googleapi.Field) *CountriesListCall {
24606	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24607	return c
24608}
24609
24610// IfNoneMatch sets the optional parameter which makes the operation
24611// fail if the object's ETag matches the given value. This is useful for
24612// getting updates only after the object has changed since the last
24613// request. Use googleapi.IsNotModified to check whether the response
24614// error from Do is the result of In-None-Match.
24615func (c *CountriesListCall) IfNoneMatch(entityTag string) *CountriesListCall {
24616	c.ifNoneMatch_ = entityTag
24617	return c
24618}
24619
24620// Context sets the context to be used in this call's Do method. Any
24621// pending HTTP request will be aborted if the provided context is
24622// canceled.
24623func (c *CountriesListCall) Context(ctx context.Context) *CountriesListCall {
24624	c.ctx_ = ctx
24625	return c
24626}
24627
24628// Header returns an http.Header that can be modified by the caller to
24629// add HTTP headers to the request.
24630func (c *CountriesListCall) Header() http.Header {
24631	if c.header_ == nil {
24632		c.header_ = make(http.Header)
24633	}
24634	return c.header_
24635}
24636
24637func (c *CountriesListCall) doRequest(alt string) (*http.Response, error) {
24638	reqHeaders := make(http.Header)
24639	for k, v := range c.header_ {
24640		reqHeaders[k] = v
24641	}
24642	reqHeaders.Set("User-Agent", c.s.userAgent())
24643	if c.ifNoneMatch_ != "" {
24644		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24645	}
24646	var body io.Reader = nil
24647	c.urlParams_.Set("alt", alt)
24648	c.urlParams_.Set("prettyPrint", "false")
24649	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/countries")
24650	urls += "?" + c.urlParams_.Encode()
24651	req, err := http.NewRequest("GET", urls, body)
24652	if err != nil {
24653		return nil, err
24654	}
24655	req.Header = reqHeaders
24656	googleapi.Expand(req.URL, map[string]string{
24657		"profileId": strconv.FormatInt(c.profileId, 10),
24658	})
24659	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24660}
24661
24662// Do executes the "dfareporting.countries.list" call.
24663// Exactly one of *CountriesListResponse or error will be non-nil. Any
24664// non-2xx status code is an error. Response headers are in either
24665// *CountriesListResponse.ServerResponse.Header or (if a response was
24666// returned at all) in error.(*googleapi.Error).Header. Use
24667// googleapi.IsNotModified to check whether the returned error was
24668// because http.StatusNotModified was returned.
24669func (c *CountriesListCall) Do(opts ...googleapi.CallOption) (*CountriesListResponse, error) {
24670	gensupport.SetOptions(c.urlParams_, opts...)
24671	res, err := c.doRequest("json")
24672	if res != nil && res.StatusCode == http.StatusNotModified {
24673		if res.Body != nil {
24674			res.Body.Close()
24675		}
24676		return nil, &googleapi.Error{
24677			Code:   res.StatusCode,
24678			Header: res.Header,
24679		}
24680	}
24681	if err != nil {
24682		return nil, err
24683	}
24684	defer googleapi.CloseBody(res)
24685	if err := googleapi.CheckResponse(res); err != nil {
24686		return nil, err
24687	}
24688	ret := &CountriesListResponse{
24689		ServerResponse: googleapi.ServerResponse{
24690			Header:         res.Header,
24691			HTTPStatusCode: res.StatusCode,
24692		},
24693	}
24694	target := &ret
24695	if err := gensupport.DecodeResponse(target, res); err != nil {
24696		return nil, err
24697	}
24698	return ret, nil
24699	// {
24700	//   "description": "Retrieves a list of countries.",
24701	//   "httpMethod": "GET",
24702	//   "id": "dfareporting.countries.list",
24703	//   "parameterOrder": [
24704	//     "profileId"
24705	//   ],
24706	//   "parameters": {
24707	//     "profileId": {
24708	//       "description": "User profile ID associated with this request.",
24709	//       "format": "int64",
24710	//       "location": "path",
24711	//       "required": true,
24712	//       "type": "string"
24713	//     }
24714	//   },
24715	//   "path": "userprofiles/{profileId}/countries",
24716	//   "response": {
24717	//     "$ref": "CountriesListResponse"
24718	//   },
24719	//   "scopes": [
24720	//     "https://www.googleapis.com/auth/dfatrafficking"
24721	//   ]
24722	// }
24723
24724}
24725
24726// method id "dfareporting.creativeAssets.insert":
24727
24728type CreativeAssetsInsertCall struct {
24729	s                     *Service
24730	profileId             int64
24731	advertiserId          int64
24732	creativeassetmetadata *CreativeAssetMetadata
24733	urlParams_            gensupport.URLParams
24734	mediaInfo_            *gensupport.MediaInfo
24735	ctx_                  context.Context
24736	header_               http.Header
24737}
24738
24739// Insert: Inserts a new creative asset.
24740func (r *CreativeAssetsService) Insert(profileId int64, advertiserId int64, creativeassetmetadata *CreativeAssetMetadata) *CreativeAssetsInsertCall {
24741	c := &CreativeAssetsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24742	c.profileId = profileId
24743	c.advertiserId = advertiserId
24744	c.creativeassetmetadata = creativeassetmetadata
24745	return c
24746}
24747
24748// Media specifies the media to upload in one or more chunks. The chunk
24749// size may be controlled by supplying a MediaOption generated by
24750// googleapi.ChunkSize. The chunk size defaults to
24751// googleapi.DefaultUploadChunkSize.The Content-Type header used in the
24752// upload request will be determined by sniffing the contents of r,
24753// unless a MediaOption generated by googleapi.ContentType is
24754// supplied.
24755// At most one of Media and ResumableMedia may be set.
24756func (c *CreativeAssetsInsertCall) Media(r io.Reader, options ...googleapi.MediaOption) *CreativeAssetsInsertCall {
24757	c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
24758	return c
24759}
24760
24761// ResumableMedia specifies the media to upload in chunks and can be
24762// canceled with ctx.
24763//
24764// Deprecated: use Media instead.
24765//
24766// At most one of Media and ResumableMedia may be set. mediaType
24767// identifies the MIME media type of the upload, such as "image/png". If
24768// mediaType is "", it will be auto-detected. The provided ctx will
24769// supersede any context previously provided to the Context method.
24770func (c *CreativeAssetsInsertCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *CreativeAssetsInsertCall {
24771	c.ctx_ = ctx
24772	c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
24773	return c
24774}
24775
24776// ProgressUpdater provides a callback function that will be called
24777// after every chunk. It should be a low-latency function in order to
24778// not slow down the upload operation. This should only be called when
24779// using ResumableMedia (as opposed to Media).
24780func (c *CreativeAssetsInsertCall) ProgressUpdater(pu googleapi.ProgressUpdater) *CreativeAssetsInsertCall {
24781	c.mediaInfo_.SetProgressUpdater(pu)
24782	return c
24783}
24784
24785// Fields allows partial responses to be retrieved. See
24786// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24787// for more information.
24788func (c *CreativeAssetsInsertCall) Fields(s ...googleapi.Field) *CreativeAssetsInsertCall {
24789	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24790	return c
24791}
24792
24793// Context sets the context to be used in this call's Do method. Any
24794// pending HTTP request will be aborted if the provided context is
24795// canceled.
24796// This context will supersede any context previously provided to the
24797// ResumableMedia method.
24798func (c *CreativeAssetsInsertCall) Context(ctx context.Context) *CreativeAssetsInsertCall {
24799	c.ctx_ = ctx
24800	return c
24801}
24802
24803// Header returns an http.Header that can be modified by the caller to
24804// add HTTP headers to the request.
24805func (c *CreativeAssetsInsertCall) Header() http.Header {
24806	if c.header_ == nil {
24807		c.header_ = make(http.Header)
24808	}
24809	return c.header_
24810}
24811
24812func (c *CreativeAssetsInsertCall) doRequest(alt string) (*http.Response, error) {
24813	reqHeaders := make(http.Header)
24814	for k, v := range c.header_ {
24815		reqHeaders[k] = v
24816	}
24817	reqHeaders.Set("User-Agent", c.s.userAgent())
24818	var body io.Reader = nil
24819	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativeassetmetadata)
24820	if err != nil {
24821		return nil, err
24822	}
24823	reqHeaders.Set("Content-Type", "application/json")
24824	c.urlParams_.Set("alt", alt)
24825	c.urlParams_.Set("prettyPrint", "false")
24826	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets")
24827	if c.mediaInfo_ != nil {
24828		urls = strings.Replace(urls, "https://www.googleapis.com/", "https://www.googleapis.com/upload/", 1)
24829		c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
24830	}
24831	if body == nil {
24832		body = new(bytes.Buffer)
24833		reqHeaders.Set("Content-Type", "application/json")
24834	}
24835	body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
24836	defer cleanup()
24837	urls += "?" + c.urlParams_.Encode()
24838	req, err := http.NewRequest("POST", urls, body)
24839	if err != nil {
24840		return nil, err
24841	}
24842	req.Header = reqHeaders
24843	req.GetBody = getBody
24844	googleapi.Expand(req.URL, map[string]string{
24845		"profileId":    strconv.FormatInt(c.profileId, 10),
24846		"advertiserId": strconv.FormatInt(c.advertiserId, 10),
24847	})
24848	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24849}
24850
24851// Do executes the "dfareporting.creativeAssets.insert" call.
24852// Exactly one of *CreativeAssetMetadata or error will be non-nil. Any
24853// non-2xx status code is an error. Response headers are in either
24854// *CreativeAssetMetadata.ServerResponse.Header or (if a response was
24855// returned at all) in error.(*googleapi.Error).Header. Use
24856// googleapi.IsNotModified to check whether the returned error was
24857// because http.StatusNotModified was returned.
24858func (c *CreativeAssetsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeAssetMetadata, error) {
24859	gensupport.SetOptions(c.urlParams_, opts...)
24860	res, err := c.doRequest("json")
24861	if res != nil && res.StatusCode == http.StatusNotModified {
24862		if res.Body != nil {
24863			res.Body.Close()
24864		}
24865		return nil, &googleapi.Error{
24866			Code:   res.StatusCode,
24867			Header: res.Header,
24868		}
24869	}
24870	if err != nil {
24871		return nil, err
24872	}
24873	defer googleapi.CloseBody(res)
24874	if err := googleapi.CheckResponse(res); err != nil {
24875		return nil, err
24876	}
24877	rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
24878	if rx != nil {
24879		rx.Client = c.s.client
24880		rx.UserAgent = c.s.userAgent()
24881		ctx := c.ctx_
24882		if ctx == nil {
24883			ctx = context.TODO()
24884		}
24885		res, err = rx.Upload(ctx)
24886		if err != nil {
24887			return nil, err
24888		}
24889		defer res.Body.Close()
24890		if err := googleapi.CheckResponse(res); err != nil {
24891			return nil, err
24892		}
24893	}
24894	ret := &CreativeAssetMetadata{
24895		ServerResponse: googleapi.ServerResponse{
24896			Header:         res.Header,
24897			HTTPStatusCode: res.StatusCode,
24898		},
24899	}
24900	target := &ret
24901	if err := gensupport.DecodeResponse(target, res); err != nil {
24902		return nil, err
24903	}
24904	return ret, nil
24905	// {
24906	//   "description": "Inserts a new creative asset.",
24907	//   "httpMethod": "POST",
24908	//   "id": "dfareporting.creativeAssets.insert",
24909	//   "mediaUpload": {
24910	//     "accept": [
24911	//       "*/*"
24912	//     ],
24913	//     "maxSize": "1024MB",
24914	//     "protocols": {
24915	//       "resumable": {
24916	//         "multipart": true,
24917	//         "path": "/resumable/upload/dfareporting/v3.1/userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets"
24918	//       },
24919	//       "simple": {
24920	//         "multipart": true,
24921	//         "path": "/upload/dfareporting/v3.1/userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets"
24922	//       }
24923	//     }
24924	//   },
24925	//   "parameterOrder": [
24926	//     "profileId",
24927	//     "advertiserId"
24928	//   ],
24929	//   "parameters": {
24930	//     "advertiserId": {
24931	//       "description": "Advertiser ID of this creative. This is a required field.",
24932	//       "format": "int64",
24933	//       "location": "path",
24934	//       "required": true,
24935	//       "type": "string"
24936	//     },
24937	//     "profileId": {
24938	//       "description": "User profile ID associated with this request.",
24939	//       "format": "int64",
24940	//       "location": "path",
24941	//       "required": true,
24942	//       "type": "string"
24943	//     }
24944	//   },
24945	//   "path": "userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets",
24946	//   "request": {
24947	//     "$ref": "CreativeAssetMetadata"
24948	//   },
24949	//   "response": {
24950	//     "$ref": "CreativeAssetMetadata"
24951	//   },
24952	//   "scopes": [
24953	//     "https://www.googleapis.com/auth/dfatrafficking"
24954	//   ],
24955	//   "supportsMediaUpload": true
24956	// }
24957
24958}
24959
24960// method id "dfareporting.creativeFieldValues.delete":
24961
24962type CreativeFieldValuesDeleteCall struct {
24963	s               *Service
24964	profileId       int64
24965	creativeFieldId int64
24966	id              int64
24967	urlParams_      gensupport.URLParams
24968	ctx_            context.Context
24969	header_         http.Header
24970}
24971
24972// Delete: Deletes an existing creative field value.
24973func (r *CreativeFieldValuesService) Delete(profileId int64, creativeFieldId int64, id int64) *CreativeFieldValuesDeleteCall {
24974	c := &CreativeFieldValuesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24975	c.profileId = profileId
24976	c.creativeFieldId = creativeFieldId
24977	c.id = id
24978	return c
24979}
24980
24981// Fields allows partial responses to be retrieved. See
24982// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24983// for more information.
24984func (c *CreativeFieldValuesDeleteCall) Fields(s ...googleapi.Field) *CreativeFieldValuesDeleteCall {
24985	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24986	return c
24987}
24988
24989// Context sets the context to be used in this call's Do method. Any
24990// pending HTTP request will be aborted if the provided context is
24991// canceled.
24992func (c *CreativeFieldValuesDeleteCall) Context(ctx context.Context) *CreativeFieldValuesDeleteCall {
24993	c.ctx_ = ctx
24994	return c
24995}
24996
24997// Header returns an http.Header that can be modified by the caller to
24998// add HTTP headers to the request.
24999func (c *CreativeFieldValuesDeleteCall) Header() http.Header {
25000	if c.header_ == nil {
25001		c.header_ = make(http.Header)
25002	}
25003	return c.header_
25004}
25005
25006func (c *CreativeFieldValuesDeleteCall) doRequest(alt string) (*http.Response, error) {
25007	reqHeaders := make(http.Header)
25008	for k, v := range c.header_ {
25009		reqHeaders[k] = v
25010	}
25011	reqHeaders.Set("User-Agent", c.s.userAgent())
25012	var body io.Reader = nil
25013	c.urlParams_.Set("alt", alt)
25014	c.urlParams_.Set("prettyPrint", "false")
25015	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}")
25016	urls += "?" + c.urlParams_.Encode()
25017	req, err := http.NewRequest("DELETE", urls, body)
25018	if err != nil {
25019		return nil, err
25020	}
25021	req.Header = reqHeaders
25022	googleapi.Expand(req.URL, map[string]string{
25023		"profileId":       strconv.FormatInt(c.profileId, 10),
25024		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25025		"id":              strconv.FormatInt(c.id, 10),
25026	})
25027	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25028}
25029
25030// Do executes the "dfareporting.creativeFieldValues.delete" call.
25031func (c *CreativeFieldValuesDeleteCall) Do(opts ...googleapi.CallOption) error {
25032	gensupport.SetOptions(c.urlParams_, opts...)
25033	res, err := c.doRequest("json")
25034	if err != nil {
25035		return err
25036	}
25037	defer googleapi.CloseBody(res)
25038	if err := googleapi.CheckResponse(res); err != nil {
25039		return err
25040	}
25041	return nil
25042	// {
25043	//   "description": "Deletes an existing creative field value.",
25044	//   "httpMethod": "DELETE",
25045	//   "id": "dfareporting.creativeFieldValues.delete",
25046	//   "parameterOrder": [
25047	//     "profileId",
25048	//     "creativeFieldId",
25049	//     "id"
25050	//   ],
25051	//   "parameters": {
25052	//     "creativeFieldId": {
25053	//       "description": "Creative field ID for this creative field value.",
25054	//       "format": "int64",
25055	//       "location": "path",
25056	//       "required": true,
25057	//       "type": "string"
25058	//     },
25059	//     "id": {
25060	//       "description": "Creative Field Value ID",
25061	//       "format": "int64",
25062	//       "location": "path",
25063	//       "required": true,
25064	//       "type": "string"
25065	//     },
25066	//     "profileId": {
25067	//       "description": "User profile ID associated with this request.",
25068	//       "format": "int64",
25069	//       "location": "path",
25070	//       "required": true,
25071	//       "type": "string"
25072	//     }
25073	//   },
25074	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}",
25075	//   "scopes": [
25076	//     "https://www.googleapis.com/auth/dfatrafficking"
25077	//   ]
25078	// }
25079
25080}
25081
25082// method id "dfareporting.creativeFieldValues.get":
25083
25084type CreativeFieldValuesGetCall struct {
25085	s               *Service
25086	profileId       int64
25087	creativeFieldId int64
25088	id              int64
25089	urlParams_      gensupport.URLParams
25090	ifNoneMatch_    string
25091	ctx_            context.Context
25092	header_         http.Header
25093}
25094
25095// Get: Gets one creative field value by ID.
25096func (r *CreativeFieldValuesService) Get(profileId int64, creativeFieldId int64, id int64) *CreativeFieldValuesGetCall {
25097	c := &CreativeFieldValuesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25098	c.profileId = profileId
25099	c.creativeFieldId = creativeFieldId
25100	c.id = id
25101	return c
25102}
25103
25104// Fields allows partial responses to be retrieved. See
25105// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25106// for more information.
25107func (c *CreativeFieldValuesGetCall) Fields(s ...googleapi.Field) *CreativeFieldValuesGetCall {
25108	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25109	return c
25110}
25111
25112// IfNoneMatch sets the optional parameter which makes the operation
25113// fail if the object's ETag matches the given value. This is useful for
25114// getting updates only after the object has changed since the last
25115// request. Use googleapi.IsNotModified to check whether the response
25116// error from Do is the result of In-None-Match.
25117func (c *CreativeFieldValuesGetCall) IfNoneMatch(entityTag string) *CreativeFieldValuesGetCall {
25118	c.ifNoneMatch_ = entityTag
25119	return c
25120}
25121
25122// Context sets the context to be used in this call's Do method. Any
25123// pending HTTP request will be aborted if the provided context is
25124// canceled.
25125func (c *CreativeFieldValuesGetCall) Context(ctx context.Context) *CreativeFieldValuesGetCall {
25126	c.ctx_ = ctx
25127	return c
25128}
25129
25130// Header returns an http.Header that can be modified by the caller to
25131// add HTTP headers to the request.
25132func (c *CreativeFieldValuesGetCall) Header() http.Header {
25133	if c.header_ == nil {
25134		c.header_ = make(http.Header)
25135	}
25136	return c.header_
25137}
25138
25139func (c *CreativeFieldValuesGetCall) doRequest(alt string) (*http.Response, error) {
25140	reqHeaders := make(http.Header)
25141	for k, v := range c.header_ {
25142		reqHeaders[k] = v
25143	}
25144	reqHeaders.Set("User-Agent", c.s.userAgent())
25145	if c.ifNoneMatch_ != "" {
25146		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25147	}
25148	var body io.Reader = nil
25149	c.urlParams_.Set("alt", alt)
25150	c.urlParams_.Set("prettyPrint", "false")
25151	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}")
25152	urls += "?" + c.urlParams_.Encode()
25153	req, err := http.NewRequest("GET", urls, body)
25154	if err != nil {
25155		return nil, err
25156	}
25157	req.Header = reqHeaders
25158	googleapi.Expand(req.URL, map[string]string{
25159		"profileId":       strconv.FormatInt(c.profileId, 10),
25160		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25161		"id":              strconv.FormatInt(c.id, 10),
25162	})
25163	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25164}
25165
25166// Do executes the "dfareporting.creativeFieldValues.get" call.
25167// Exactly one of *CreativeFieldValue or error will be non-nil. Any
25168// non-2xx status code is an error. Response headers are in either
25169// *CreativeFieldValue.ServerResponse.Header or (if a response was
25170// returned at all) in error.(*googleapi.Error).Header. Use
25171// googleapi.IsNotModified to check whether the returned error was
25172// because http.StatusNotModified was returned.
25173func (c *CreativeFieldValuesGetCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25174	gensupport.SetOptions(c.urlParams_, opts...)
25175	res, err := c.doRequest("json")
25176	if res != nil && res.StatusCode == http.StatusNotModified {
25177		if res.Body != nil {
25178			res.Body.Close()
25179		}
25180		return nil, &googleapi.Error{
25181			Code:   res.StatusCode,
25182			Header: res.Header,
25183		}
25184	}
25185	if err != nil {
25186		return nil, err
25187	}
25188	defer googleapi.CloseBody(res)
25189	if err := googleapi.CheckResponse(res); err != nil {
25190		return nil, err
25191	}
25192	ret := &CreativeFieldValue{
25193		ServerResponse: googleapi.ServerResponse{
25194			Header:         res.Header,
25195			HTTPStatusCode: res.StatusCode,
25196		},
25197	}
25198	target := &ret
25199	if err := gensupport.DecodeResponse(target, res); err != nil {
25200		return nil, err
25201	}
25202	return ret, nil
25203	// {
25204	//   "description": "Gets one creative field value by ID.",
25205	//   "httpMethod": "GET",
25206	//   "id": "dfareporting.creativeFieldValues.get",
25207	//   "parameterOrder": [
25208	//     "profileId",
25209	//     "creativeFieldId",
25210	//     "id"
25211	//   ],
25212	//   "parameters": {
25213	//     "creativeFieldId": {
25214	//       "description": "Creative field ID for this creative field value.",
25215	//       "format": "int64",
25216	//       "location": "path",
25217	//       "required": true,
25218	//       "type": "string"
25219	//     },
25220	//     "id": {
25221	//       "description": "Creative Field Value ID",
25222	//       "format": "int64",
25223	//       "location": "path",
25224	//       "required": true,
25225	//       "type": "string"
25226	//     },
25227	//     "profileId": {
25228	//       "description": "User profile ID associated with this request.",
25229	//       "format": "int64",
25230	//       "location": "path",
25231	//       "required": true,
25232	//       "type": "string"
25233	//     }
25234	//   },
25235	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}",
25236	//   "response": {
25237	//     "$ref": "CreativeFieldValue"
25238	//   },
25239	//   "scopes": [
25240	//     "https://www.googleapis.com/auth/dfatrafficking"
25241	//   ]
25242	// }
25243
25244}
25245
25246// method id "dfareporting.creativeFieldValues.insert":
25247
25248type CreativeFieldValuesInsertCall struct {
25249	s                  *Service
25250	profileId          int64
25251	creativeFieldId    int64
25252	creativefieldvalue *CreativeFieldValue
25253	urlParams_         gensupport.URLParams
25254	ctx_               context.Context
25255	header_            http.Header
25256}
25257
25258// Insert: Inserts a new creative field value.
25259func (r *CreativeFieldValuesService) Insert(profileId int64, creativeFieldId int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesInsertCall {
25260	c := &CreativeFieldValuesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25261	c.profileId = profileId
25262	c.creativeFieldId = creativeFieldId
25263	c.creativefieldvalue = creativefieldvalue
25264	return c
25265}
25266
25267// Fields allows partial responses to be retrieved. See
25268// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25269// for more information.
25270func (c *CreativeFieldValuesInsertCall) Fields(s ...googleapi.Field) *CreativeFieldValuesInsertCall {
25271	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25272	return c
25273}
25274
25275// Context sets the context to be used in this call's Do method. Any
25276// pending HTTP request will be aborted if the provided context is
25277// canceled.
25278func (c *CreativeFieldValuesInsertCall) Context(ctx context.Context) *CreativeFieldValuesInsertCall {
25279	c.ctx_ = ctx
25280	return c
25281}
25282
25283// Header returns an http.Header that can be modified by the caller to
25284// add HTTP headers to the request.
25285func (c *CreativeFieldValuesInsertCall) Header() http.Header {
25286	if c.header_ == nil {
25287		c.header_ = make(http.Header)
25288	}
25289	return c.header_
25290}
25291
25292func (c *CreativeFieldValuesInsertCall) doRequest(alt string) (*http.Response, error) {
25293	reqHeaders := make(http.Header)
25294	for k, v := range c.header_ {
25295		reqHeaders[k] = v
25296	}
25297	reqHeaders.Set("User-Agent", c.s.userAgent())
25298	var body io.Reader = nil
25299	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
25300	if err != nil {
25301		return nil, err
25302	}
25303	reqHeaders.Set("Content-Type", "application/json")
25304	c.urlParams_.Set("alt", alt)
25305	c.urlParams_.Set("prettyPrint", "false")
25306	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25307	urls += "?" + c.urlParams_.Encode()
25308	req, err := http.NewRequest("POST", urls, body)
25309	if err != nil {
25310		return nil, err
25311	}
25312	req.Header = reqHeaders
25313	googleapi.Expand(req.URL, map[string]string{
25314		"profileId":       strconv.FormatInt(c.profileId, 10),
25315		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25316	})
25317	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25318}
25319
25320// Do executes the "dfareporting.creativeFieldValues.insert" call.
25321// Exactly one of *CreativeFieldValue or error will be non-nil. Any
25322// non-2xx status code is an error. Response headers are in either
25323// *CreativeFieldValue.ServerResponse.Header or (if a response was
25324// returned at all) in error.(*googleapi.Error).Header. Use
25325// googleapi.IsNotModified to check whether the returned error was
25326// because http.StatusNotModified was returned.
25327func (c *CreativeFieldValuesInsertCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25328	gensupport.SetOptions(c.urlParams_, opts...)
25329	res, err := c.doRequest("json")
25330	if res != nil && res.StatusCode == http.StatusNotModified {
25331		if res.Body != nil {
25332			res.Body.Close()
25333		}
25334		return nil, &googleapi.Error{
25335			Code:   res.StatusCode,
25336			Header: res.Header,
25337		}
25338	}
25339	if err != nil {
25340		return nil, err
25341	}
25342	defer googleapi.CloseBody(res)
25343	if err := googleapi.CheckResponse(res); err != nil {
25344		return nil, err
25345	}
25346	ret := &CreativeFieldValue{
25347		ServerResponse: googleapi.ServerResponse{
25348			Header:         res.Header,
25349			HTTPStatusCode: res.StatusCode,
25350		},
25351	}
25352	target := &ret
25353	if err := gensupport.DecodeResponse(target, res); err != nil {
25354		return nil, err
25355	}
25356	return ret, nil
25357	// {
25358	//   "description": "Inserts a new creative field value.",
25359	//   "httpMethod": "POST",
25360	//   "id": "dfareporting.creativeFieldValues.insert",
25361	//   "parameterOrder": [
25362	//     "profileId",
25363	//     "creativeFieldId"
25364	//   ],
25365	//   "parameters": {
25366	//     "creativeFieldId": {
25367	//       "description": "Creative field ID for this creative field value.",
25368	//       "format": "int64",
25369	//       "location": "path",
25370	//       "required": true,
25371	//       "type": "string"
25372	//     },
25373	//     "profileId": {
25374	//       "description": "User profile ID associated with this request.",
25375	//       "format": "int64",
25376	//       "location": "path",
25377	//       "required": true,
25378	//       "type": "string"
25379	//     }
25380	//   },
25381	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
25382	//   "request": {
25383	//     "$ref": "CreativeFieldValue"
25384	//   },
25385	//   "response": {
25386	//     "$ref": "CreativeFieldValue"
25387	//   },
25388	//   "scopes": [
25389	//     "https://www.googleapis.com/auth/dfatrafficking"
25390	//   ]
25391	// }
25392
25393}
25394
25395// method id "dfareporting.creativeFieldValues.list":
25396
25397type CreativeFieldValuesListCall struct {
25398	s               *Service
25399	profileId       int64
25400	creativeFieldId int64
25401	urlParams_      gensupport.URLParams
25402	ifNoneMatch_    string
25403	ctx_            context.Context
25404	header_         http.Header
25405}
25406
25407// List: Retrieves a list of creative field values, possibly filtered.
25408// This method supports paging.
25409func (r *CreativeFieldValuesService) List(profileId int64, creativeFieldId int64) *CreativeFieldValuesListCall {
25410	c := &CreativeFieldValuesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25411	c.profileId = profileId
25412	c.creativeFieldId = creativeFieldId
25413	return c
25414}
25415
25416// Ids sets the optional parameter "ids": Select only creative field
25417// values with these IDs.
25418func (c *CreativeFieldValuesListCall) Ids(ids ...int64) *CreativeFieldValuesListCall {
25419	var ids_ []string
25420	for _, v := range ids {
25421		ids_ = append(ids_, fmt.Sprint(v))
25422	}
25423	c.urlParams_.SetMulti("ids", ids_)
25424	return c
25425}
25426
25427// MaxResults sets the optional parameter "maxResults": Maximum number
25428// of results to return.
25429func (c *CreativeFieldValuesListCall) MaxResults(maxResults int64) *CreativeFieldValuesListCall {
25430	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
25431	return c
25432}
25433
25434// PageToken sets the optional parameter "pageToken": Value of the
25435// nextPageToken from the previous result page.
25436func (c *CreativeFieldValuesListCall) PageToken(pageToken string) *CreativeFieldValuesListCall {
25437	c.urlParams_.Set("pageToken", pageToken)
25438	return c
25439}
25440
25441// SearchString sets the optional parameter "searchString": Allows
25442// searching for creative field values by their values. Wildcards (e.g.
25443// *) are not allowed.
25444func (c *CreativeFieldValuesListCall) SearchString(searchString string) *CreativeFieldValuesListCall {
25445	c.urlParams_.Set("searchString", searchString)
25446	return c
25447}
25448
25449// SortField sets the optional parameter "sortField": Field by which to
25450// sort the list.
25451//
25452// Possible values:
25453//   "ID" (default)
25454//   "VALUE"
25455func (c *CreativeFieldValuesListCall) SortField(sortField string) *CreativeFieldValuesListCall {
25456	c.urlParams_.Set("sortField", sortField)
25457	return c
25458}
25459
25460// SortOrder sets the optional parameter "sortOrder": Order of sorted
25461// results.
25462//
25463// Possible values:
25464//   "ASCENDING" (default)
25465//   "DESCENDING"
25466func (c *CreativeFieldValuesListCall) SortOrder(sortOrder string) *CreativeFieldValuesListCall {
25467	c.urlParams_.Set("sortOrder", sortOrder)
25468	return c
25469}
25470
25471// Fields allows partial responses to be retrieved. See
25472// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25473// for more information.
25474func (c *CreativeFieldValuesListCall) Fields(s ...googleapi.Field) *CreativeFieldValuesListCall {
25475	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25476	return c
25477}
25478
25479// IfNoneMatch sets the optional parameter which makes the operation
25480// fail if the object's ETag matches the given value. This is useful for
25481// getting updates only after the object has changed since the last
25482// request. Use googleapi.IsNotModified to check whether the response
25483// error from Do is the result of In-None-Match.
25484func (c *CreativeFieldValuesListCall) IfNoneMatch(entityTag string) *CreativeFieldValuesListCall {
25485	c.ifNoneMatch_ = entityTag
25486	return c
25487}
25488
25489// Context sets the context to be used in this call's Do method. Any
25490// pending HTTP request will be aborted if the provided context is
25491// canceled.
25492func (c *CreativeFieldValuesListCall) Context(ctx context.Context) *CreativeFieldValuesListCall {
25493	c.ctx_ = ctx
25494	return c
25495}
25496
25497// Header returns an http.Header that can be modified by the caller to
25498// add HTTP headers to the request.
25499func (c *CreativeFieldValuesListCall) Header() http.Header {
25500	if c.header_ == nil {
25501		c.header_ = make(http.Header)
25502	}
25503	return c.header_
25504}
25505
25506func (c *CreativeFieldValuesListCall) doRequest(alt string) (*http.Response, error) {
25507	reqHeaders := make(http.Header)
25508	for k, v := range c.header_ {
25509		reqHeaders[k] = v
25510	}
25511	reqHeaders.Set("User-Agent", c.s.userAgent())
25512	if c.ifNoneMatch_ != "" {
25513		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25514	}
25515	var body io.Reader = nil
25516	c.urlParams_.Set("alt", alt)
25517	c.urlParams_.Set("prettyPrint", "false")
25518	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25519	urls += "?" + c.urlParams_.Encode()
25520	req, err := http.NewRequest("GET", urls, body)
25521	if err != nil {
25522		return nil, err
25523	}
25524	req.Header = reqHeaders
25525	googleapi.Expand(req.URL, map[string]string{
25526		"profileId":       strconv.FormatInt(c.profileId, 10),
25527		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25528	})
25529	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25530}
25531
25532// Do executes the "dfareporting.creativeFieldValues.list" call.
25533// Exactly one of *CreativeFieldValuesListResponse or error will be
25534// non-nil. Any non-2xx status code is an error. Response headers are in
25535// either *CreativeFieldValuesListResponse.ServerResponse.Header or (if
25536// a response was returned at all) in error.(*googleapi.Error).Header.
25537// Use googleapi.IsNotModified to check whether the returned error was
25538// because http.StatusNotModified was returned.
25539func (c *CreativeFieldValuesListCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValuesListResponse, error) {
25540	gensupport.SetOptions(c.urlParams_, opts...)
25541	res, err := c.doRequest("json")
25542	if res != nil && res.StatusCode == http.StatusNotModified {
25543		if res.Body != nil {
25544			res.Body.Close()
25545		}
25546		return nil, &googleapi.Error{
25547			Code:   res.StatusCode,
25548			Header: res.Header,
25549		}
25550	}
25551	if err != nil {
25552		return nil, err
25553	}
25554	defer googleapi.CloseBody(res)
25555	if err := googleapi.CheckResponse(res); err != nil {
25556		return nil, err
25557	}
25558	ret := &CreativeFieldValuesListResponse{
25559		ServerResponse: googleapi.ServerResponse{
25560			Header:         res.Header,
25561			HTTPStatusCode: res.StatusCode,
25562		},
25563	}
25564	target := &ret
25565	if err := gensupport.DecodeResponse(target, res); err != nil {
25566		return nil, err
25567	}
25568	return ret, nil
25569	// {
25570	//   "description": "Retrieves a list of creative field values, possibly filtered. This method supports paging.",
25571	//   "httpMethod": "GET",
25572	//   "id": "dfareporting.creativeFieldValues.list",
25573	//   "parameterOrder": [
25574	//     "profileId",
25575	//     "creativeFieldId"
25576	//   ],
25577	//   "parameters": {
25578	//     "creativeFieldId": {
25579	//       "description": "Creative field ID for this creative field value.",
25580	//       "format": "int64",
25581	//       "location": "path",
25582	//       "required": true,
25583	//       "type": "string"
25584	//     },
25585	//     "ids": {
25586	//       "description": "Select only creative field values with these IDs.",
25587	//       "format": "int64",
25588	//       "location": "query",
25589	//       "repeated": true,
25590	//       "type": "string"
25591	//     },
25592	//     "maxResults": {
25593	//       "default": "1000",
25594	//       "description": "Maximum number of results to return.",
25595	//       "format": "int32",
25596	//       "location": "query",
25597	//       "maximum": "1000",
25598	//       "minimum": "0",
25599	//       "type": "integer"
25600	//     },
25601	//     "pageToken": {
25602	//       "description": "Value of the nextPageToken from the previous result page.",
25603	//       "location": "query",
25604	//       "type": "string"
25605	//     },
25606	//     "profileId": {
25607	//       "description": "User profile ID associated with this request.",
25608	//       "format": "int64",
25609	//       "location": "path",
25610	//       "required": true,
25611	//       "type": "string"
25612	//     },
25613	//     "searchString": {
25614	//       "description": "Allows searching for creative field values by their values. Wildcards (e.g. *) are not allowed.",
25615	//       "location": "query",
25616	//       "type": "string"
25617	//     },
25618	//     "sortField": {
25619	//       "default": "ID",
25620	//       "description": "Field by which to sort the list.",
25621	//       "enum": [
25622	//         "ID",
25623	//         "VALUE"
25624	//       ],
25625	//       "enumDescriptions": [
25626	//         "",
25627	//         ""
25628	//       ],
25629	//       "location": "query",
25630	//       "type": "string"
25631	//     },
25632	//     "sortOrder": {
25633	//       "default": "ASCENDING",
25634	//       "description": "Order of sorted results.",
25635	//       "enum": [
25636	//         "ASCENDING",
25637	//         "DESCENDING"
25638	//       ],
25639	//       "enumDescriptions": [
25640	//         "",
25641	//         ""
25642	//       ],
25643	//       "location": "query",
25644	//       "type": "string"
25645	//     }
25646	//   },
25647	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
25648	//   "response": {
25649	//     "$ref": "CreativeFieldValuesListResponse"
25650	//   },
25651	//   "scopes": [
25652	//     "https://www.googleapis.com/auth/dfatrafficking"
25653	//   ]
25654	// }
25655
25656}
25657
25658// Pages invokes f for each page of results.
25659// A non-nil error returned from f will halt the iteration.
25660// The provided context supersedes any context provided to the Context method.
25661func (c *CreativeFieldValuesListCall) Pages(ctx context.Context, f func(*CreativeFieldValuesListResponse) error) error {
25662	c.ctx_ = ctx
25663	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
25664	for {
25665		x, err := c.Do()
25666		if err != nil {
25667			return err
25668		}
25669		if err := f(x); err != nil {
25670			return err
25671		}
25672		if x.NextPageToken == "" {
25673			return nil
25674		}
25675		c.PageToken(x.NextPageToken)
25676	}
25677}
25678
25679// method id "dfareporting.creativeFieldValues.patch":
25680
25681type CreativeFieldValuesPatchCall struct {
25682	s                  *Service
25683	profileId          int64
25684	creativeFieldId    int64
25685	creativefieldvalue *CreativeFieldValue
25686	urlParams_         gensupport.URLParams
25687	ctx_               context.Context
25688	header_            http.Header
25689}
25690
25691// Patch: Updates an existing creative field value. This method supports
25692// patch semantics.
25693func (r *CreativeFieldValuesService) Patch(profileId int64, creativeFieldId int64, id int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesPatchCall {
25694	c := &CreativeFieldValuesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25695	c.profileId = profileId
25696	c.creativeFieldId = creativeFieldId
25697	c.urlParams_.Set("id", fmt.Sprint(id))
25698	c.creativefieldvalue = creativefieldvalue
25699	return c
25700}
25701
25702// Fields allows partial responses to be retrieved. See
25703// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25704// for more information.
25705func (c *CreativeFieldValuesPatchCall) Fields(s ...googleapi.Field) *CreativeFieldValuesPatchCall {
25706	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25707	return c
25708}
25709
25710// Context sets the context to be used in this call's Do method. Any
25711// pending HTTP request will be aborted if the provided context is
25712// canceled.
25713func (c *CreativeFieldValuesPatchCall) Context(ctx context.Context) *CreativeFieldValuesPatchCall {
25714	c.ctx_ = ctx
25715	return c
25716}
25717
25718// Header returns an http.Header that can be modified by the caller to
25719// add HTTP headers to the request.
25720func (c *CreativeFieldValuesPatchCall) Header() http.Header {
25721	if c.header_ == nil {
25722		c.header_ = make(http.Header)
25723	}
25724	return c.header_
25725}
25726
25727func (c *CreativeFieldValuesPatchCall) doRequest(alt string) (*http.Response, error) {
25728	reqHeaders := make(http.Header)
25729	for k, v := range c.header_ {
25730		reqHeaders[k] = v
25731	}
25732	reqHeaders.Set("User-Agent", c.s.userAgent())
25733	var body io.Reader = nil
25734	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
25735	if err != nil {
25736		return nil, err
25737	}
25738	reqHeaders.Set("Content-Type", "application/json")
25739	c.urlParams_.Set("alt", alt)
25740	c.urlParams_.Set("prettyPrint", "false")
25741	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25742	urls += "?" + c.urlParams_.Encode()
25743	req, err := http.NewRequest("PATCH", urls, body)
25744	if err != nil {
25745		return nil, err
25746	}
25747	req.Header = reqHeaders
25748	googleapi.Expand(req.URL, map[string]string{
25749		"profileId":       strconv.FormatInt(c.profileId, 10),
25750		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25751	})
25752	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25753}
25754
25755// Do executes the "dfareporting.creativeFieldValues.patch" call.
25756// Exactly one of *CreativeFieldValue or error will be non-nil. Any
25757// non-2xx status code is an error. Response headers are in either
25758// *CreativeFieldValue.ServerResponse.Header or (if a response was
25759// returned at all) in error.(*googleapi.Error).Header. Use
25760// googleapi.IsNotModified to check whether the returned error was
25761// because http.StatusNotModified was returned.
25762func (c *CreativeFieldValuesPatchCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25763	gensupport.SetOptions(c.urlParams_, opts...)
25764	res, err := c.doRequest("json")
25765	if res != nil && res.StatusCode == http.StatusNotModified {
25766		if res.Body != nil {
25767			res.Body.Close()
25768		}
25769		return nil, &googleapi.Error{
25770			Code:   res.StatusCode,
25771			Header: res.Header,
25772		}
25773	}
25774	if err != nil {
25775		return nil, err
25776	}
25777	defer googleapi.CloseBody(res)
25778	if err := googleapi.CheckResponse(res); err != nil {
25779		return nil, err
25780	}
25781	ret := &CreativeFieldValue{
25782		ServerResponse: googleapi.ServerResponse{
25783			Header:         res.Header,
25784			HTTPStatusCode: res.StatusCode,
25785		},
25786	}
25787	target := &ret
25788	if err := gensupport.DecodeResponse(target, res); err != nil {
25789		return nil, err
25790	}
25791	return ret, nil
25792	// {
25793	//   "description": "Updates an existing creative field value. This method supports patch semantics.",
25794	//   "httpMethod": "PATCH",
25795	//   "id": "dfareporting.creativeFieldValues.patch",
25796	//   "parameterOrder": [
25797	//     "profileId",
25798	//     "creativeFieldId",
25799	//     "id"
25800	//   ],
25801	//   "parameters": {
25802	//     "creativeFieldId": {
25803	//       "description": "Creative field ID for this creative field value.",
25804	//       "format": "int64",
25805	//       "location": "path",
25806	//       "required": true,
25807	//       "type": "string"
25808	//     },
25809	//     "id": {
25810	//       "description": "Creative Field Value ID",
25811	//       "format": "int64",
25812	//       "location": "query",
25813	//       "required": true,
25814	//       "type": "string"
25815	//     },
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}/creativeFields/{creativeFieldId}/creativeFieldValues",
25825	//   "request": {
25826	//     "$ref": "CreativeFieldValue"
25827	//   },
25828	//   "response": {
25829	//     "$ref": "CreativeFieldValue"
25830	//   },
25831	//   "scopes": [
25832	//     "https://www.googleapis.com/auth/dfatrafficking"
25833	//   ]
25834	// }
25835
25836}
25837
25838// method id "dfareporting.creativeFieldValues.update":
25839
25840type CreativeFieldValuesUpdateCall struct {
25841	s                  *Service
25842	profileId          int64
25843	creativeFieldId    int64
25844	creativefieldvalue *CreativeFieldValue
25845	urlParams_         gensupport.URLParams
25846	ctx_               context.Context
25847	header_            http.Header
25848}
25849
25850// Update: Updates an existing creative field value.
25851func (r *CreativeFieldValuesService) Update(profileId int64, creativeFieldId int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesUpdateCall {
25852	c := &CreativeFieldValuesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25853	c.profileId = profileId
25854	c.creativeFieldId = creativeFieldId
25855	c.creativefieldvalue = creativefieldvalue
25856	return c
25857}
25858
25859// Fields allows partial responses to be retrieved. See
25860// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25861// for more information.
25862func (c *CreativeFieldValuesUpdateCall) Fields(s ...googleapi.Field) *CreativeFieldValuesUpdateCall {
25863	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25864	return c
25865}
25866
25867// Context sets the context to be used in this call's Do method. Any
25868// pending HTTP request will be aborted if the provided context is
25869// canceled.
25870func (c *CreativeFieldValuesUpdateCall) Context(ctx context.Context) *CreativeFieldValuesUpdateCall {
25871	c.ctx_ = ctx
25872	return c
25873}
25874
25875// Header returns an http.Header that can be modified by the caller to
25876// add HTTP headers to the request.
25877func (c *CreativeFieldValuesUpdateCall) Header() http.Header {
25878	if c.header_ == nil {
25879		c.header_ = make(http.Header)
25880	}
25881	return c.header_
25882}
25883
25884func (c *CreativeFieldValuesUpdateCall) doRequest(alt string) (*http.Response, error) {
25885	reqHeaders := make(http.Header)
25886	for k, v := range c.header_ {
25887		reqHeaders[k] = v
25888	}
25889	reqHeaders.Set("User-Agent", c.s.userAgent())
25890	var body io.Reader = nil
25891	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
25892	if err != nil {
25893		return nil, err
25894	}
25895	reqHeaders.Set("Content-Type", "application/json")
25896	c.urlParams_.Set("alt", alt)
25897	c.urlParams_.Set("prettyPrint", "false")
25898	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25899	urls += "?" + c.urlParams_.Encode()
25900	req, err := http.NewRequest("PUT", urls, body)
25901	if err != nil {
25902		return nil, err
25903	}
25904	req.Header = reqHeaders
25905	googleapi.Expand(req.URL, map[string]string{
25906		"profileId":       strconv.FormatInt(c.profileId, 10),
25907		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25908	})
25909	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25910}
25911
25912// Do executes the "dfareporting.creativeFieldValues.update" call.
25913// Exactly one of *CreativeFieldValue or error will be non-nil. Any
25914// non-2xx status code is an error. Response headers are in either
25915// *CreativeFieldValue.ServerResponse.Header or (if a response was
25916// returned at all) in error.(*googleapi.Error).Header. Use
25917// googleapi.IsNotModified to check whether the returned error was
25918// because http.StatusNotModified was returned.
25919func (c *CreativeFieldValuesUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25920	gensupport.SetOptions(c.urlParams_, opts...)
25921	res, err := c.doRequest("json")
25922	if res != nil && res.StatusCode == http.StatusNotModified {
25923		if res.Body != nil {
25924			res.Body.Close()
25925		}
25926		return nil, &googleapi.Error{
25927			Code:   res.StatusCode,
25928			Header: res.Header,
25929		}
25930	}
25931	if err != nil {
25932		return nil, err
25933	}
25934	defer googleapi.CloseBody(res)
25935	if err := googleapi.CheckResponse(res); err != nil {
25936		return nil, err
25937	}
25938	ret := &CreativeFieldValue{
25939		ServerResponse: googleapi.ServerResponse{
25940			Header:         res.Header,
25941			HTTPStatusCode: res.StatusCode,
25942		},
25943	}
25944	target := &ret
25945	if err := gensupport.DecodeResponse(target, res); err != nil {
25946		return nil, err
25947	}
25948	return ret, nil
25949	// {
25950	//   "description": "Updates an existing creative field value.",
25951	//   "httpMethod": "PUT",
25952	//   "id": "dfareporting.creativeFieldValues.update",
25953	//   "parameterOrder": [
25954	//     "profileId",
25955	//     "creativeFieldId"
25956	//   ],
25957	//   "parameters": {
25958	//     "creativeFieldId": {
25959	//       "description": "Creative field ID for this creative field value.",
25960	//       "format": "int64",
25961	//       "location": "path",
25962	//       "required": true,
25963	//       "type": "string"
25964	//     },
25965	//     "profileId": {
25966	//       "description": "User profile ID associated with this request.",
25967	//       "format": "int64",
25968	//       "location": "path",
25969	//       "required": true,
25970	//       "type": "string"
25971	//     }
25972	//   },
25973	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
25974	//   "request": {
25975	//     "$ref": "CreativeFieldValue"
25976	//   },
25977	//   "response": {
25978	//     "$ref": "CreativeFieldValue"
25979	//   },
25980	//   "scopes": [
25981	//     "https://www.googleapis.com/auth/dfatrafficking"
25982	//   ]
25983	// }
25984
25985}
25986
25987// method id "dfareporting.creativeFields.delete":
25988
25989type CreativeFieldsDeleteCall struct {
25990	s          *Service
25991	profileId  int64
25992	id         int64
25993	urlParams_ gensupport.URLParams
25994	ctx_       context.Context
25995	header_    http.Header
25996}
25997
25998// Delete: Deletes an existing creative field.
25999func (r *CreativeFieldsService) Delete(profileId int64, id int64) *CreativeFieldsDeleteCall {
26000	c := &CreativeFieldsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26001	c.profileId = profileId
26002	c.id = id
26003	return c
26004}
26005
26006// Fields allows partial responses to be retrieved. See
26007// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26008// for more information.
26009func (c *CreativeFieldsDeleteCall) Fields(s ...googleapi.Field) *CreativeFieldsDeleteCall {
26010	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26011	return c
26012}
26013
26014// Context sets the context to be used in this call's Do method. Any
26015// pending HTTP request will be aborted if the provided context is
26016// canceled.
26017func (c *CreativeFieldsDeleteCall) Context(ctx context.Context) *CreativeFieldsDeleteCall {
26018	c.ctx_ = ctx
26019	return c
26020}
26021
26022// Header returns an http.Header that can be modified by the caller to
26023// add HTTP headers to the request.
26024func (c *CreativeFieldsDeleteCall) Header() http.Header {
26025	if c.header_ == nil {
26026		c.header_ = make(http.Header)
26027	}
26028	return c.header_
26029}
26030
26031func (c *CreativeFieldsDeleteCall) doRequest(alt string) (*http.Response, error) {
26032	reqHeaders := make(http.Header)
26033	for k, v := range c.header_ {
26034		reqHeaders[k] = v
26035	}
26036	reqHeaders.Set("User-Agent", c.s.userAgent())
26037	var body io.Reader = nil
26038	c.urlParams_.Set("alt", alt)
26039	c.urlParams_.Set("prettyPrint", "false")
26040	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{id}")
26041	urls += "?" + c.urlParams_.Encode()
26042	req, err := http.NewRequest("DELETE", urls, body)
26043	if err != nil {
26044		return nil, err
26045	}
26046	req.Header = reqHeaders
26047	googleapi.Expand(req.URL, map[string]string{
26048		"profileId": strconv.FormatInt(c.profileId, 10),
26049		"id":        strconv.FormatInt(c.id, 10),
26050	})
26051	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26052}
26053
26054// Do executes the "dfareporting.creativeFields.delete" call.
26055func (c *CreativeFieldsDeleteCall) Do(opts ...googleapi.CallOption) error {
26056	gensupport.SetOptions(c.urlParams_, opts...)
26057	res, err := c.doRequest("json")
26058	if err != nil {
26059		return err
26060	}
26061	defer googleapi.CloseBody(res)
26062	if err := googleapi.CheckResponse(res); err != nil {
26063		return err
26064	}
26065	return nil
26066	// {
26067	//   "description": "Deletes an existing creative field.",
26068	//   "httpMethod": "DELETE",
26069	//   "id": "dfareporting.creativeFields.delete",
26070	//   "parameterOrder": [
26071	//     "profileId",
26072	//     "id"
26073	//   ],
26074	//   "parameters": {
26075	//     "id": {
26076	//       "description": "Creative Field ID",
26077	//       "format": "int64",
26078	//       "location": "path",
26079	//       "required": true,
26080	//       "type": "string"
26081	//     },
26082	//     "profileId": {
26083	//       "description": "User profile ID associated with this request.",
26084	//       "format": "int64",
26085	//       "location": "path",
26086	//       "required": true,
26087	//       "type": "string"
26088	//     }
26089	//   },
26090	//   "path": "userprofiles/{profileId}/creativeFields/{id}",
26091	//   "scopes": [
26092	//     "https://www.googleapis.com/auth/dfatrafficking"
26093	//   ]
26094	// }
26095
26096}
26097
26098// method id "dfareporting.creativeFields.get":
26099
26100type CreativeFieldsGetCall struct {
26101	s            *Service
26102	profileId    int64
26103	id           int64
26104	urlParams_   gensupport.URLParams
26105	ifNoneMatch_ string
26106	ctx_         context.Context
26107	header_      http.Header
26108}
26109
26110// Get: Gets one creative field by ID.
26111func (r *CreativeFieldsService) Get(profileId int64, id int64) *CreativeFieldsGetCall {
26112	c := &CreativeFieldsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26113	c.profileId = profileId
26114	c.id = id
26115	return c
26116}
26117
26118// Fields allows partial responses to be retrieved. See
26119// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26120// for more information.
26121func (c *CreativeFieldsGetCall) Fields(s ...googleapi.Field) *CreativeFieldsGetCall {
26122	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26123	return c
26124}
26125
26126// IfNoneMatch sets the optional parameter which makes the operation
26127// fail if the object's ETag matches the given value. This is useful for
26128// getting updates only after the object has changed since the last
26129// request. Use googleapi.IsNotModified to check whether the response
26130// error from Do is the result of In-None-Match.
26131func (c *CreativeFieldsGetCall) IfNoneMatch(entityTag string) *CreativeFieldsGetCall {
26132	c.ifNoneMatch_ = entityTag
26133	return c
26134}
26135
26136// Context sets the context to be used in this call's Do method. Any
26137// pending HTTP request will be aborted if the provided context is
26138// canceled.
26139func (c *CreativeFieldsGetCall) Context(ctx context.Context) *CreativeFieldsGetCall {
26140	c.ctx_ = ctx
26141	return c
26142}
26143
26144// Header returns an http.Header that can be modified by the caller to
26145// add HTTP headers to the request.
26146func (c *CreativeFieldsGetCall) Header() http.Header {
26147	if c.header_ == nil {
26148		c.header_ = make(http.Header)
26149	}
26150	return c.header_
26151}
26152
26153func (c *CreativeFieldsGetCall) doRequest(alt string) (*http.Response, error) {
26154	reqHeaders := make(http.Header)
26155	for k, v := range c.header_ {
26156		reqHeaders[k] = v
26157	}
26158	reqHeaders.Set("User-Agent", c.s.userAgent())
26159	if c.ifNoneMatch_ != "" {
26160		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26161	}
26162	var body io.Reader = nil
26163	c.urlParams_.Set("alt", alt)
26164	c.urlParams_.Set("prettyPrint", "false")
26165	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{id}")
26166	urls += "?" + c.urlParams_.Encode()
26167	req, err := http.NewRequest("GET", urls, body)
26168	if err != nil {
26169		return nil, err
26170	}
26171	req.Header = reqHeaders
26172	googleapi.Expand(req.URL, map[string]string{
26173		"profileId": strconv.FormatInt(c.profileId, 10),
26174		"id":        strconv.FormatInt(c.id, 10),
26175	})
26176	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26177}
26178
26179// Do executes the "dfareporting.creativeFields.get" call.
26180// Exactly one of *CreativeField or error will be non-nil. Any non-2xx
26181// status code is an error. Response headers are in either
26182// *CreativeField.ServerResponse.Header or (if a response was returned
26183// at all) in error.(*googleapi.Error).Header. Use
26184// googleapi.IsNotModified to check whether the returned error was
26185// because http.StatusNotModified was returned.
26186func (c *CreativeFieldsGetCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26187	gensupport.SetOptions(c.urlParams_, opts...)
26188	res, err := c.doRequest("json")
26189	if res != nil && res.StatusCode == http.StatusNotModified {
26190		if res.Body != nil {
26191			res.Body.Close()
26192		}
26193		return nil, &googleapi.Error{
26194			Code:   res.StatusCode,
26195			Header: res.Header,
26196		}
26197	}
26198	if err != nil {
26199		return nil, err
26200	}
26201	defer googleapi.CloseBody(res)
26202	if err := googleapi.CheckResponse(res); err != nil {
26203		return nil, err
26204	}
26205	ret := &CreativeField{
26206		ServerResponse: googleapi.ServerResponse{
26207			Header:         res.Header,
26208			HTTPStatusCode: res.StatusCode,
26209		},
26210	}
26211	target := &ret
26212	if err := gensupport.DecodeResponse(target, res); err != nil {
26213		return nil, err
26214	}
26215	return ret, nil
26216	// {
26217	//   "description": "Gets one creative field by ID.",
26218	//   "httpMethod": "GET",
26219	//   "id": "dfareporting.creativeFields.get",
26220	//   "parameterOrder": [
26221	//     "profileId",
26222	//     "id"
26223	//   ],
26224	//   "parameters": {
26225	//     "id": {
26226	//       "description": "Creative Field ID",
26227	//       "format": "int64",
26228	//       "location": "path",
26229	//       "required": true,
26230	//       "type": "string"
26231	//     },
26232	//     "profileId": {
26233	//       "description": "User profile ID associated with this request.",
26234	//       "format": "int64",
26235	//       "location": "path",
26236	//       "required": true,
26237	//       "type": "string"
26238	//     }
26239	//   },
26240	//   "path": "userprofiles/{profileId}/creativeFields/{id}",
26241	//   "response": {
26242	//     "$ref": "CreativeField"
26243	//   },
26244	//   "scopes": [
26245	//     "https://www.googleapis.com/auth/dfatrafficking"
26246	//   ]
26247	// }
26248
26249}
26250
26251// method id "dfareporting.creativeFields.insert":
26252
26253type CreativeFieldsInsertCall struct {
26254	s             *Service
26255	profileId     int64
26256	creativefield *CreativeField
26257	urlParams_    gensupport.URLParams
26258	ctx_          context.Context
26259	header_       http.Header
26260}
26261
26262// Insert: Inserts a new creative field.
26263func (r *CreativeFieldsService) Insert(profileId int64, creativefield *CreativeField) *CreativeFieldsInsertCall {
26264	c := &CreativeFieldsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26265	c.profileId = profileId
26266	c.creativefield = creativefield
26267	return c
26268}
26269
26270// Fields allows partial responses to be retrieved. See
26271// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26272// for more information.
26273func (c *CreativeFieldsInsertCall) Fields(s ...googleapi.Field) *CreativeFieldsInsertCall {
26274	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26275	return c
26276}
26277
26278// Context sets the context to be used in this call's Do method. Any
26279// pending HTTP request will be aborted if the provided context is
26280// canceled.
26281func (c *CreativeFieldsInsertCall) Context(ctx context.Context) *CreativeFieldsInsertCall {
26282	c.ctx_ = ctx
26283	return c
26284}
26285
26286// Header returns an http.Header that can be modified by the caller to
26287// add HTTP headers to the request.
26288func (c *CreativeFieldsInsertCall) Header() http.Header {
26289	if c.header_ == nil {
26290		c.header_ = make(http.Header)
26291	}
26292	return c.header_
26293}
26294
26295func (c *CreativeFieldsInsertCall) doRequest(alt string) (*http.Response, error) {
26296	reqHeaders := make(http.Header)
26297	for k, v := range c.header_ {
26298		reqHeaders[k] = v
26299	}
26300	reqHeaders.Set("User-Agent", c.s.userAgent())
26301	var body io.Reader = nil
26302	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
26303	if err != nil {
26304		return nil, err
26305	}
26306	reqHeaders.Set("Content-Type", "application/json")
26307	c.urlParams_.Set("alt", alt)
26308	c.urlParams_.Set("prettyPrint", "false")
26309	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26310	urls += "?" + c.urlParams_.Encode()
26311	req, err := http.NewRequest("POST", urls, body)
26312	if err != nil {
26313		return nil, err
26314	}
26315	req.Header = reqHeaders
26316	googleapi.Expand(req.URL, map[string]string{
26317		"profileId": strconv.FormatInt(c.profileId, 10),
26318	})
26319	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26320}
26321
26322// Do executes the "dfareporting.creativeFields.insert" call.
26323// Exactly one of *CreativeField or error will be non-nil. Any non-2xx
26324// status code is an error. Response headers are in either
26325// *CreativeField.ServerResponse.Header or (if a response was returned
26326// at all) in error.(*googleapi.Error).Header. Use
26327// googleapi.IsNotModified to check whether the returned error was
26328// because http.StatusNotModified was returned.
26329func (c *CreativeFieldsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26330	gensupport.SetOptions(c.urlParams_, opts...)
26331	res, err := c.doRequest("json")
26332	if res != nil && res.StatusCode == http.StatusNotModified {
26333		if res.Body != nil {
26334			res.Body.Close()
26335		}
26336		return nil, &googleapi.Error{
26337			Code:   res.StatusCode,
26338			Header: res.Header,
26339		}
26340	}
26341	if err != nil {
26342		return nil, err
26343	}
26344	defer googleapi.CloseBody(res)
26345	if err := googleapi.CheckResponse(res); err != nil {
26346		return nil, err
26347	}
26348	ret := &CreativeField{
26349		ServerResponse: googleapi.ServerResponse{
26350			Header:         res.Header,
26351			HTTPStatusCode: res.StatusCode,
26352		},
26353	}
26354	target := &ret
26355	if err := gensupport.DecodeResponse(target, res); err != nil {
26356		return nil, err
26357	}
26358	return ret, nil
26359	// {
26360	//   "description": "Inserts a new creative field.",
26361	//   "httpMethod": "POST",
26362	//   "id": "dfareporting.creativeFields.insert",
26363	//   "parameterOrder": [
26364	//     "profileId"
26365	//   ],
26366	//   "parameters": {
26367	//     "profileId": {
26368	//       "description": "User profile ID associated with this request.",
26369	//       "format": "int64",
26370	//       "location": "path",
26371	//       "required": true,
26372	//       "type": "string"
26373	//     }
26374	//   },
26375	//   "path": "userprofiles/{profileId}/creativeFields",
26376	//   "request": {
26377	//     "$ref": "CreativeField"
26378	//   },
26379	//   "response": {
26380	//     "$ref": "CreativeField"
26381	//   },
26382	//   "scopes": [
26383	//     "https://www.googleapis.com/auth/dfatrafficking"
26384	//   ]
26385	// }
26386
26387}
26388
26389// method id "dfareporting.creativeFields.list":
26390
26391type CreativeFieldsListCall struct {
26392	s            *Service
26393	profileId    int64
26394	urlParams_   gensupport.URLParams
26395	ifNoneMatch_ string
26396	ctx_         context.Context
26397	header_      http.Header
26398}
26399
26400// List: Retrieves a list of creative fields, possibly filtered. This
26401// method supports paging.
26402func (r *CreativeFieldsService) List(profileId int64) *CreativeFieldsListCall {
26403	c := &CreativeFieldsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26404	c.profileId = profileId
26405	return c
26406}
26407
26408// AdvertiserIds sets the optional parameter "advertiserIds": Select
26409// only creative fields that belong to these advertisers.
26410func (c *CreativeFieldsListCall) AdvertiserIds(advertiserIds ...int64) *CreativeFieldsListCall {
26411	var advertiserIds_ []string
26412	for _, v := range advertiserIds {
26413		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
26414	}
26415	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
26416	return c
26417}
26418
26419// Ids sets the optional parameter "ids": Select only creative fields
26420// with these IDs.
26421func (c *CreativeFieldsListCall) Ids(ids ...int64) *CreativeFieldsListCall {
26422	var ids_ []string
26423	for _, v := range ids {
26424		ids_ = append(ids_, fmt.Sprint(v))
26425	}
26426	c.urlParams_.SetMulti("ids", ids_)
26427	return c
26428}
26429
26430// MaxResults sets the optional parameter "maxResults": Maximum number
26431// of results to return.
26432func (c *CreativeFieldsListCall) MaxResults(maxResults int64) *CreativeFieldsListCall {
26433	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
26434	return c
26435}
26436
26437// PageToken sets the optional parameter "pageToken": Value of the
26438// nextPageToken from the previous result page.
26439func (c *CreativeFieldsListCall) PageToken(pageToken string) *CreativeFieldsListCall {
26440	c.urlParams_.Set("pageToken", pageToken)
26441	return c
26442}
26443
26444// SearchString sets the optional parameter "searchString": Allows
26445// searching for creative fields by name or ID. Wildcards (*) are
26446// allowed. For example, "creativefield*2015" will return creative
26447// fields with names like "creativefield June 2015", "creativefield
26448// April 2015", or simply "creativefield 2015". Most of the searches
26449// also add wild-cards implicitly at the start and the end of the search
26450// string. For example, a search string of "creativefield" will match
26451// creative fields with the name "my creativefield", "creativefield
26452// 2015", or simply "creativefield".
26453func (c *CreativeFieldsListCall) SearchString(searchString string) *CreativeFieldsListCall {
26454	c.urlParams_.Set("searchString", searchString)
26455	return c
26456}
26457
26458// SortField sets the optional parameter "sortField": Field by which to
26459// sort the list.
26460//
26461// Possible values:
26462//   "ID" (default)
26463//   "NAME"
26464func (c *CreativeFieldsListCall) SortField(sortField string) *CreativeFieldsListCall {
26465	c.urlParams_.Set("sortField", sortField)
26466	return c
26467}
26468
26469// SortOrder sets the optional parameter "sortOrder": Order of sorted
26470// results.
26471//
26472// Possible values:
26473//   "ASCENDING" (default)
26474//   "DESCENDING"
26475func (c *CreativeFieldsListCall) SortOrder(sortOrder string) *CreativeFieldsListCall {
26476	c.urlParams_.Set("sortOrder", sortOrder)
26477	return c
26478}
26479
26480// Fields allows partial responses to be retrieved. See
26481// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26482// for more information.
26483func (c *CreativeFieldsListCall) Fields(s ...googleapi.Field) *CreativeFieldsListCall {
26484	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26485	return c
26486}
26487
26488// IfNoneMatch sets the optional parameter which makes the operation
26489// fail if the object's ETag matches the given value. This is useful for
26490// getting updates only after the object has changed since the last
26491// request. Use googleapi.IsNotModified to check whether the response
26492// error from Do is the result of In-None-Match.
26493func (c *CreativeFieldsListCall) IfNoneMatch(entityTag string) *CreativeFieldsListCall {
26494	c.ifNoneMatch_ = entityTag
26495	return c
26496}
26497
26498// Context sets the context to be used in this call's Do method. Any
26499// pending HTTP request will be aborted if the provided context is
26500// canceled.
26501func (c *CreativeFieldsListCall) Context(ctx context.Context) *CreativeFieldsListCall {
26502	c.ctx_ = ctx
26503	return c
26504}
26505
26506// Header returns an http.Header that can be modified by the caller to
26507// add HTTP headers to the request.
26508func (c *CreativeFieldsListCall) Header() http.Header {
26509	if c.header_ == nil {
26510		c.header_ = make(http.Header)
26511	}
26512	return c.header_
26513}
26514
26515func (c *CreativeFieldsListCall) doRequest(alt string) (*http.Response, error) {
26516	reqHeaders := make(http.Header)
26517	for k, v := range c.header_ {
26518		reqHeaders[k] = v
26519	}
26520	reqHeaders.Set("User-Agent", c.s.userAgent())
26521	if c.ifNoneMatch_ != "" {
26522		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26523	}
26524	var body io.Reader = nil
26525	c.urlParams_.Set("alt", alt)
26526	c.urlParams_.Set("prettyPrint", "false")
26527	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26528	urls += "?" + c.urlParams_.Encode()
26529	req, err := http.NewRequest("GET", urls, body)
26530	if err != nil {
26531		return nil, err
26532	}
26533	req.Header = reqHeaders
26534	googleapi.Expand(req.URL, map[string]string{
26535		"profileId": strconv.FormatInt(c.profileId, 10),
26536	})
26537	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26538}
26539
26540// Do executes the "dfareporting.creativeFields.list" call.
26541// Exactly one of *CreativeFieldsListResponse or error will be non-nil.
26542// Any non-2xx status code is an error. Response headers are in either
26543// *CreativeFieldsListResponse.ServerResponse.Header or (if a response
26544// was returned at all) in error.(*googleapi.Error).Header. Use
26545// googleapi.IsNotModified to check whether the returned error was
26546// because http.StatusNotModified was returned.
26547func (c *CreativeFieldsListCall) Do(opts ...googleapi.CallOption) (*CreativeFieldsListResponse, error) {
26548	gensupport.SetOptions(c.urlParams_, opts...)
26549	res, err := c.doRequest("json")
26550	if res != nil && res.StatusCode == http.StatusNotModified {
26551		if res.Body != nil {
26552			res.Body.Close()
26553		}
26554		return nil, &googleapi.Error{
26555			Code:   res.StatusCode,
26556			Header: res.Header,
26557		}
26558	}
26559	if err != nil {
26560		return nil, err
26561	}
26562	defer googleapi.CloseBody(res)
26563	if err := googleapi.CheckResponse(res); err != nil {
26564		return nil, err
26565	}
26566	ret := &CreativeFieldsListResponse{
26567		ServerResponse: googleapi.ServerResponse{
26568			Header:         res.Header,
26569			HTTPStatusCode: res.StatusCode,
26570		},
26571	}
26572	target := &ret
26573	if err := gensupport.DecodeResponse(target, res); err != nil {
26574		return nil, err
26575	}
26576	return ret, nil
26577	// {
26578	//   "description": "Retrieves a list of creative fields, possibly filtered. This method supports paging.",
26579	//   "httpMethod": "GET",
26580	//   "id": "dfareporting.creativeFields.list",
26581	//   "parameterOrder": [
26582	//     "profileId"
26583	//   ],
26584	//   "parameters": {
26585	//     "advertiserIds": {
26586	//       "description": "Select only creative fields that belong to these advertisers.",
26587	//       "format": "int64",
26588	//       "location": "query",
26589	//       "repeated": true,
26590	//       "type": "string"
26591	//     },
26592	//     "ids": {
26593	//       "description": "Select only creative fields with these IDs.",
26594	//       "format": "int64",
26595	//       "location": "query",
26596	//       "repeated": true,
26597	//       "type": "string"
26598	//     },
26599	//     "maxResults": {
26600	//       "default": "1000",
26601	//       "description": "Maximum number of results to return.",
26602	//       "format": "int32",
26603	//       "location": "query",
26604	//       "maximum": "1000",
26605	//       "minimum": "0",
26606	//       "type": "integer"
26607	//     },
26608	//     "pageToken": {
26609	//       "description": "Value of the nextPageToken from the previous result page.",
26610	//       "location": "query",
26611	//       "type": "string"
26612	//     },
26613	//     "profileId": {
26614	//       "description": "User profile ID associated with this request.",
26615	//       "format": "int64",
26616	//       "location": "path",
26617	//       "required": true,
26618	//       "type": "string"
26619	//     },
26620	//     "searchString": {
26621	//       "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\".",
26622	//       "location": "query",
26623	//       "type": "string"
26624	//     },
26625	//     "sortField": {
26626	//       "default": "ID",
26627	//       "description": "Field by which to sort the list.",
26628	//       "enum": [
26629	//         "ID",
26630	//         "NAME"
26631	//       ],
26632	//       "enumDescriptions": [
26633	//         "",
26634	//         ""
26635	//       ],
26636	//       "location": "query",
26637	//       "type": "string"
26638	//     },
26639	//     "sortOrder": {
26640	//       "default": "ASCENDING",
26641	//       "description": "Order of sorted results.",
26642	//       "enum": [
26643	//         "ASCENDING",
26644	//         "DESCENDING"
26645	//       ],
26646	//       "enumDescriptions": [
26647	//         "",
26648	//         ""
26649	//       ],
26650	//       "location": "query",
26651	//       "type": "string"
26652	//     }
26653	//   },
26654	//   "path": "userprofiles/{profileId}/creativeFields",
26655	//   "response": {
26656	//     "$ref": "CreativeFieldsListResponse"
26657	//   },
26658	//   "scopes": [
26659	//     "https://www.googleapis.com/auth/dfatrafficking"
26660	//   ]
26661	// }
26662
26663}
26664
26665// Pages invokes f for each page of results.
26666// A non-nil error returned from f will halt the iteration.
26667// The provided context supersedes any context provided to the Context method.
26668func (c *CreativeFieldsListCall) Pages(ctx context.Context, f func(*CreativeFieldsListResponse) error) error {
26669	c.ctx_ = ctx
26670	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
26671	for {
26672		x, err := c.Do()
26673		if err != nil {
26674			return err
26675		}
26676		if err := f(x); err != nil {
26677			return err
26678		}
26679		if x.NextPageToken == "" {
26680			return nil
26681		}
26682		c.PageToken(x.NextPageToken)
26683	}
26684}
26685
26686// method id "dfareporting.creativeFields.patch":
26687
26688type CreativeFieldsPatchCall struct {
26689	s             *Service
26690	profileId     int64
26691	creativefield *CreativeField
26692	urlParams_    gensupport.URLParams
26693	ctx_          context.Context
26694	header_       http.Header
26695}
26696
26697// Patch: Updates an existing creative field. This method supports patch
26698// semantics.
26699func (r *CreativeFieldsService) Patch(profileId int64, id int64, creativefield *CreativeField) *CreativeFieldsPatchCall {
26700	c := &CreativeFieldsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26701	c.profileId = profileId
26702	c.urlParams_.Set("id", fmt.Sprint(id))
26703	c.creativefield = creativefield
26704	return c
26705}
26706
26707// Fields allows partial responses to be retrieved. See
26708// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26709// for more information.
26710func (c *CreativeFieldsPatchCall) Fields(s ...googleapi.Field) *CreativeFieldsPatchCall {
26711	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26712	return c
26713}
26714
26715// Context sets the context to be used in this call's Do method. Any
26716// pending HTTP request will be aborted if the provided context is
26717// canceled.
26718func (c *CreativeFieldsPatchCall) Context(ctx context.Context) *CreativeFieldsPatchCall {
26719	c.ctx_ = ctx
26720	return c
26721}
26722
26723// Header returns an http.Header that can be modified by the caller to
26724// add HTTP headers to the request.
26725func (c *CreativeFieldsPatchCall) Header() http.Header {
26726	if c.header_ == nil {
26727		c.header_ = make(http.Header)
26728	}
26729	return c.header_
26730}
26731
26732func (c *CreativeFieldsPatchCall) doRequest(alt string) (*http.Response, error) {
26733	reqHeaders := make(http.Header)
26734	for k, v := range c.header_ {
26735		reqHeaders[k] = v
26736	}
26737	reqHeaders.Set("User-Agent", c.s.userAgent())
26738	var body io.Reader = nil
26739	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
26740	if err != nil {
26741		return nil, err
26742	}
26743	reqHeaders.Set("Content-Type", "application/json")
26744	c.urlParams_.Set("alt", alt)
26745	c.urlParams_.Set("prettyPrint", "false")
26746	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26747	urls += "?" + c.urlParams_.Encode()
26748	req, err := http.NewRequest("PATCH", urls, body)
26749	if err != nil {
26750		return nil, err
26751	}
26752	req.Header = reqHeaders
26753	googleapi.Expand(req.URL, map[string]string{
26754		"profileId": strconv.FormatInt(c.profileId, 10),
26755	})
26756	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26757}
26758
26759// Do executes the "dfareporting.creativeFields.patch" call.
26760// Exactly one of *CreativeField or error will be non-nil. Any non-2xx
26761// status code is an error. Response headers are in either
26762// *CreativeField.ServerResponse.Header or (if a response was returned
26763// at all) in error.(*googleapi.Error).Header. Use
26764// googleapi.IsNotModified to check whether the returned error was
26765// because http.StatusNotModified was returned.
26766func (c *CreativeFieldsPatchCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26767	gensupport.SetOptions(c.urlParams_, opts...)
26768	res, err := c.doRequest("json")
26769	if res != nil && res.StatusCode == http.StatusNotModified {
26770		if res.Body != nil {
26771			res.Body.Close()
26772		}
26773		return nil, &googleapi.Error{
26774			Code:   res.StatusCode,
26775			Header: res.Header,
26776		}
26777	}
26778	if err != nil {
26779		return nil, err
26780	}
26781	defer googleapi.CloseBody(res)
26782	if err := googleapi.CheckResponse(res); err != nil {
26783		return nil, err
26784	}
26785	ret := &CreativeField{
26786		ServerResponse: googleapi.ServerResponse{
26787			Header:         res.Header,
26788			HTTPStatusCode: res.StatusCode,
26789		},
26790	}
26791	target := &ret
26792	if err := gensupport.DecodeResponse(target, res); err != nil {
26793		return nil, err
26794	}
26795	return ret, nil
26796	// {
26797	//   "description": "Updates an existing creative field. This method supports patch semantics.",
26798	//   "httpMethod": "PATCH",
26799	//   "id": "dfareporting.creativeFields.patch",
26800	//   "parameterOrder": [
26801	//     "profileId",
26802	//     "id"
26803	//   ],
26804	//   "parameters": {
26805	//     "id": {
26806	//       "description": "Creative Field ID",
26807	//       "format": "int64",
26808	//       "location": "query",
26809	//       "required": true,
26810	//       "type": "string"
26811	//     },
26812	//     "profileId": {
26813	//       "description": "User profile ID associated with this request.",
26814	//       "format": "int64",
26815	//       "location": "path",
26816	//       "required": true,
26817	//       "type": "string"
26818	//     }
26819	//   },
26820	//   "path": "userprofiles/{profileId}/creativeFields",
26821	//   "request": {
26822	//     "$ref": "CreativeField"
26823	//   },
26824	//   "response": {
26825	//     "$ref": "CreativeField"
26826	//   },
26827	//   "scopes": [
26828	//     "https://www.googleapis.com/auth/dfatrafficking"
26829	//   ]
26830	// }
26831
26832}
26833
26834// method id "dfareporting.creativeFields.update":
26835
26836type CreativeFieldsUpdateCall struct {
26837	s             *Service
26838	profileId     int64
26839	creativefield *CreativeField
26840	urlParams_    gensupport.URLParams
26841	ctx_          context.Context
26842	header_       http.Header
26843}
26844
26845// Update: Updates an existing creative field.
26846func (r *CreativeFieldsService) Update(profileId int64, creativefield *CreativeField) *CreativeFieldsUpdateCall {
26847	c := &CreativeFieldsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26848	c.profileId = profileId
26849	c.creativefield = creativefield
26850	return c
26851}
26852
26853// Fields allows partial responses to be retrieved. See
26854// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26855// for more information.
26856func (c *CreativeFieldsUpdateCall) Fields(s ...googleapi.Field) *CreativeFieldsUpdateCall {
26857	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26858	return c
26859}
26860
26861// Context sets the context to be used in this call's Do method. Any
26862// pending HTTP request will be aborted if the provided context is
26863// canceled.
26864func (c *CreativeFieldsUpdateCall) Context(ctx context.Context) *CreativeFieldsUpdateCall {
26865	c.ctx_ = ctx
26866	return c
26867}
26868
26869// Header returns an http.Header that can be modified by the caller to
26870// add HTTP headers to the request.
26871func (c *CreativeFieldsUpdateCall) Header() http.Header {
26872	if c.header_ == nil {
26873		c.header_ = make(http.Header)
26874	}
26875	return c.header_
26876}
26877
26878func (c *CreativeFieldsUpdateCall) doRequest(alt string) (*http.Response, error) {
26879	reqHeaders := make(http.Header)
26880	for k, v := range c.header_ {
26881		reqHeaders[k] = v
26882	}
26883	reqHeaders.Set("User-Agent", c.s.userAgent())
26884	var body io.Reader = nil
26885	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
26886	if err != nil {
26887		return nil, err
26888	}
26889	reqHeaders.Set("Content-Type", "application/json")
26890	c.urlParams_.Set("alt", alt)
26891	c.urlParams_.Set("prettyPrint", "false")
26892	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26893	urls += "?" + c.urlParams_.Encode()
26894	req, err := http.NewRequest("PUT", urls, body)
26895	if err != nil {
26896		return nil, err
26897	}
26898	req.Header = reqHeaders
26899	googleapi.Expand(req.URL, map[string]string{
26900		"profileId": strconv.FormatInt(c.profileId, 10),
26901	})
26902	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26903}
26904
26905// Do executes the "dfareporting.creativeFields.update" call.
26906// Exactly one of *CreativeField or error will be non-nil. Any non-2xx
26907// status code is an error. Response headers are in either
26908// *CreativeField.ServerResponse.Header or (if a response was returned
26909// at all) in error.(*googleapi.Error).Header. Use
26910// googleapi.IsNotModified to check whether the returned error was
26911// because http.StatusNotModified was returned.
26912func (c *CreativeFieldsUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26913	gensupport.SetOptions(c.urlParams_, opts...)
26914	res, err := c.doRequest("json")
26915	if res != nil && res.StatusCode == http.StatusNotModified {
26916		if res.Body != nil {
26917			res.Body.Close()
26918		}
26919		return nil, &googleapi.Error{
26920			Code:   res.StatusCode,
26921			Header: res.Header,
26922		}
26923	}
26924	if err != nil {
26925		return nil, err
26926	}
26927	defer googleapi.CloseBody(res)
26928	if err := googleapi.CheckResponse(res); err != nil {
26929		return nil, err
26930	}
26931	ret := &CreativeField{
26932		ServerResponse: googleapi.ServerResponse{
26933			Header:         res.Header,
26934			HTTPStatusCode: res.StatusCode,
26935		},
26936	}
26937	target := &ret
26938	if err := gensupport.DecodeResponse(target, res); err != nil {
26939		return nil, err
26940	}
26941	return ret, nil
26942	// {
26943	//   "description": "Updates an existing creative field.",
26944	//   "httpMethod": "PUT",
26945	//   "id": "dfareporting.creativeFields.update",
26946	//   "parameterOrder": [
26947	//     "profileId"
26948	//   ],
26949	//   "parameters": {
26950	//     "profileId": {
26951	//       "description": "User profile ID associated with this request.",
26952	//       "format": "int64",
26953	//       "location": "path",
26954	//       "required": true,
26955	//       "type": "string"
26956	//     }
26957	//   },
26958	//   "path": "userprofiles/{profileId}/creativeFields",
26959	//   "request": {
26960	//     "$ref": "CreativeField"
26961	//   },
26962	//   "response": {
26963	//     "$ref": "CreativeField"
26964	//   },
26965	//   "scopes": [
26966	//     "https://www.googleapis.com/auth/dfatrafficking"
26967	//   ]
26968	// }
26969
26970}
26971
26972// method id "dfareporting.creativeGroups.get":
26973
26974type CreativeGroupsGetCall struct {
26975	s            *Service
26976	profileId    int64
26977	id           int64
26978	urlParams_   gensupport.URLParams
26979	ifNoneMatch_ string
26980	ctx_         context.Context
26981	header_      http.Header
26982}
26983
26984// Get: Gets one creative group by ID.
26985func (r *CreativeGroupsService) Get(profileId int64, id int64) *CreativeGroupsGetCall {
26986	c := &CreativeGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26987	c.profileId = profileId
26988	c.id = id
26989	return c
26990}
26991
26992// Fields allows partial responses to be retrieved. See
26993// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26994// for more information.
26995func (c *CreativeGroupsGetCall) Fields(s ...googleapi.Field) *CreativeGroupsGetCall {
26996	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26997	return c
26998}
26999
27000// IfNoneMatch sets the optional parameter which makes the operation
27001// fail if the object's ETag matches the given value. This is useful for
27002// getting updates only after the object has changed since the last
27003// request. Use googleapi.IsNotModified to check whether the response
27004// error from Do is the result of In-None-Match.
27005func (c *CreativeGroupsGetCall) IfNoneMatch(entityTag string) *CreativeGroupsGetCall {
27006	c.ifNoneMatch_ = entityTag
27007	return c
27008}
27009
27010// Context sets the context to be used in this call's Do method. Any
27011// pending HTTP request will be aborted if the provided context is
27012// canceled.
27013func (c *CreativeGroupsGetCall) Context(ctx context.Context) *CreativeGroupsGetCall {
27014	c.ctx_ = ctx
27015	return c
27016}
27017
27018// Header returns an http.Header that can be modified by the caller to
27019// add HTTP headers to the request.
27020func (c *CreativeGroupsGetCall) Header() http.Header {
27021	if c.header_ == nil {
27022		c.header_ = make(http.Header)
27023	}
27024	return c.header_
27025}
27026
27027func (c *CreativeGroupsGetCall) doRequest(alt string) (*http.Response, error) {
27028	reqHeaders := make(http.Header)
27029	for k, v := range c.header_ {
27030		reqHeaders[k] = v
27031	}
27032	reqHeaders.Set("User-Agent", c.s.userAgent())
27033	if c.ifNoneMatch_ != "" {
27034		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27035	}
27036	var body io.Reader = nil
27037	c.urlParams_.Set("alt", alt)
27038	c.urlParams_.Set("prettyPrint", "false")
27039	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups/{id}")
27040	urls += "?" + c.urlParams_.Encode()
27041	req, err := http.NewRequest("GET", urls, body)
27042	if err != nil {
27043		return nil, err
27044	}
27045	req.Header = reqHeaders
27046	googleapi.Expand(req.URL, map[string]string{
27047		"profileId": strconv.FormatInt(c.profileId, 10),
27048		"id":        strconv.FormatInt(c.id, 10),
27049	})
27050	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27051}
27052
27053// Do executes the "dfareporting.creativeGroups.get" call.
27054// Exactly one of *CreativeGroup or error will be non-nil. Any non-2xx
27055// status code is an error. Response headers are in either
27056// *CreativeGroup.ServerResponse.Header or (if a response was returned
27057// at all) in error.(*googleapi.Error).Header. Use
27058// googleapi.IsNotModified to check whether the returned error was
27059// because http.StatusNotModified was returned.
27060func (c *CreativeGroupsGetCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27061	gensupport.SetOptions(c.urlParams_, opts...)
27062	res, err := c.doRequest("json")
27063	if res != nil && res.StatusCode == http.StatusNotModified {
27064		if res.Body != nil {
27065			res.Body.Close()
27066		}
27067		return nil, &googleapi.Error{
27068			Code:   res.StatusCode,
27069			Header: res.Header,
27070		}
27071	}
27072	if err != nil {
27073		return nil, err
27074	}
27075	defer googleapi.CloseBody(res)
27076	if err := googleapi.CheckResponse(res); err != nil {
27077		return nil, err
27078	}
27079	ret := &CreativeGroup{
27080		ServerResponse: googleapi.ServerResponse{
27081			Header:         res.Header,
27082			HTTPStatusCode: res.StatusCode,
27083		},
27084	}
27085	target := &ret
27086	if err := gensupport.DecodeResponse(target, res); err != nil {
27087		return nil, err
27088	}
27089	return ret, nil
27090	// {
27091	//   "description": "Gets one creative group by ID.",
27092	//   "httpMethod": "GET",
27093	//   "id": "dfareporting.creativeGroups.get",
27094	//   "parameterOrder": [
27095	//     "profileId",
27096	//     "id"
27097	//   ],
27098	//   "parameters": {
27099	//     "id": {
27100	//       "description": "Creative group ID.",
27101	//       "format": "int64",
27102	//       "location": "path",
27103	//       "required": true,
27104	//       "type": "string"
27105	//     },
27106	//     "profileId": {
27107	//       "description": "User profile ID associated with this request.",
27108	//       "format": "int64",
27109	//       "location": "path",
27110	//       "required": true,
27111	//       "type": "string"
27112	//     }
27113	//   },
27114	//   "path": "userprofiles/{profileId}/creativeGroups/{id}",
27115	//   "response": {
27116	//     "$ref": "CreativeGroup"
27117	//   },
27118	//   "scopes": [
27119	//     "https://www.googleapis.com/auth/dfatrafficking"
27120	//   ]
27121	// }
27122
27123}
27124
27125// method id "dfareporting.creativeGroups.insert":
27126
27127type CreativeGroupsInsertCall struct {
27128	s             *Service
27129	profileId     int64
27130	creativegroup *CreativeGroup
27131	urlParams_    gensupport.URLParams
27132	ctx_          context.Context
27133	header_       http.Header
27134}
27135
27136// Insert: Inserts a new creative group.
27137func (r *CreativeGroupsService) Insert(profileId int64, creativegroup *CreativeGroup) *CreativeGroupsInsertCall {
27138	c := &CreativeGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27139	c.profileId = profileId
27140	c.creativegroup = creativegroup
27141	return c
27142}
27143
27144// Fields allows partial responses to be retrieved. See
27145// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27146// for more information.
27147func (c *CreativeGroupsInsertCall) Fields(s ...googleapi.Field) *CreativeGroupsInsertCall {
27148	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27149	return c
27150}
27151
27152// Context sets the context to be used in this call's Do method. Any
27153// pending HTTP request will be aborted if the provided context is
27154// canceled.
27155func (c *CreativeGroupsInsertCall) Context(ctx context.Context) *CreativeGroupsInsertCall {
27156	c.ctx_ = ctx
27157	return c
27158}
27159
27160// Header returns an http.Header that can be modified by the caller to
27161// add HTTP headers to the request.
27162func (c *CreativeGroupsInsertCall) Header() http.Header {
27163	if c.header_ == nil {
27164		c.header_ = make(http.Header)
27165	}
27166	return c.header_
27167}
27168
27169func (c *CreativeGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
27170	reqHeaders := make(http.Header)
27171	for k, v := range c.header_ {
27172		reqHeaders[k] = v
27173	}
27174	reqHeaders.Set("User-Agent", c.s.userAgent())
27175	var body io.Reader = nil
27176	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27177	if err != nil {
27178		return nil, err
27179	}
27180	reqHeaders.Set("Content-Type", "application/json")
27181	c.urlParams_.Set("alt", alt)
27182	c.urlParams_.Set("prettyPrint", "false")
27183	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27184	urls += "?" + c.urlParams_.Encode()
27185	req, err := http.NewRequest("POST", urls, body)
27186	if err != nil {
27187		return nil, err
27188	}
27189	req.Header = reqHeaders
27190	googleapi.Expand(req.URL, map[string]string{
27191		"profileId": strconv.FormatInt(c.profileId, 10),
27192	})
27193	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27194}
27195
27196// Do executes the "dfareporting.creativeGroups.insert" call.
27197// Exactly one of *CreativeGroup or error will be non-nil. Any non-2xx
27198// status code is an error. Response headers are in either
27199// *CreativeGroup.ServerResponse.Header or (if a response was returned
27200// at all) in error.(*googleapi.Error).Header. Use
27201// googleapi.IsNotModified to check whether the returned error was
27202// because http.StatusNotModified was returned.
27203func (c *CreativeGroupsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27204	gensupport.SetOptions(c.urlParams_, opts...)
27205	res, err := c.doRequest("json")
27206	if res != nil && res.StatusCode == http.StatusNotModified {
27207		if res.Body != nil {
27208			res.Body.Close()
27209		}
27210		return nil, &googleapi.Error{
27211			Code:   res.StatusCode,
27212			Header: res.Header,
27213		}
27214	}
27215	if err != nil {
27216		return nil, err
27217	}
27218	defer googleapi.CloseBody(res)
27219	if err := googleapi.CheckResponse(res); err != nil {
27220		return nil, err
27221	}
27222	ret := &CreativeGroup{
27223		ServerResponse: googleapi.ServerResponse{
27224			Header:         res.Header,
27225			HTTPStatusCode: res.StatusCode,
27226		},
27227	}
27228	target := &ret
27229	if err := gensupport.DecodeResponse(target, res); err != nil {
27230		return nil, err
27231	}
27232	return ret, nil
27233	// {
27234	//   "description": "Inserts a new creative group.",
27235	//   "httpMethod": "POST",
27236	//   "id": "dfareporting.creativeGroups.insert",
27237	//   "parameterOrder": [
27238	//     "profileId"
27239	//   ],
27240	//   "parameters": {
27241	//     "profileId": {
27242	//       "description": "User profile ID associated with this request.",
27243	//       "format": "int64",
27244	//       "location": "path",
27245	//       "required": true,
27246	//       "type": "string"
27247	//     }
27248	//   },
27249	//   "path": "userprofiles/{profileId}/creativeGroups",
27250	//   "request": {
27251	//     "$ref": "CreativeGroup"
27252	//   },
27253	//   "response": {
27254	//     "$ref": "CreativeGroup"
27255	//   },
27256	//   "scopes": [
27257	//     "https://www.googleapis.com/auth/dfatrafficking"
27258	//   ]
27259	// }
27260
27261}
27262
27263// method id "dfareporting.creativeGroups.list":
27264
27265type CreativeGroupsListCall struct {
27266	s            *Service
27267	profileId    int64
27268	urlParams_   gensupport.URLParams
27269	ifNoneMatch_ string
27270	ctx_         context.Context
27271	header_      http.Header
27272}
27273
27274// List: Retrieves a list of creative groups, possibly filtered. This
27275// method supports paging.
27276func (r *CreativeGroupsService) List(profileId int64) *CreativeGroupsListCall {
27277	c := &CreativeGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27278	c.profileId = profileId
27279	return c
27280}
27281
27282// AdvertiserIds sets the optional parameter "advertiserIds": Select
27283// only creative groups that belong to these advertisers.
27284func (c *CreativeGroupsListCall) AdvertiserIds(advertiserIds ...int64) *CreativeGroupsListCall {
27285	var advertiserIds_ []string
27286	for _, v := range advertiserIds {
27287		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
27288	}
27289	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
27290	return c
27291}
27292
27293// GroupNumber sets the optional parameter "groupNumber": Select only
27294// creative groups that belong to this subgroup.
27295func (c *CreativeGroupsListCall) GroupNumber(groupNumber int64) *CreativeGroupsListCall {
27296	c.urlParams_.Set("groupNumber", fmt.Sprint(groupNumber))
27297	return c
27298}
27299
27300// Ids sets the optional parameter "ids": Select only creative groups
27301// with these IDs.
27302func (c *CreativeGroupsListCall) Ids(ids ...int64) *CreativeGroupsListCall {
27303	var ids_ []string
27304	for _, v := range ids {
27305		ids_ = append(ids_, fmt.Sprint(v))
27306	}
27307	c.urlParams_.SetMulti("ids", ids_)
27308	return c
27309}
27310
27311// MaxResults sets the optional parameter "maxResults": Maximum number
27312// of results to return.
27313func (c *CreativeGroupsListCall) MaxResults(maxResults int64) *CreativeGroupsListCall {
27314	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
27315	return c
27316}
27317
27318// PageToken sets the optional parameter "pageToken": Value of the
27319// nextPageToken from the previous result page.
27320func (c *CreativeGroupsListCall) PageToken(pageToken string) *CreativeGroupsListCall {
27321	c.urlParams_.Set("pageToken", pageToken)
27322	return c
27323}
27324
27325// SearchString sets the optional parameter "searchString": Allows
27326// searching for creative groups by name or ID. Wildcards (*) are
27327// allowed. For example, "creativegroup*2015" will return creative
27328// groups with names like "creativegroup June 2015", "creativegroup
27329// April 2015", or simply "creativegroup 2015". Most of the searches
27330// also add wild-cards implicitly at the start and the end of the search
27331// string. For example, a search string of "creativegroup" will match
27332// creative groups with the name "my creativegroup", "creativegroup
27333// 2015", or simply "creativegroup".
27334func (c *CreativeGroupsListCall) SearchString(searchString string) *CreativeGroupsListCall {
27335	c.urlParams_.Set("searchString", searchString)
27336	return c
27337}
27338
27339// SortField sets the optional parameter "sortField": Field by which to
27340// sort the list.
27341//
27342// Possible values:
27343//   "ID" (default)
27344//   "NAME"
27345func (c *CreativeGroupsListCall) SortField(sortField string) *CreativeGroupsListCall {
27346	c.urlParams_.Set("sortField", sortField)
27347	return c
27348}
27349
27350// SortOrder sets the optional parameter "sortOrder": Order of sorted
27351// results.
27352//
27353// Possible values:
27354//   "ASCENDING" (default)
27355//   "DESCENDING"
27356func (c *CreativeGroupsListCall) SortOrder(sortOrder string) *CreativeGroupsListCall {
27357	c.urlParams_.Set("sortOrder", sortOrder)
27358	return c
27359}
27360
27361// Fields allows partial responses to be retrieved. See
27362// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27363// for more information.
27364func (c *CreativeGroupsListCall) Fields(s ...googleapi.Field) *CreativeGroupsListCall {
27365	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27366	return c
27367}
27368
27369// IfNoneMatch sets the optional parameter which makes the operation
27370// fail if the object's ETag matches the given value. This is useful for
27371// getting updates only after the object has changed since the last
27372// request. Use googleapi.IsNotModified to check whether the response
27373// error from Do is the result of In-None-Match.
27374func (c *CreativeGroupsListCall) IfNoneMatch(entityTag string) *CreativeGroupsListCall {
27375	c.ifNoneMatch_ = entityTag
27376	return c
27377}
27378
27379// Context sets the context to be used in this call's Do method. Any
27380// pending HTTP request will be aborted if the provided context is
27381// canceled.
27382func (c *CreativeGroupsListCall) Context(ctx context.Context) *CreativeGroupsListCall {
27383	c.ctx_ = ctx
27384	return c
27385}
27386
27387// Header returns an http.Header that can be modified by the caller to
27388// add HTTP headers to the request.
27389func (c *CreativeGroupsListCall) Header() http.Header {
27390	if c.header_ == nil {
27391		c.header_ = make(http.Header)
27392	}
27393	return c.header_
27394}
27395
27396func (c *CreativeGroupsListCall) doRequest(alt string) (*http.Response, error) {
27397	reqHeaders := make(http.Header)
27398	for k, v := range c.header_ {
27399		reqHeaders[k] = v
27400	}
27401	reqHeaders.Set("User-Agent", c.s.userAgent())
27402	if c.ifNoneMatch_ != "" {
27403		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27404	}
27405	var body io.Reader = nil
27406	c.urlParams_.Set("alt", alt)
27407	c.urlParams_.Set("prettyPrint", "false")
27408	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27409	urls += "?" + c.urlParams_.Encode()
27410	req, err := http.NewRequest("GET", urls, body)
27411	if err != nil {
27412		return nil, err
27413	}
27414	req.Header = reqHeaders
27415	googleapi.Expand(req.URL, map[string]string{
27416		"profileId": strconv.FormatInt(c.profileId, 10),
27417	})
27418	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27419}
27420
27421// Do executes the "dfareporting.creativeGroups.list" call.
27422// Exactly one of *CreativeGroupsListResponse or error will be non-nil.
27423// Any non-2xx status code is an error. Response headers are in either
27424// *CreativeGroupsListResponse.ServerResponse.Header or (if a response
27425// was returned at all) in error.(*googleapi.Error).Header. Use
27426// googleapi.IsNotModified to check whether the returned error was
27427// because http.StatusNotModified was returned.
27428func (c *CreativeGroupsListCall) Do(opts ...googleapi.CallOption) (*CreativeGroupsListResponse, error) {
27429	gensupport.SetOptions(c.urlParams_, opts...)
27430	res, err := c.doRequest("json")
27431	if res != nil && res.StatusCode == http.StatusNotModified {
27432		if res.Body != nil {
27433			res.Body.Close()
27434		}
27435		return nil, &googleapi.Error{
27436			Code:   res.StatusCode,
27437			Header: res.Header,
27438		}
27439	}
27440	if err != nil {
27441		return nil, err
27442	}
27443	defer googleapi.CloseBody(res)
27444	if err := googleapi.CheckResponse(res); err != nil {
27445		return nil, err
27446	}
27447	ret := &CreativeGroupsListResponse{
27448		ServerResponse: googleapi.ServerResponse{
27449			Header:         res.Header,
27450			HTTPStatusCode: res.StatusCode,
27451		},
27452	}
27453	target := &ret
27454	if err := gensupport.DecodeResponse(target, res); err != nil {
27455		return nil, err
27456	}
27457	return ret, nil
27458	// {
27459	//   "description": "Retrieves a list of creative groups, possibly filtered. This method supports paging.",
27460	//   "httpMethod": "GET",
27461	//   "id": "dfareporting.creativeGroups.list",
27462	//   "parameterOrder": [
27463	//     "profileId"
27464	//   ],
27465	//   "parameters": {
27466	//     "advertiserIds": {
27467	//       "description": "Select only creative groups that belong to these advertisers.",
27468	//       "format": "int64",
27469	//       "location": "query",
27470	//       "repeated": true,
27471	//       "type": "string"
27472	//     },
27473	//     "groupNumber": {
27474	//       "description": "Select only creative groups that belong to this subgroup.",
27475	//       "format": "int32",
27476	//       "location": "query",
27477	//       "maximum": "2",
27478	//       "minimum": "1",
27479	//       "type": "integer"
27480	//     },
27481	//     "ids": {
27482	//       "description": "Select only creative groups with these IDs.",
27483	//       "format": "int64",
27484	//       "location": "query",
27485	//       "repeated": true,
27486	//       "type": "string"
27487	//     },
27488	//     "maxResults": {
27489	//       "default": "1000",
27490	//       "description": "Maximum number of results to return.",
27491	//       "format": "int32",
27492	//       "location": "query",
27493	//       "maximum": "1000",
27494	//       "minimum": "0",
27495	//       "type": "integer"
27496	//     },
27497	//     "pageToken": {
27498	//       "description": "Value of the nextPageToken from the previous result page.",
27499	//       "location": "query",
27500	//       "type": "string"
27501	//     },
27502	//     "profileId": {
27503	//       "description": "User profile ID associated with this request.",
27504	//       "format": "int64",
27505	//       "location": "path",
27506	//       "required": true,
27507	//       "type": "string"
27508	//     },
27509	//     "searchString": {
27510	//       "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\".",
27511	//       "location": "query",
27512	//       "type": "string"
27513	//     },
27514	//     "sortField": {
27515	//       "default": "ID",
27516	//       "description": "Field by which to sort the list.",
27517	//       "enum": [
27518	//         "ID",
27519	//         "NAME"
27520	//       ],
27521	//       "enumDescriptions": [
27522	//         "",
27523	//         ""
27524	//       ],
27525	//       "location": "query",
27526	//       "type": "string"
27527	//     },
27528	//     "sortOrder": {
27529	//       "default": "ASCENDING",
27530	//       "description": "Order of sorted results.",
27531	//       "enum": [
27532	//         "ASCENDING",
27533	//         "DESCENDING"
27534	//       ],
27535	//       "enumDescriptions": [
27536	//         "",
27537	//         ""
27538	//       ],
27539	//       "location": "query",
27540	//       "type": "string"
27541	//     }
27542	//   },
27543	//   "path": "userprofiles/{profileId}/creativeGroups",
27544	//   "response": {
27545	//     "$ref": "CreativeGroupsListResponse"
27546	//   },
27547	//   "scopes": [
27548	//     "https://www.googleapis.com/auth/dfatrafficking"
27549	//   ]
27550	// }
27551
27552}
27553
27554// Pages invokes f for each page of results.
27555// A non-nil error returned from f will halt the iteration.
27556// The provided context supersedes any context provided to the Context method.
27557func (c *CreativeGroupsListCall) Pages(ctx context.Context, f func(*CreativeGroupsListResponse) error) error {
27558	c.ctx_ = ctx
27559	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
27560	for {
27561		x, err := c.Do()
27562		if err != nil {
27563			return err
27564		}
27565		if err := f(x); err != nil {
27566			return err
27567		}
27568		if x.NextPageToken == "" {
27569			return nil
27570		}
27571		c.PageToken(x.NextPageToken)
27572	}
27573}
27574
27575// method id "dfareporting.creativeGroups.patch":
27576
27577type CreativeGroupsPatchCall struct {
27578	s             *Service
27579	profileId     int64
27580	creativegroup *CreativeGroup
27581	urlParams_    gensupport.URLParams
27582	ctx_          context.Context
27583	header_       http.Header
27584}
27585
27586// Patch: Updates an existing creative group. This method supports patch
27587// semantics.
27588func (r *CreativeGroupsService) Patch(profileId int64, id int64, creativegroup *CreativeGroup) *CreativeGroupsPatchCall {
27589	c := &CreativeGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27590	c.profileId = profileId
27591	c.urlParams_.Set("id", fmt.Sprint(id))
27592	c.creativegroup = creativegroup
27593	return c
27594}
27595
27596// Fields allows partial responses to be retrieved. See
27597// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27598// for more information.
27599func (c *CreativeGroupsPatchCall) Fields(s ...googleapi.Field) *CreativeGroupsPatchCall {
27600	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27601	return c
27602}
27603
27604// Context sets the context to be used in this call's Do method. Any
27605// pending HTTP request will be aborted if the provided context is
27606// canceled.
27607func (c *CreativeGroupsPatchCall) Context(ctx context.Context) *CreativeGroupsPatchCall {
27608	c.ctx_ = ctx
27609	return c
27610}
27611
27612// Header returns an http.Header that can be modified by the caller to
27613// add HTTP headers to the request.
27614func (c *CreativeGroupsPatchCall) Header() http.Header {
27615	if c.header_ == nil {
27616		c.header_ = make(http.Header)
27617	}
27618	return c.header_
27619}
27620
27621func (c *CreativeGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
27622	reqHeaders := make(http.Header)
27623	for k, v := range c.header_ {
27624		reqHeaders[k] = v
27625	}
27626	reqHeaders.Set("User-Agent", c.s.userAgent())
27627	var body io.Reader = nil
27628	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27629	if err != nil {
27630		return nil, err
27631	}
27632	reqHeaders.Set("Content-Type", "application/json")
27633	c.urlParams_.Set("alt", alt)
27634	c.urlParams_.Set("prettyPrint", "false")
27635	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27636	urls += "?" + c.urlParams_.Encode()
27637	req, err := http.NewRequest("PATCH", urls, body)
27638	if err != nil {
27639		return nil, err
27640	}
27641	req.Header = reqHeaders
27642	googleapi.Expand(req.URL, map[string]string{
27643		"profileId": strconv.FormatInt(c.profileId, 10),
27644	})
27645	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27646}
27647
27648// Do executes the "dfareporting.creativeGroups.patch" call.
27649// Exactly one of *CreativeGroup or error will be non-nil. Any non-2xx
27650// status code is an error. Response headers are in either
27651// *CreativeGroup.ServerResponse.Header or (if a response was returned
27652// at all) in error.(*googleapi.Error).Header. Use
27653// googleapi.IsNotModified to check whether the returned error was
27654// because http.StatusNotModified was returned.
27655func (c *CreativeGroupsPatchCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27656	gensupport.SetOptions(c.urlParams_, opts...)
27657	res, err := c.doRequest("json")
27658	if res != nil && res.StatusCode == http.StatusNotModified {
27659		if res.Body != nil {
27660			res.Body.Close()
27661		}
27662		return nil, &googleapi.Error{
27663			Code:   res.StatusCode,
27664			Header: res.Header,
27665		}
27666	}
27667	if err != nil {
27668		return nil, err
27669	}
27670	defer googleapi.CloseBody(res)
27671	if err := googleapi.CheckResponse(res); err != nil {
27672		return nil, err
27673	}
27674	ret := &CreativeGroup{
27675		ServerResponse: googleapi.ServerResponse{
27676			Header:         res.Header,
27677			HTTPStatusCode: res.StatusCode,
27678		},
27679	}
27680	target := &ret
27681	if err := gensupport.DecodeResponse(target, res); err != nil {
27682		return nil, err
27683	}
27684	return ret, nil
27685	// {
27686	//   "description": "Updates an existing creative group. This method supports patch semantics.",
27687	//   "httpMethod": "PATCH",
27688	//   "id": "dfareporting.creativeGroups.patch",
27689	//   "parameterOrder": [
27690	//     "profileId",
27691	//     "id"
27692	//   ],
27693	//   "parameters": {
27694	//     "id": {
27695	//       "description": "Creative group ID.",
27696	//       "format": "int64",
27697	//       "location": "query",
27698	//       "required": true,
27699	//       "type": "string"
27700	//     },
27701	//     "profileId": {
27702	//       "description": "User profile ID associated with this request.",
27703	//       "format": "int64",
27704	//       "location": "path",
27705	//       "required": true,
27706	//       "type": "string"
27707	//     }
27708	//   },
27709	//   "path": "userprofiles/{profileId}/creativeGroups",
27710	//   "request": {
27711	//     "$ref": "CreativeGroup"
27712	//   },
27713	//   "response": {
27714	//     "$ref": "CreativeGroup"
27715	//   },
27716	//   "scopes": [
27717	//     "https://www.googleapis.com/auth/dfatrafficking"
27718	//   ]
27719	// }
27720
27721}
27722
27723// method id "dfareporting.creativeGroups.update":
27724
27725type CreativeGroupsUpdateCall struct {
27726	s             *Service
27727	profileId     int64
27728	creativegroup *CreativeGroup
27729	urlParams_    gensupport.URLParams
27730	ctx_          context.Context
27731	header_       http.Header
27732}
27733
27734// Update: Updates an existing creative group.
27735func (r *CreativeGroupsService) Update(profileId int64, creativegroup *CreativeGroup) *CreativeGroupsUpdateCall {
27736	c := &CreativeGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27737	c.profileId = profileId
27738	c.creativegroup = creativegroup
27739	return c
27740}
27741
27742// Fields allows partial responses to be retrieved. See
27743// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27744// for more information.
27745func (c *CreativeGroupsUpdateCall) Fields(s ...googleapi.Field) *CreativeGroupsUpdateCall {
27746	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27747	return c
27748}
27749
27750// Context sets the context to be used in this call's Do method. Any
27751// pending HTTP request will be aborted if the provided context is
27752// canceled.
27753func (c *CreativeGroupsUpdateCall) Context(ctx context.Context) *CreativeGroupsUpdateCall {
27754	c.ctx_ = ctx
27755	return c
27756}
27757
27758// Header returns an http.Header that can be modified by the caller to
27759// add HTTP headers to the request.
27760func (c *CreativeGroupsUpdateCall) Header() http.Header {
27761	if c.header_ == nil {
27762		c.header_ = make(http.Header)
27763	}
27764	return c.header_
27765}
27766
27767func (c *CreativeGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
27768	reqHeaders := make(http.Header)
27769	for k, v := range c.header_ {
27770		reqHeaders[k] = v
27771	}
27772	reqHeaders.Set("User-Agent", c.s.userAgent())
27773	var body io.Reader = nil
27774	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27775	if err != nil {
27776		return nil, err
27777	}
27778	reqHeaders.Set("Content-Type", "application/json")
27779	c.urlParams_.Set("alt", alt)
27780	c.urlParams_.Set("prettyPrint", "false")
27781	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27782	urls += "?" + c.urlParams_.Encode()
27783	req, err := http.NewRequest("PUT", urls, body)
27784	if err != nil {
27785		return nil, err
27786	}
27787	req.Header = reqHeaders
27788	googleapi.Expand(req.URL, map[string]string{
27789		"profileId": strconv.FormatInt(c.profileId, 10),
27790	})
27791	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27792}
27793
27794// Do executes the "dfareporting.creativeGroups.update" call.
27795// Exactly one of *CreativeGroup or error will be non-nil. Any non-2xx
27796// status code is an error. Response headers are in either
27797// *CreativeGroup.ServerResponse.Header or (if a response was returned
27798// at all) in error.(*googleapi.Error).Header. Use
27799// googleapi.IsNotModified to check whether the returned error was
27800// because http.StatusNotModified was returned.
27801func (c *CreativeGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27802	gensupport.SetOptions(c.urlParams_, opts...)
27803	res, err := c.doRequest("json")
27804	if res != nil && res.StatusCode == http.StatusNotModified {
27805		if res.Body != nil {
27806			res.Body.Close()
27807		}
27808		return nil, &googleapi.Error{
27809			Code:   res.StatusCode,
27810			Header: res.Header,
27811		}
27812	}
27813	if err != nil {
27814		return nil, err
27815	}
27816	defer googleapi.CloseBody(res)
27817	if err := googleapi.CheckResponse(res); err != nil {
27818		return nil, err
27819	}
27820	ret := &CreativeGroup{
27821		ServerResponse: googleapi.ServerResponse{
27822			Header:         res.Header,
27823			HTTPStatusCode: res.StatusCode,
27824		},
27825	}
27826	target := &ret
27827	if err := gensupport.DecodeResponse(target, res); err != nil {
27828		return nil, err
27829	}
27830	return ret, nil
27831	// {
27832	//   "description": "Updates an existing creative group.",
27833	//   "httpMethod": "PUT",
27834	//   "id": "dfareporting.creativeGroups.update",
27835	//   "parameterOrder": [
27836	//     "profileId"
27837	//   ],
27838	//   "parameters": {
27839	//     "profileId": {
27840	//       "description": "User profile ID associated with this request.",
27841	//       "format": "int64",
27842	//       "location": "path",
27843	//       "required": true,
27844	//       "type": "string"
27845	//     }
27846	//   },
27847	//   "path": "userprofiles/{profileId}/creativeGroups",
27848	//   "request": {
27849	//     "$ref": "CreativeGroup"
27850	//   },
27851	//   "response": {
27852	//     "$ref": "CreativeGroup"
27853	//   },
27854	//   "scopes": [
27855	//     "https://www.googleapis.com/auth/dfatrafficking"
27856	//   ]
27857	// }
27858
27859}
27860
27861// method id "dfareporting.creatives.get":
27862
27863type CreativesGetCall struct {
27864	s            *Service
27865	profileId    int64
27866	id           int64
27867	urlParams_   gensupport.URLParams
27868	ifNoneMatch_ string
27869	ctx_         context.Context
27870	header_      http.Header
27871}
27872
27873// Get: Gets one creative by ID.
27874func (r *CreativesService) Get(profileId int64, id int64) *CreativesGetCall {
27875	c := &CreativesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27876	c.profileId = profileId
27877	c.id = id
27878	return c
27879}
27880
27881// Fields allows partial responses to be retrieved. See
27882// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27883// for more information.
27884func (c *CreativesGetCall) Fields(s ...googleapi.Field) *CreativesGetCall {
27885	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27886	return c
27887}
27888
27889// IfNoneMatch sets the optional parameter which makes the operation
27890// fail if the object's ETag matches the given value. This is useful for
27891// getting updates only after the object has changed since the last
27892// request. Use googleapi.IsNotModified to check whether the response
27893// error from Do is the result of In-None-Match.
27894func (c *CreativesGetCall) IfNoneMatch(entityTag string) *CreativesGetCall {
27895	c.ifNoneMatch_ = entityTag
27896	return c
27897}
27898
27899// Context sets the context to be used in this call's Do method. Any
27900// pending HTTP request will be aborted if the provided context is
27901// canceled.
27902func (c *CreativesGetCall) Context(ctx context.Context) *CreativesGetCall {
27903	c.ctx_ = ctx
27904	return c
27905}
27906
27907// Header returns an http.Header that can be modified by the caller to
27908// add HTTP headers to the request.
27909func (c *CreativesGetCall) Header() http.Header {
27910	if c.header_ == nil {
27911		c.header_ = make(http.Header)
27912	}
27913	return c.header_
27914}
27915
27916func (c *CreativesGetCall) doRequest(alt string) (*http.Response, error) {
27917	reqHeaders := make(http.Header)
27918	for k, v := range c.header_ {
27919		reqHeaders[k] = v
27920	}
27921	reqHeaders.Set("User-Agent", c.s.userAgent())
27922	if c.ifNoneMatch_ != "" {
27923		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27924	}
27925	var body io.Reader = nil
27926	c.urlParams_.Set("alt", alt)
27927	c.urlParams_.Set("prettyPrint", "false")
27928	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives/{id}")
27929	urls += "?" + c.urlParams_.Encode()
27930	req, err := http.NewRequest("GET", urls, body)
27931	if err != nil {
27932		return nil, err
27933	}
27934	req.Header = reqHeaders
27935	googleapi.Expand(req.URL, map[string]string{
27936		"profileId": strconv.FormatInt(c.profileId, 10),
27937		"id":        strconv.FormatInt(c.id, 10),
27938	})
27939	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27940}
27941
27942// Do executes the "dfareporting.creatives.get" call.
27943// Exactly one of *Creative or error will be non-nil. Any non-2xx status
27944// code is an error. Response headers are in either
27945// *Creative.ServerResponse.Header or (if a response was returned at
27946// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
27947// to check whether the returned error was because
27948// http.StatusNotModified was returned.
27949func (c *CreativesGetCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
27950	gensupport.SetOptions(c.urlParams_, opts...)
27951	res, err := c.doRequest("json")
27952	if res != nil && res.StatusCode == http.StatusNotModified {
27953		if res.Body != nil {
27954			res.Body.Close()
27955		}
27956		return nil, &googleapi.Error{
27957			Code:   res.StatusCode,
27958			Header: res.Header,
27959		}
27960	}
27961	if err != nil {
27962		return nil, err
27963	}
27964	defer googleapi.CloseBody(res)
27965	if err := googleapi.CheckResponse(res); err != nil {
27966		return nil, err
27967	}
27968	ret := &Creative{
27969		ServerResponse: googleapi.ServerResponse{
27970			Header:         res.Header,
27971			HTTPStatusCode: res.StatusCode,
27972		},
27973	}
27974	target := &ret
27975	if err := gensupport.DecodeResponse(target, res); err != nil {
27976		return nil, err
27977	}
27978	return ret, nil
27979	// {
27980	//   "description": "Gets one creative by ID.",
27981	//   "httpMethod": "GET",
27982	//   "id": "dfareporting.creatives.get",
27983	//   "parameterOrder": [
27984	//     "profileId",
27985	//     "id"
27986	//   ],
27987	//   "parameters": {
27988	//     "id": {
27989	//       "description": "Creative ID.",
27990	//       "format": "int64",
27991	//       "location": "path",
27992	//       "required": true,
27993	//       "type": "string"
27994	//     },
27995	//     "profileId": {
27996	//       "description": "User profile ID associated with this request.",
27997	//       "format": "int64",
27998	//       "location": "path",
27999	//       "required": true,
28000	//       "type": "string"
28001	//     }
28002	//   },
28003	//   "path": "userprofiles/{profileId}/creatives/{id}",
28004	//   "response": {
28005	//     "$ref": "Creative"
28006	//   },
28007	//   "scopes": [
28008	//     "https://www.googleapis.com/auth/dfatrafficking"
28009	//   ]
28010	// }
28011
28012}
28013
28014// method id "dfareporting.creatives.insert":
28015
28016type CreativesInsertCall struct {
28017	s          *Service
28018	profileId  int64
28019	creative   *Creative
28020	urlParams_ gensupport.URLParams
28021	ctx_       context.Context
28022	header_    http.Header
28023}
28024
28025// Insert: Inserts a new creative.
28026func (r *CreativesService) Insert(profileId int64, creative *Creative) *CreativesInsertCall {
28027	c := &CreativesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28028	c.profileId = profileId
28029	c.creative = creative
28030	return c
28031}
28032
28033// Fields allows partial responses to be retrieved. See
28034// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28035// for more information.
28036func (c *CreativesInsertCall) Fields(s ...googleapi.Field) *CreativesInsertCall {
28037	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28038	return c
28039}
28040
28041// Context sets the context to be used in this call's Do method. Any
28042// pending HTTP request will be aborted if the provided context is
28043// canceled.
28044func (c *CreativesInsertCall) Context(ctx context.Context) *CreativesInsertCall {
28045	c.ctx_ = ctx
28046	return c
28047}
28048
28049// Header returns an http.Header that can be modified by the caller to
28050// add HTTP headers to the request.
28051func (c *CreativesInsertCall) Header() http.Header {
28052	if c.header_ == nil {
28053		c.header_ = make(http.Header)
28054	}
28055	return c.header_
28056}
28057
28058func (c *CreativesInsertCall) doRequest(alt string) (*http.Response, error) {
28059	reqHeaders := make(http.Header)
28060	for k, v := range c.header_ {
28061		reqHeaders[k] = v
28062	}
28063	reqHeaders.Set("User-Agent", c.s.userAgent())
28064	var body io.Reader = nil
28065	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
28066	if err != nil {
28067		return nil, err
28068	}
28069	reqHeaders.Set("Content-Type", "application/json")
28070	c.urlParams_.Set("alt", alt)
28071	c.urlParams_.Set("prettyPrint", "false")
28072	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28073	urls += "?" + c.urlParams_.Encode()
28074	req, err := http.NewRequest("POST", urls, body)
28075	if err != nil {
28076		return nil, err
28077	}
28078	req.Header = reqHeaders
28079	googleapi.Expand(req.URL, map[string]string{
28080		"profileId": strconv.FormatInt(c.profileId, 10),
28081	})
28082	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28083}
28084
28085// Do executes the "dfareporting.creatives.insert" call.
28086// Exactly one of *Creative or error will be non-nil. Any non-2xx status
28087// code is an error. Response headers are in either
28088// *Creative.ServerResponse.Header or (if a response was returned at
28089// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
28090// to check whether the returned error was because
28091// http.StatusNotModified was returned.
28092func (c *CreativesInsertCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28093	gensupport.SetOptions(c.urlParams_, opts...)
28094	res, err := c.doRequest("json")
28095	if res != nil && res.StatusCode == http.StatusNotModified {
28096		if res.Body != nil {
28097			res.Body.Close()
28098		}
28099		return nil, &googleapi.Error{
28100			Code:   res.StatusCode,
28101			Header: res.Header,
28102		}
28103	}
28104	if err != nil {
28105		return nil, err
28106	}
28107	defer googleapi.CloseBody(res)
28108	if err := googleapi.CheckResponse(res); err != nil {
28109		return nil, err
28110	}
28111	ret := &Creative{
28112		ServerResponse: googleapi.ServerResponse{
28113			Header:         res.Header,
28114			HTTPStatusCode: res.StatusCode,
28115		},
28116	}
28117	target := &ret
28118	if err := gensupport.DecodeResponse(target, res); err != nil {
28119		return nil, err
28120	}
28121	return ret, nil
28122	// {
28123	//   "description": "Inserts a new creative.",
28124	//   "httpMethod": "POST",
28125	//   "id": "dfareporting.creatives.insert",
28126	//   "parameterOrder": [
28127	//     "profileId"
28128	//   ],
28129	//   "parameters": {
28130	//     "profileId": {
28131	//       "description": "User profile ID associated with this request.",
28132	//       "format": "int64",
28133	//       "location": "path",
28134	//       "required": true,
28135	//       "type": "string"
28136	//     }
28137	//   },
28138	//   "path": "userprofiles/{profileId}/creatives",
28139	//   "request": {
28140	//     "$ref": "Creative"
28141	//   },
28142	//   "response": {
28143	//     "$ref": "Creative"
28144	//   },
28145	//   "scopes": [
28146	//     "https://www.googleapis.com/auth/dfatrafficking"
28147	//   ]
28148	// }
28149
28150}
28151
28152// method id "dfareporting.creatives.list":
28153
28154type CreativesListCall struct {
28155	s            *Service
28156	profileId    int64
28157	urlParams_   gensupport.URLParams
28158	ifNoneMatch_ string
28159	ctx_         context.Context
28160	header_      http.Header
28161}
28162
28163// List: Retrieves a list of creatives, possibly filtered. This method
28164// supports paging.
28165func (r *CreativesService) List(profileId int64) *CreativesListCall {
28166	c := &CreativesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28167	c.profileId = profileId
28168	return c
28169}
28170
28171// Active sets the optional parameter "active": Select only active
28172// creatives. Leave blank to select active and inactive creatives.
28173func (c *CreativesListCall) Active(active bool) *CreativesListCall {
28174	c.urlParams_.Set("active", fmt.Sprint(active))
28175	return c
28176}
28177
28178// AdvertiserId sets the optional parameter "advertiserId": Select only
28179// creatives with this advertiser ID.
28180func (c *CreativesListCall) AdvertiserId(advertiserId int64) *CreativesListCall {
28181	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
28182	return c
28183}
28184
28185// Archived sets the optional parameter "archived": Select only archived
28186// creatives. Leave blank to select archived and unarchived creatives.
28187func (c *CreativesListCall) Archived(archived bool) *CreativesListCall {
28188	c.urlParams_.Set("archived", fmt.Sprint(archived))
28189	return c
28190}
28191
28192// CampaignId sets the optional parameter "campaignId": Select only
28193// creatives with this campaign ID.
28194func (c *CreativesListCall) CampaignId(campaignId int64) *CreativesListCall {
28195	c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
28196	return c
28197}
28198
28199// CompanionCreativeIds sets the optional parameter
28200// "companionCreativeIds": Select only in-stream video creatives with
28201// these companion IDs.
28202func (c *CreativesListCall) CompanionCreativeIds(companionCreativeIds ...int64) *CreativesListCall {
28203	var companionCreativeIds_ []string
28204	for _, v := range companionCreativeIds {
28205		companionCreativeIds_ = append(companionCreativeIds_, fmt.Sprint(v))
28206	}
28207	c.urlParams_.SetMulti("companionCreativeIds", companionCreativeIds_)
28208	return c
28209}
28210
28211// CreativeFieldIds sets the optional parameter "creativeFieldIds":
28212// Select only creatives with these creative field IDs.
28213func (c *CreativesListCall) CreativeFieldIds(creativeFieldIds ...int64) *CreativesListCall {
28214	var creativeFieldIds_ []string
28215	for _, v := range creativeFieldIds {
28216		creativeFieldIds_ = append(creativeFieldIds_, fmt.Sprint(v))
28217	}
28218	c.urlParams_.SetMulti("creativeFieldIds", creativeFieldIds_)
28219	return c
28220}
28221
28222// Ids sets the optional parameter "ids": Select only creatives with
28223// these IDs.
28224func (c *CreativesListCall) Ids(ids ...int64) *CreativesListCall {
28225	var ids_ []string
28226	for _, v := range ids {
28227		ids_ = append(ids_, fmt.Sprint(v))
28228	}
28229	c.urlParams_.SetMulti("ids", ids_)
28230	return c
28231}
28232
28233// MaxResults sets the optional parameter "maxResults": Maximum number
28234// of results to return.
28235func (c *CreativesListCall) MaxResults(maxResults int64) *CreativesListCall {
28236	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
28237	return c
28238}
28239
28240// PageToken sets the optional parameter "pageToken": Value of the
28241// nextPageToken from the previous result page.
28242func (c *CreativesListCall) PageToken(pageToken string) *CreativesListCall {
28243	c.urlParams_.Set("pageToken", pageToken)
28244	return c
28245}
28246
28247// RenderingIds sets the optional parameter "renderingIds": Select only
28248// creatives with these rendering IDs.
28249func (c *CreativesListCall) RenderingIds(renderingIds ...int64) *CreativesListCall {
28250	var renderingIds_ []string
28251	for _, v := range renderingIds {
28252		renderingIds_ = append(renderingIds_, fmt.Sprint(v))
28253	}
28254	c.urlParams_.SetMulti("renderingIds", renderingIds_)
28255	return c
28256}
28257
28258// SearchString sets the optional parameter "searchString": Allows
28259// searching for objects by name or ID. Wildcards (*) are allowed. For
28260// example, "creative*2015" will return objects with names like
28261// "creative June 2015", "creative April 2015", or simply "creative
28262// 2015". Most of the searches also add wildcards implicitly at the
28263// start and the end of the search string. For example, a search string
28264// of "creative" will match objects with name "my creative", "creative
28265// 2015", or simply "creative".
28266func (c *CreativesListCall) SearchString(searchString string) *CreativesListCall {
28267	c.urlParams_.Set("searchString", searchString)
28268	return c
28269}
28270
28271// SizeIds sets the optional parameter "sizeIds": Select only creatives
28272// with these size IDs.
28273func (c *CreativesListCall) SizeIds(sizeIds ...int64) *CreativesListCall {
28274	var sizeIds_ []string
28275	for _, v := range sizeIds {
28276		sizeIds_ = append(sizeIds_, fmt.Sprint(v))
28277	}
28278	c.urlParams_.SetMulti("sizeIds", sizeIds_)
28279	return c
28280}
28281
28282// SortField sets the optional parameter "sortField": Field by which to
28283// sort the list.
28284//
28285// Possible values:
28286//   "ID" (default)
28287//   "NAME"
28288func (c *CreativesListCall) SortField(sortField string) *CreativesListCall {
28289	c.urlParams_.Set("sortField", sortField)
28290	return c
28291}
28292
28293// SortOrder sets the optional parameter "sortOrder": Order of sorted
28294// results.
28295//
28296// Possible values:
28297//   "ASCENDING" (default)
28298//   "DESCENDING"
28299func (c *CreativesListCall) SortOrder(sortOrder string) *CreativesListCall {
28300	c.urlParams_.Set("sortOrder", sortOrder)
28301	return c
28302}
28303
28304// StudioCreativeId sets the optional parameter "studioCreativeId":
28305// Select only creatives corresponding to this Studio creative ID.
28306func (c *CreativesListCall) StudioCreativeId(studioCreativeId int64) *CreativesListCall {
28307	c.urlParams_.Set("studioCreativeId", fmt.Sprint(studioCreativeId))
28308	return c
28309}
28310
28311// Types sets the optional parameter "types": Select only creatives with
28312// these creative types.
28313//
28314// Possible values:
28315//   "BRAND_SAFE_DEFAULT_INSTREAM_VIDEO"
28316//   "CUSTOM_DISPLAY"
28317//   "CUSTOM_DISPLAY_INTERSTITIAL"
28318//   "DISPLAY"
28319//   "DISPLAY_IMAGE_GALLERY"
28320//   "DISPLAY_REDIRECT"
28321//   "FLASH_INPAGE"
28322//   "HTML5_BANNER"
28323//   "IMAGE"
28324//   "INSTREAM_AUDIO"
28325//   "INSTREAM_VIDEO"
28326//   "INSTREAM_VIDEO_REDIRECT"
28327//   "INTERNAL_REDIRECT"
28328//   "INTERSTITIAL_INTERNAL_REDIRECT"
28329//   "RICH_MEDIA_DISPLAY_BANNER"
28330//   "RICH_MEDIA_DISPLAY_EXPANDING"
28331//   "RICH_MEDIA_DISPLAY_INTERSTITIAL"
28332//   "RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL"
28333//   "RICH_MEDIA_IM_EXPAND"
28334//   "RICH_MEDIA_INPAGE_FLOATING"
28335//   "RICH_MEDIA_MOBILE_IN_APP"
28336//   "RICH_MEDIA_PEEL_DOWN"
28337//   "TRACKING_TEXT"
28338//   "VPAID_LINEAR_VIDEO"
28339//   "VPAID_NON_LINEAR_VIDEO"
28340func (c *CreativesListCall) Types(types ...string) *CreativesListCall {
28341	c.urlParams_.SetMulti("types", append([]string{}, types...))
28342	return c
28343}
28344
28345// Fields allows partial responses to be retrieved. See
28346// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28347// for more information.
28348func (c *CreativesListCall) Fields(s ...googleapi.Field) *CreativesListCall {
28349	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28350	return c
28351}
28352
28353// IfNoneMatch sets the optional parameter which makes the operation
28354// fail if the object's ETag matches the given value. This is useful for
28355// getting updates only after the object has changed since the last
28356// request. Use googleapi.IsNotModified to check whether the response
28357// error from Do is the result of In-None-Match.
28358func (c *CreativesListCall) IfNoneMatch(entityTag string) *CreativesListCall {
28359	c.ifNoneMatch_ = entityTag
28360	return c
28361}
28362
28363// Context sets the context to be used in this call's Do method. Any
28364// pending HTTP request will be aborted if the provided context is
28365// canceled.
28366func (c *CreativesListCall) Context(ctx context.Context) *CreativesListCall {
28367	c.ctx_ = ctx
28368	return c
28369}
28370
28371// Header returns an http.Header that can be modified by the caller to
28372// add HTTP headers to the request.
28373func (c *CreativesListCall) Header() http.Header {
28374	if c.header_ == nil {
28375		c.header_ = make(http.Header)
28376	}
28377	return c.header_
28378}
28379
28380func (c *CreativesListCall) doRequest(alt string) (*http.Response, error) {
28381	reqHeaders := make(http.Header)
28382	for k, v := range c.header_ {
28383		reqHeaders[k] = v
28384	}
28385	reqHeaders.Set("User-Agent", c.s.userAgent())
28386	if c.ifNoneMatch_ != "" {
28387		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28388	}
28389	var body io.Reader = nil
28390	c.urlParams_.Set("alt", alt)
28391	c.urlParams_.Set("prettyPrint", "false")
28392	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28393	urls += "?" + c.urlParams_.Encode()
28394	req, err := http.NewRequest("GET", urls, body)
28395	if err != nil {
28396		return nil, err
28397	}
28398	req.Header = reqHeaders
28399	googleapi.Expand(req.URL, map[string]string{
28400		"profileId": strconv.FormatInt(c.profileId, 10),
28401	})
28402	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28403}
28404
28405// Do executes the "dfareporting.creatives.list" call.
28406// Exactly one of *CreativesListResponse or error will be non-nil. Any
28407// non-2xx status code is an error. Response headers are in either
28408// *CreativesListResponse.ServerResponse.Header or (if a response was
28409// returned at all) in error.(*googleapi.Error).Header. Use
28410// googleapi.IsNotModified to check whether the returned error was
28411// because http.StatusNotModified was returned.
28412func (c *CreativesListCall) Do(opts ...googleapi.CallOption) (*CreativesListResponse, error) {
28413	gensupport.SetOptions(c.urlParams_, opts...)
28414	res, err := c.doRequest("json")
28415	if res != nil && res.StatusCode == http.StatusNotModified {
28416		if res.Body != nil {
28417			res.Body.Close()
28418		}
28419		return nil, &googleapi.Error{
28420			Code:   res.StatusCode,
28421			Header: res.Header,
28422		}
28423	}
28424	if err != nil {
28425		return nil, err
28426	}
28427	defer googleapi.CloseBody(res)
28428	if err := googleapi.CheckResponse(res); err != nil {
28429		return nil, err
28430	}
28431	ret := &CreativesListResponse{
28432		ServerResponse: googleapi.ServerResponse{
28433			Header:         res.Header,
28434			HTTPStatusCode: res.StatusCode,
28435		},
28436	}
28437	target := &ret
28438	if err := gensupport.DecodeResponse(target, res); err != nil {
28439		return nil, err
28440	}
28441	return ret, nil
28442	// {
28443	//   "description": "Retrieves a list of creatives, possibly filtered. This method supports paging.",
28444	//   "httpMethod": "GET",
28445	//   "id": "dfareporting.creatives.list",
28446	//   "parameterOrder": [
28447	//     "profileId"
28448	//   ],
28449	//   "parameters": {
28450	//     "active": {
28451	//       "description": "Select only active creatives. Leave blank to select active and inactive creatives.",
28452	//       "location": "query",
28453	//       "type": "boolean"
28454	//     },
28455	//     "advertiserId": {
28456	//       "description": "Select only creatives with this advertiser ID.",
28457	//       "format": "int64",
28458	//       "location": "query",
28459	//       "type": "string"
28460	//     },
28461	//     "archived": {
28462	//       "description": "Select only archived creatives. Leave blank to select archived and unarchived creatives.",
28463	//       "location": "query",
28464	//       "type": "boolean"
28465	//     },
28466	//     "campaignId": {
28467	//       "description": "Select only creatives with this campaign ID.",
28468	//       "format": "int64",
28469	//       "location": "query",
28470	//       "type": "string"
28471	//     },
28472	//     "companionCreativeIds": {
28473	//       "description": "Select only in-stream video creatives with these companion IDs.",
28474	//       "format": "int64",
28475	//       "location": "query",
28476	//       "repeated": true,
28477	//       "type": "string"
28478	//     },
28479	//     "creativeFieldIds": {
28480	//       "description": "Select only creatives with these creative field IDs.",
28481	//       "format": "int64",
28482	//       "location": "query",
28483	//       "repeated": true,
28484	//       "type": "string"
28485	//     },
28486	//     "ids": {
28487	//       "description": "Select only creatives with these IDs.",
28488	//       "format": "int64",
28489	//       "location": "query",
28490	//       "repeated": true,
28491	//       "type": "string"
28492	//     },
28493	//     "maxResults": {
28494	//       "default": "1000",
28495	//       "description": "Maximum number of results to return.",
28496	//       "format": "int32",
28497	//       "location": "query",
28498	//       "maximum": "1000",
28499	//       "minimum": "0",
28500	//       "type": "integer"
28501	//     },
28502	//     "pageToken": {
28503	//       "description": "Value of the nextPageToken from the previous result page.",
28504	//       "location": "query",
28505	//       "type": "string"
28506	//     },
28507	//     "profileId": {
28508	//       "description": "User profile ID associated with this request.",
28509	//       "format": "int64",
28510	//       "location": "path",
28511	//       "required": true,
28512	//       "type": "string"
28513	//     },
28514	//     "renderingIds": {
28515	//       "description": "Select only creatives with these rendering IDs.",
28516	//       "format": "int64",
28517	//       "location": "query",
28518	//       "repeated": true,
28519	//       "type": "string"
28520	//     },
28521	//     "searchString": {
28522	//       "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\".",
28523	//       "location": "query",
28524	//       "type": "string"
28525	//     },
28526	//     "sizeIds": {
28527	//       "description": "Select only creatives with these size IDs.",
28528	//       "format": "int64",
28529	//       "location": "query",
28530	//       "repeated": true,
28531	//       "type": "string"
28532	//     },
28533	//     "sortField": {
28534	//       "default": "ID",
28535	//       "description": "Field by which to sort the list.",
28536	//       "enum": [
28537	//         "ID",
28538	//         "NAME"
28539	//       ],
28540	//       "enumDescriptions": [
28541	//         "",
28542	//         ""
28543	//       ],
28544	//       "location": "query",
28545	//       "type": "string"
28546	//     },
28547	//     "sortOrder": {
28548	//       "default": "ASCENDING",
28549	//       "description": "Order of sorted results.",
28550	//       "enum": [
28551	//         "ASCENDING",
28552	//         "DESCENDING"
28553	//       ],
28554	//       "enumDescriptions": [
28555	//         "",
28556	//         ""
28557	//       ],
28558	//       "location": "query",
28559	//       "type": "string"
28560	//     },
28561	//     "studioCreativeId": {
28562	//       "description": "Select only creatives corresponding to this Studio creative ID.",
28563	//       "format": "int64",
28564	//       "location": "query",
28565	//       "type": "string"
28566	//     },
28567	//     "types": {
28568	//       "description": "Select only creatives with these creative types.",
28569	//       "enum": [
28570	//         "BRAND_SAFE_DEFAULT_INSTREAM_VIDEO",
28571	//         "CUSTOM_DISPLAY",
28572	//         "CUSTOM_DISPLAY_INTERSTITIAL",
28573	//         "DISPLAY",
28574	//         "DISPLAY_IMAGE_GALLERY",
28575	//         "DISPLAY_REDIRECT",
28576	//         "FLASH_INPAGE",
28577	//         "HTML5_BANNER",
28578	//         "IMAGE",
28579	//         "INSTREAM_AUDIO",
28580	//         "INSTREAM_VIDEO",
28581	//         "INSTREAM_VIDEO_REDIRECT",
28582	//         "INTERNAL_REDIRECT",
28583	//         "INTERSTITIAL_INTERNAL_REDIRECT",
28584	//         "RICH_MEDIA_DISPLAY_BANNER",
28585	//         "RICH_MEDIA_DISPLAY_EXPANDING",
28586	//         "RICH_MEDIA_DISPLAY_INTERSTITIAL",
28587	//         "RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL",
28588	//         "RICH_MEDIA_IM_EXPAND",
28589	//         "RICH_MEDIA_INPAGE_FLOATING",
28590	//         "RICH_MEDIA_MOBILE_IN_APP",
28591	//         "RICH_MEDIA_PEEL_DOWN",
28592	//         "TRACKING_TEXT",
28593	//         "VPAID_LINEAR_VIDEO",
28594	//         "VPAID_NON_LINEAR_VIDEO"
28595	//       ],
28596	//       "enumDescriptions": [
28597	//         "",
28598	//         "",
28599	//         "",
28600	//         "",
28601	//         "",
28602	//         "",
28603	//         "",
28604	//         "",
28605	//         "",
28606	//         "",
28607	//         "",
28608	//         "",
28609	//         "",
28610	//         "",
28611	//         "",
28612	//         "",
28613	//         "",
28614	//         "",
28615	//         "",
28616	//         "",
28617	//         "",
28618	//         "",
28619	//         "",
28620	//         "",
28621	//         ""
28622	//       ],
28623	//       "location": "query",
28624	//       "repeated": true,
28625	//       "type": "string"
28626	//     }
28627	//   },
28628	//   "path": "userprofiles/{profileId}/creatives",
28629	//   "response": {
28630	//     "$ref": "CreativesListResponse"
28631	//   },
28632	//   "scopes": [
28633	//     "https://www.googleapis.com/auth/dfatrafficking"
28634	//   ]
28635	// }
28636
28637}
28638
28639// Pages invokes f for each page of results.
28640// A non-nil error returned from f will halt the iteration.
28641// The provided context supersedes any context provided to the Context method.
28642func (c *CreativesListCall) Pages(ctx context.Context, f func(*CreativesListResponse) error) error {
28643	c.ctx_ = ctx
28644	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
28645	for {
28646		x, err := c.Do()
28647		if err != nil {
28648			return err
28649		}
28650		if err := f(x); err != nil {
28651			return err
28652		}
28653		if x.NextPageToken == "" {
28654			return nil
28655		}
28656		c.PageToken(x.NextPageToken)
28657	}
28658}
28659
28660// method id "dfareporting.creatives.patch":
28661
28662type CreativesPatchCall struct {
28663	s          *Service
28664	profileId  int64
28665	creative   *Creative
28666	urlParams_ gensupport.URLParams
28667	ctx_       context.Context
28668	header_    http.Header
28669}
28670
28671// Patch: Updates an existing creative. This method supports patch
28672// semantics.
28673func (r *CreativesService) Patch(profileId int64, id int64, creative *Creative) *CreativesPatchCall {
28674	c := &CreativesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28675	c.profileId = profileId
28676	c.urlParams_.Set("id", fmt.Sprint(id))
28677	c.creative = creative
28678	return c
28679}
28680
28681// Fields allows partial responses to be retrieved. See
28682// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28683// for more information.
28684func (c *CreativesPatchCall) Fields(s ...googleapi.Field) *CreativesPatchCall {
28685	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28686	return c
28687}
28688
28689// Context sets the context to be used in this call's Do method. Any
28690// pending HTTP request will be aborted if the provided context is
28691// canceled.
28692func (c *CreativesPatchCall) Context(ctx context.Context) *CreativesPatchCall {
28693	c.ctx_ = ctx
28694	return c
28695}
28696
28697// Header returns an http.Header that can be modified by the caller to
28698// add HTTP headers to the request.
28699func (c *CreativesPatchCall) Header() http.Header {
28700	if c.header_ == nil {
28701		c.header_ = make(http.Header)
28702	}
28703	return c.header_
28704}
28705
28706func (c *CreativesPatchCall) doRequest(alt string) (*http.Response, error) {
28707	reqHeaders := make(http.Header)
28708	for k, v := range c.header_ {
28709		reqHeaders[k] = v
28710	}
28711	reqHeaders.Set("User-Agent", c.s.userAgent())
28712	var body io.Reader = nil
28713	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
28714	if err != nil {
28715		return nil, err
28716	}
28717	reqHeaders.Set("Content-Type", "application/json")
28718	c.urlParams_.Set("alt", alt)
28719	c.urlParams_.Set("prettyPrint", "false")
28720	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28721	urls += "?" + c.urlParams_.Encode()
28722	req, err := http.NewRequest("PATCH", urls, body)
28723	if err != nil {
28724		return nil, err
28725	}
28726	req.Header = reqHeaders
28727	googleapi.Expand(req.URL, map[string]string{
28728		"profileId": strconv.FormatInt(c.profileId, 10),
28729	})
28730	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28731}
28732
28733// Do executes the "dfareporting.creatives.patch" call.
28734// Exactly one of *Creative or error will be non-nil. Any non-2xx status
28735// code is an error. Response headers are in either
28736// *Creative.ServerResponse.Header or (if a response was returned at
28737// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
28738// to check whether the returned error was because
28739// http.StatusNotModified was returned.
28740func (c *CreativesPatchCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28741	gensupport.SetOptions(c.urlParams_, opts...)
28742	res, err := c.doRequest("json")
28743	if res != nil && res.StatusCode == http.StatusNotModified {
28744		if res.Body != nil {
28745			res.Body.Close()
28746		}
28747		return nil, &googleapi.Error{
28748			Code:   res.StatusCode,
28749			Header: res.Header,
28750		}
28751	}
28752	if err != nil {
28753		return nil, err
28754	}
28755	defer googleapi.CloseBody(res)
28756	if err := googleapi.CheckResponse(res); err != nil {
28757		return nil, err
28758	}
28759	ret := &Creative{
28760		ServerResponse: googleapi.ServerResponse{
28761			Header:         res.Header,
28762			HTTPStatusCode: res.StatusCode,
28763		},
28764	}
28765	target := &ret
28766	if err := gensupport.DecodeResponse(target, res); err != nil {
28767		return nil, err
28768	}
28769	return ret, nil
28770	// {
28771	//   "description": "Updates an existing creative. This method supports patch semantics.",
28772	//   "httpMethod": "PATCH",
28773	//   "id": "dfareporting.creatives.patch",
28774	//   "parameterOrder": [
28775	//     "profileId",
28776	//     "id"
28777	//   ],
28778	//   "parameters": {
28779	//     "id": {
28780	//       "description": "Creative ID.",
28781	//       "format": "int64",
28782	//       "location": "query",
28783	//       "required": true,
28784	//       "type": "string"
28785	//     },
28786	//     "profileId": {
28787	//       "description": "User profile ID associated with this request.",
28788	//       "format": "int64",
28789	//       "location": "path",
28790	//       "required": true,
28791	//       "type": "string"
28792	//     }
28793	//   },
28794	//   "path": "userprofiles/{profileId}/creatives",
28795	//   "request": {
28796	//     "$ref": "Creative"
28797	//   },
28798	//   "response": {
28799	//     "$ref": "Creative"
28800	//   },
28801	//   "scopes": [
28802	//     "https://www.googleapis.com/auth/dfatrafficking"
28803	//   ]
28804	// }
28805
28806}
28807
28808// method id "dfareporting.creatives.update":
28809
28810type CreativesUpdateCall struct {
28811	s          *Service
28812	profileId  int64
28813	creative   *Creative
28814	urlParams_ gensupport.URLParams
28815	ctx_       context.Context
28816	header_    http.Header
28817}
28818
28819// Update: Updates an existing creative.
28820func (r *CreativesService) Update(profileId int64, creative *Creative) *CreativesUpdateCall {
28821	c := &CreativesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28822	c.profileId = profileId
28823	c.creative = creative
28824	return c
28825}
28826
28827// Fields allows partial responses to be retrieved. See
28828// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28829// for more information.
28830func (c *CreativesUpdateCall) Fields(s ...googleapi.Field) *CreativesUpdateCall {
28831	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28832	return c
28833}
28834
28835// Context sets the context to be used in this call's Do method. Any
28836// pending HTTP request will be aborted if the provided context is
28837// canceled.
28838func (c *CreativesUpdateCall) Context(ctx context.Context) *CreativesUpdateCall {
28839	c.ctx_ = ctx
28840	return c
28841}
28842
28843// Header returns an http.Header that can be modified by the caller to
28844// add HTTP headers to the request.
28845func (c *CreativesUpdateCall) Header() http.Header {
28846	if c.header_ == nil {
28847		c.header_ = make(http.Header)
28848	}
28849	return c.header_
28850}
28851
28852func (c *CreativesUpdateCall) doRequest(alt string) (*http.Response, error) {
28853	reqHeaders := make(http.Header)
28854	for k, v := range c.header_ {
28855		reqHeaders[k] = v
28856	}
28857	reqHeaders.Set("User-Agent", c.s.userAgent())
28858	var body io.Reader = nil
28859	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
28860	if err != nil {
28861		return nil, err
28862	}
28863	reqHeaders.Set("Content-Type", "application/json")
28864	c.urlParams_.Set("alt", alt)
28865	c.urlParams_.Set("prettyPrint", "false")
28866	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28867	urls += "?" + c.urlParams_.Encode()
28868	req, err := http.NewRequest("PUT", urls, body)
28869	if err != nil {
28870		return nil, err
28871	}
28872	req.Header = reqHeaders
28873	googleapi.Expand(req.URL, map[string]string{
28874		"profileId": strconv.FormatInt(c.profileId, 10),
28875	})
28876	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28877}
28878
28879// Do executes the "dfareporting.creatives.update" call.
28880// Exactly one of *Creative or error will be non-nil. Any non-2xx status
28881// code is an error. Response headers are in either
28882// *Creative.ServerResponse.Header or (if a response was returned at
28883// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
28884// to check whether the returned error was because
28885// http.StatusNotModified was returned.
28886func (c *CreativesUpdateCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28887	gensupport.SetOptions(c.urlParams_, opts...)
28888	res, err := c.doRequest("json")
28889	if res != nil && res.StatusCode == http.StatusNotModified {
28890		if res.Body != nil {
28891			res.Body.Close()
28892		}
28893		return nil, &googleapi.Error{
28894			Code:   res.StatusCode,
28895			Header: res.Header,
28896		}
28897	}
28898	if err != nil {
28899		return nil, err
28900	}
28901	defer googleapi.CloseBody(res)
28902	if err := googleapi.CheckResponse(res); err != nil {
28903		return nil, err
28904	}
28905	ret := &Creative{
28906		ServerResponse: googleapi.ServerResponse{
28907			Header:         res.Header,
28908			HTTPStatusCode: res.StatusCode,
28909		},
28910	}
28911	target := &ret
28912	if err := gensupport.DecodeResponse(target, res); err != nil {
28913		return nil, err
28914	}
28915	return ret, nil
28916	// {
28917	//   "description": "Updates an existing creative.",
28918	//   "httpMethod": "PUT",
28919	//   "id": "dfareporting.creatives.update",
28920	//   "parameterOrder": [
28921	//     "profileId"
28922	//   ],
28923	//   "parameters": {
28924	//     "profileId": {
28925	//       "description": "User profile ID associated with this request.",
28926	//       "format": "int64",
28927	//       "location": "path",
28928	//       "required": true,
28929	//       "type": "string"
28930	//     }
28931	//   },
28932	//   "path": "userprofiles/{profileId}/creatives",
28933	//   "request": {
28934	//     "$ref": "Creative"
28935	//   },
28936	//   "response": {
28937	//     "$ref": "Creative"
28938	//   },
28939	//   "scopes": [
28940	//     "https://www.googleapis.com/auth/dfatrafficking"
28941	//   ]
28942	// }
28943
28944}
28945
28946// method id "dfareporting.dimensionValues.query":
28947
28948type DimensionValuesQueryCall struct {
28949	s                     *Service
28950	profileId             int64
28951	dimensionvaluerequest *DimensionValueRequest
28952	urlParams_            gensupport.URLParams
28953	ctx_                  context.Context
28954	header_               http.Header
28955}
28956
28957// Query: Retrieves list of report dimension values for a list of
28958// filters.
28959func (r *DimensionValuesService) Query(profileId int64, dimensionvaluerequest *DimensionValueRequest) *DimensionValuesQueryCall {
28960	c := &DimensionValuesQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28961	c.profileId = profileId
28962	c.dimensionvaluerequest = dimensionvaluerequest
28963	return c
28964}
28965
28966// MaxResults sets the optional parameter "maxResults": Maximum number
28967// of results to return.
28968func (c *DimensionValuesQueryCall) MaxResults(maxResults int64) *DimensionValuesQueryCall {
28969	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
28970	return c
28971}
28972
28973// PageToken sets the optional parameter "pageToken": The value of the
28974// nextToken from the previous result page.
28975func (c *DimensionValuesQueryCall) PageToken(pageToken string) *DimensionValuesQueryCall {
28976	c.urlParams_.Set("pageToken", pageToken)
28977	return c
28978}
28979
28980// Fields allows partial responses to be retrieved. See
28981// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28982// for more information.
28983func (c *DimensionValuesQueryCall) Fields(s ...googleapi.Field) *DimensionValuesQueryCall {
28984	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28985	return c
28986}
28987
28988// Context sets the context to be used in this call's Do method. Any
28989// pending HTTP request will be aborted if the provided context is
28990// canceled.
28991func (c *DimensionValuesQueryCall) Context(ctx context.Context) *DimensionValuesQueryCall {
28992	c.ctx_ = ctx
28993	return c
28994}
28995
28996// Header returns an http.Header that can be modified by the caller to
28997// add HTTP headers to the request.
28998func (c *DimensionValuesQueryCall) Header() http.Header {
28999	if c.header_ == nil {
29000		c.header_ = make(http.Header)
29001	}
29002	return c.header_
29003}
29004
29005func (c *DimensionValuesQueryCall) doRequest(alt string) (*http.Response, error) {
29006	reqHeaders := make(http.Header)
29007	for k, v := range c.header_ {
29008		reqHeaders[k] = v
29009	}
29010	reqHeaders.Set("User-Agent", c.s.userAgent())
29011	var body io.Reader = nil
29012	body, err := googleapi.WithoutDataWrapper.JSONReader(c.dimensionvaluerequest)
29013	if err != nil {
29014		return nil, err
29015	}
29016	reqHeaders.Set("Content-Type", "application/json")
29017	c.urlParams_.Set("alt", alt)
29018	c.urlParams_.Set("prettyPrint", "false")
29019	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dimensionvalues/query")
29020	urls += "?" + c.urlParams_.Encode()
29021	req, err := http.NewRequest("POST", urls, body)
29022	if err != nil {
29023		return nil, err
29024	}
29025	req.Header = reqHeaders
29026	googleapi.Expand(req.URL, map[string]string{
29027		"profileId": strconv.FormatInt(c.profileId, 10),
29028	})
29029	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29030}
29031
29032// Do executes the "dfareporting.dimensionValues.query" call.
29033// Exactly one of *DimensionValueList or error will be non-nil. Any
29034// non-2xx status code is an error. Response headers are in either
29035// *DimensionValueList.ServerResponse.Header or (if a response was
29036// returned at all) in error.(*googleapi.Error).Header. Use
29037// googleapi.IsNotModified to check whether the returned error was
29038// because http.StatusNotModified was returned.
29039func (c *DimensionValuesQueryCall) Do(opts ...googleapi.CallOption) (*DimensionValueList, error) {
29040	gensupport.SetOptions(c.urlParams_, opts...)
29041	res, err := c.doRequest("json")
29042	if res != nil && res.StatusCode == http.StatusNotModified {
29043		if res.Body != nil {
29044			res.Body.Close()
29045		}
29046		return nil, &googleapi.Error{
29047			Code:   res.StatusCode,
29048			Header: res.Header,
29049		}
29050	}
29051	if err != nil {
29052		return nil, err
29053	}
29054	defer googleapi.CloseBody(res)
29055	if err := googleapi.CheckResponse(res); err != nil {
29056		return nil, err
29057	}
29058	ret := &DimensionValueList{
29059		ServerResponse: googleapi.ServerResponse{
29060			Header:         res.Header,
29061			HTTPStatusCode: res.StatusCode,
29062		},
29063	}
29064	target := &ret
29065	if err := gensupport.DecodeResponse(target, res); err != nil {
29066		return nil, err
29067	}
29068	return ret, nil
29069	// {
29070	//   "description": "Retrieves list of report dimension values for a list of filters.",
29071	//   "httpMethod": "POST",
29072	//   "id": "dfareporting.dimensionValues.query",
29073	//   "parameterOrder": [
29074	//     "profileId"
29075	//   ],
29076	//   "parameters": {
29077	//     "maxResults": {
29078	//       "default": "100",
29079	//       "description": "Maximum number of results to return.",
29080	//       "format": "int32",
29081	//       "location": "query",
29082	//       "maximum": "100",
29083	//       "minimum": "0",
29084	//       "type": "integer"
29085	//     },
29086	//     "pageToken": {
29087	//       "description": "The value of the nextToken from the previous result page.",
29088	//       "location": "query",
29089	//       "type": "string"
29090	//     },
29091	//     "profileId": {
29092	//       "description": "The DFA user profile ID.",
29093	//       "format": "int64",
29094	//       "location": "path",
29095	//       "required": true,
29096	//       "type": "string"
29097	//     }
29098	//   },
29099	//   "path": "userprofiles/{profileId}/dimensionvalues/query",
29100	//   "request": {
29101	//     "$ref": "DimensionValueRequest"
29102	//   },
29103	//   "response": {
29104	//     "$ref": "DimensionValueList"
29105	//   },
29106	//   "scopes": [
29107	//     "https://www.googleapis.com/auth/dfareporting"
29108	//   ]
29109	// }
29110
29111}
29112
29113// Pages invokes f for each page of results.
29114// A non-nil error returned from f will halt the iteration.
29115// The provided context supersedes any context provided to the Context method.
29116func (c *DimensionValuesQueryCall) Pages(ctx context.Context, f func(*DimensionValueList) error) error {
29117	c.ctx_ = ctx
29118	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
29119	for {
29120		x, err := c.Do()
29121		if err != nil {
29122			return err
29123		}
29124		if err := f(x); err != nil {
29125			return err
29126		}
29127		if x.NextPageToken == "" {
29128			return nil
29129		}
29130		c.PageToken(x.NextPageToken)
29131	}
29132}
29133
29134// method id "dfareporting.directorySiteContacts.get":
29135
29136type DirectorySiteContactsGetCall struct {
29137	s            *Service
29138	profileId    int64
29139	id           int64
29140	urlParams_   gensupport.URLParams
29141	ifNoneMatch_ string
29142	ctx_         context.Context
29143	header_      http.Header
29144}
29145
29146// Get: Gets one directory site contact by ID.
29147func (r *DirectorySiteContactsService) Get(profileId int64, id int64) *DirectorySiteContactsGetCall {
29148	c := &DirectorySiteContactsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29149	c.profileId = profileId
29150	c.id = id
29151	return c
29152}
29153
29154// Fields allows partial responses to be retrieved. See
29155// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29156// for more information.
29157func (c *DirectorySiteContactsGetCall) Fields(s ...googleapi.Field) *DirectorySiteContactsGetCall {
29158	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29159	return c
29160}
29161
29162// IfNoneMatch sets the optional parameter which makes the operation
29163// fail if the object's ETag matches the given value. This is useful for
29164// getting updates only after the object has changed since the last
29165// request. Use googleapi.IsNotModified to check whether the response
29166// error from Do is the result of In-None-Match.
29167func (c *DirectorySiteContactsGetCall) IfNoneMatch(entityTag string) *DirectorySiteContactsGetCall {
29168	c.ifNoneMatch_ = entityTag
29169	return c
29170}
29171
29172// Context sets the context to be used in this call's Do method. Any
29173// pending HTTP request will be aborted if the provided context is
29174// canceled.
29175func (c *DirectorySiteContactsGetCall) Context(ctx context.Context) *DirectorySiteContactsGetCall {
29176	c.ctx_ = ctx
29177	return c
29178}
29179
29180// Header returns an http.Header that can be modified by the caller to
29181// add HTTP headers to the request.
29182func (c *DirectorySiteContactsGetCall) Header() http.Header {
29183	if c.header_ == nil {
29184		c.header_ = make(http.Header)
29185	}
29186	return c.header_
29187}
29188
29189func (c *DirectorySiteContactsGetCall) doRequest(alt string) (*http.Response, error) {
29190	reqHeaders := make(http.Header)
29191	for k, v := range c.header_ {
29192		reqHeaders[k] = v
29193	}
29194	reqHeaders.Set("User-Agent", c.s.userAgent())
29195	if c.ifNoneMatch_ != "" {
29196		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29197	}
29198	var body io.Reader = nil
29199	c.urlParams_.Set("alt", alt)
29200	c.urlParams_.Set("prettyPrint", "false")
29201	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySiteContacts/{id}")
29202	urls += "?" + c.urlParams_.Encode()
29203	req, err := http.NewRequest("GET", urls, body)
29204	if err != nil {
29205		return nil, err
29206	}
29207	req.Header = reqHeaders
29208	googleapi.Expand(req.URL, map[string]string{
29209		"profileId": strconv.FormatInt(c.profileId, 10),
29210		"id":        strconv.FormatInt(c.id, 10),
29211	})
29212	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29213}
29214
29215// Do executes the "dfareporting.directorySiteContacts.get" call.
29216// Exactly one of *DirectorySiteContact or error will be non-nil. Any
29217// non-2xx status code is an error. Response headers are in either
29218// *DirectorySiteContact.ServerResponse.Header or (if a response was
29219// returned at all) in error.(*googleapi.Error).Header. Use
29220// googleapi.IsNotModified to check whether the returned error was
29221// because http.StatusNotModified was returned.
29222func (c *DirectorySiteContactsGetCall) Do(opts ...googleapi.CallOption) (*DirectorySiteContact, error) {
29223	gensupport.SetOptions(c.urlParams_, opts...)
29224	res, err := c.doRequest("json")
29225	if res != nil && res.StatusCode == http.StatusNotModified {
29226		if res.Body != nil {
29227			res.Body.Close()
29228		}
29229		return nil, &googleapi.Error{
29230			Code:   res.StatusCode,
29231			Header: res.Header,
29232		}
29233	}
29234	if err != nil {
29235		return nil, err
29236	}
29237	defer googleapi.CloseBody(res)
29238	if err := googleapi.CheckResponse(res); err != nil {
29239		return nil, err
29240	}
29241	ret := &DirectorySiteContact{
29242		ServerResponse: googleapi.ServerResponse{
29243			Header:         res.Header,
29244			HTTPStatusCode: res.StatusCode,
29245		},
29246	}
29247	target := &ret
29248	if err := gensupport.DecodeResponse(target, res); err != nil {
29249		return nil, err
29250	}
29251	return ret, nil
29252	// {
29253	//   "description": "Gets one directory site contact by ID.",
29254	//   "httpMethod": "GET",
29255	//   "id": "dfareporting.directorySiteContacts.get",
29256	//   "parameterOrder": [
29257	//     "profileId",
29258	//     "id"
29259	//   ],
29260	//   "parameters": {
29261	//     "id": {
29262	//       "description": "Directory site contact ID.",
29263	//       "format": "int64",
29264	//       "location": "path",
29265	//       "required": true,
29266	//       "type": "string"
29267	//     },
29268	//     "profileId": {
29269	//       "description": "User profile ID associated with this request.",
29270	//       "format": "int64",
29271	//       "location": "path",
29272	//       "required": true,
29273	//       "type": "string"
29274	//     }
29275	//   },
29276	//   "path": "userprofiles/{profileId}/directorySiteContacts/{id}",
29277	//   "response": {
29278	//     "$ref": "DirectorySiteContact"
29279	//   },
29280	//   "scopes": [
29281	//     "https://www.googleapis.com/auth/dfatrafficking"
29282	//   ]
29283	// }
29284
29285}
29286
29287// method id "dfareporting.directorySiteContacts.list":
29288
29289type DirectorySiteContactsListCall struct {
29290	s            *Service
29291	profileId    int64
29292	urlParams_   gensupport.URLParams
29293	ifNoneMatch_ string
29294	ctx_         context.Context
29295	header_      http.Header
29296}
29297
29298// List: Retrieves a list of directory site contacts, possibly filtered.
29299// This method supports paging.
29300func (r *DirectorySiteContactsService) List(profileId int64) *DirectorySiteContactsListCall {
29301	c := &DirectorySiteContactsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29302	c.profileId = profileId
29303	return c
29304}
29305
29306// DirectorySiteIds sets the optional parameter "directorySiteIds":
29307// Select only directory site contacts with these directory site IDs.
29308// This is a required field.
29309func (c *DirectorySiteContactsListCall) DirectorySiteIds(directorySiteIds ...int64) *DirectorySiteContactsListCall {
29310	var directorySiteIds_ []string
29311	for _, v := range directorySiteIds {
29312		directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
29313	}
29314	c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
29315	return c
29316}
29317
29318// Ids sets the optional parameter "ids": Select only directory site
29319// contacts with these IDs.
29320func (c *DirectorySiteContactsListCall) Ids(ids ...int64) *DirectorySiteContactsListCall {
29321	var ids_ []string
29322	for _, v := range ids {
29323		ids_ = append(ids_, fmt.Sprint(v))
29324	}
29325	c.urlParams_.SetMulti("ids", ids_)
29326	return c
29327}
29328
29329// MaxResults sets the optional parameter "maxResults": Maximum number
29330// of results to return.
29331func (c *DirectorySiteContactsListCall) MaxResults(maxResults int64) *DirectorySiteContactsListCall {
29332	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
29333	return c
29334}
29335
29336// PageToken sets the optional parameter "pageToken": Value of the
29337// nextPageToken from the previous result page.
29338func (c *DirectorySiteContactsListCall) PageToken(pageToken string) *DirectorySiteContactsListCall {
29339	c.urlParams_.Set("pageToken", pageToken)
29340	return c
29341}
29342
29343// SearchString sets the optional parameter "searchString": Allows
29344// searching for objects by name, ID or email. Wildcards (*) are
29345// allowed. For example, "directory site contact*2015" will return
29346// objects with names like "directory site contact June 2015",
29347// "directory site contact April 2015", or simply "directory site
29348// contact 2015". Most of the searches also add wildcards implicitly at
29349// the start and the end of the search string. For example, a search
29350// string of "directory site contact" will match objects with name "my
29351// directory site contact", "directory site contact 2015", or simply
29352// "directory site contact".
29353func (c *DirectorySiteContactsListCall) SearchString(searchString string) *DirectorySiteContactsListCall {
29354	c.urlParams_.Set("searchString", searchString)
29355	return c
29356}
29357
29358// SortField sets the optional parameter "sortField": Field by which to
29359// sort the list.
29360//
29361// Possible values:
29362//   "ID" (default)
29363//   "NAME"
29364func (c *DirectorySiteContactsListCall) SortField(sortField string) *DirectorySiteContactsListCall {
29365	c.urlParams_.Set("sortField", sortField)
29366	return c
29367}
29368
29369// SortOrder sets the optional parameter "sortOrder": Order of sorted
29370// results.
29371//
29372// Possible values:
29373//   "ASCENDING" (default)
29374//   "DESCENDING"
29375func (c *DirectorySiteContactsListCall) SortOrder(sortOrder string) *DirectorySiteContactsListCall {
29376	c.urlParams_.Set("sortOrder", sortOrder)
29377	return c
29378}
29379
29380// Fields allows partial responses to be retrieved. See
29381// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29382// for more information.
29383func (c *DirectorySiteContactsListCall) Fields(s ...googleapi.Field) *DirectorySiteContactsListCall {
29384	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29385	return c
29386}
29387
29388// IfNoneMatch sets the optional parameter which makes the operation
29389// fail if the object's ETag matches the given value. This is useful for
29390// getting updates only after the object has changed since the last
29391// request. Use googleapi.IsNotModified to check whether the response
29392// error from Do is the result of In-None-Match.
29393func (c *DirectorySiteContactsListCall) IfNoneMatch(entityTag string) *DirectorySiteContactsListCall {
29394	c.ifNoneMatch_ = entityTag
29395	return c
29396}
29397
29398// Context sets the context to be used in this call's Do method. Any
29399// pending HTTP request will be aborted if the provided context is
29400// canceled.
29401func (c *DirectorySiteContactsListCall) Context(ctx context.Context) *DirectorySiteContactsListCall {
29402	c.ctx_ = ctx
29403	return c
29404}
29405
29406// Header returns an http.Header that can be modified by the caller to
29407// add HTTP headers to the request.
29408func (c *DirectorySiteContactsListCall) Header() http.Header {
29409	if c.header_ == nil {
29410		c.header_ = make(http.Header)
29411	}
29412	return c.header_
29413}
29414
29415func (c *DirectorySiteContactsListCall) doRequest(alt string) (*http.Response, error) {
29416	reqHeaders := make(http.Header)
29417	for k, v := range c.header_ {
29418		reqHeaders[k] = v
29419	}
29420	reqHeaders.Set("User-Agent", c.s.userAgent())
29421	if c.ifNoneMatch_ != "" {
29422		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29423	}
29424	var body io.Reader = nil
29425	c.urlParams_.Set("alt", alt)
29426	c.urlParams_.Set("prettyPrint", "false")
29427	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySiteContacts")
29428	urls += "?" + c.urlParams_.Encode()
29429	req, err := http.NewRequest("GET", urls, body)
29430	if err != nil {
29431		return nil, err
29432	}
29433	req.Header = reqHeaders
29434	googleapi.Expand(req.URL, map[string]string{
29435		"profileId": strconv.FormatInt(c.profileId, 10),
29436	})
29437	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29438}
29439
29440// Do executes the "dfareporting.directorySiteContacts.list" call.
29441// Exactly one of *DirectorySiteContactsListResponse or error will be
29442// non-nil. Any non-2xx status code is an error. Response headers are in
29443// either *DirectorySiteContactsListResponse.ServerResponse.Header or
29444// (if a response was returned at all) in
29445// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29446// whether the returned error was because http.StatusNotModified was
29447// returned.
29448func (c *DirectorySiteContactsListCall) Do(opts ...googleapi.CallOption) (*DirectorySiteContactsListResponse, error) {
29449	gensupport.SetOptions(c.urlParams_, opts...)
29450	res, err := c.doRequest("json")
29451	if res != nil && res.StatusCode == http.StatusNotModified {
29452		if res.Body != nil {
29453			res.Body.Close()
29454		}
29455		return nil, &googleapi.Error{
29456			Code:   res.StatusCode,
29457			Header: res.Header,
29458		}
29459	}
29460	if err != nil {
29461		return nil, err
29462	}
29463	defer googleapi.CloseBody(res)
29464	if err := googleapi.CheckResponse(res); err != nil {
29465		return nil, err
29466	}
29467	ret := &DirectorySiteContactsListResponse{
29468		ServerResponse: googleapi.ServerResponse{
29469			Header:         res.Header,
29470			HTTPStatusCode: res.StatusCode,
29471		},
29472	}
29473	target := &ret
29474	if err := gensupport.DecodeResponse(target, res); err != nil {
29475		return nil, err
29476	}
29477	return ret, nil
29478	// {
29479	//   "description": "Retrieves a list of directory site contacts, possibly filtered. This method supports paging.",
29480	//   "httpMethod": "GET",
29481	//   "id": "dfareporting.directorySiteContacts.list",
29482	//   "parameterOrder": [
29483	//     "profileId"
29484	//   ],
29485	//   "parameters": {
29486	//     "directorySiteIds": {
29487	//       "description": "Select only directory site contacts with these directory site IDs. This is a required field.",
29488	//       "format": "int64",
29489	//       "location": "query",
29490	//       "repeated": true,
29491	//       "type": "string"
29492	//     },
29493	//     "ids": {
29494	//       "description": "Select only directory site contacts with these IDs.",
29495	//       "format": "int64",
29496	//       "location": "query",
29497	//       "repeated": true,
29498	//       "type": "string"
29499	//     },
29500	//     "maxResults": {
29501	//       "default": "1000",
29502	//       "description": "Maximum number of results to return.",
29503	//       "format": "int32",
29504	//       "location": "query",
29505	//       "maximum": "1000",
29506	//       "minimum": "0",
29507	//       "type": "integer"
29508	//     },
29509	//     "pageToken": {
29510	//       "description": "Value of the nextPageToken from the previous result page.",
29511	//       "location": "query",
29512	//       "type": "string"
29513	//     },
29514	//     "profileId": {
29515	//       "description": "User profile ID associated with this request.",
29516	//       "format": "int64",
29517	//       "location": "path",
29518	//       "required": true,
29519	//       "type": "string"
29520	//     },
29521	//     "searchString": {
29522	//       "description": "Allows searching for objects by name, ID or email. Wildcards (*) are allowed. For example, \"directory site contact*2015\" will return objects with names like \"directory site contact June 2015\", \"directory site contact April 2015\", or simply \"directory site contact 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 contact\" will match objects with name \"my directory site contact\", \"directory site contact 2015\", or simply \"directory site contact\".",
29523	//       "location": "query",
29524	//       "type": "string"
29525	//     },
29526	//     "sortField": {
29527	//       "default": "ID",
29528	//       "description": "Field by which to sort the list.",
29529	//       "enum": [
29530	//         "ID",
29531	//         "NAME"
29532	//       ],
29533	//       "enumDescriptions": [
29534	//         "",
29535	//         ""
29536	//       ],
29537	//       "location": "query",
29538	//       "type": "string"
29539	//     },
29540	//     "sortOrder": {
29541	//       "default": "ASCENDING",
29542	//       "description": "Order of sorted results.",
29543	//       "enum": [
29544	//         "ASCENDING",
29545	//         "DESCENDING"
29546	//       ],
29547	//       "enumDescriptions": [
29548	//         "",
29549	//         ""
29550	//       ],
29551	//       "location": "query",
29552	//       "type": "string"
29553	//     }
29554	//   },
29555	//   "path": "userprofiles/{profileId}/directorySiteContacts",
29556	//   "response": {
29557	//     "$ref": "DirectorySiteContactsListResponse"
29558	//   },
29559	//   "scopes": [
29560	//     "https://www.googleapis.com/auth/dfatrafficking"
29561	//   ]
29562	// }
29563
29564}
29565
29566// Pages invokes f for each page of results.
29567// A non-nil error returned from f will halt the iteration.
29568// The provided context supersedes any context provided to the Context method.
29569func (c *DirectorySiteContactsListCall) Pages(ctx context.Context, f func(*DirectorySiteContactsListResponse) error) error {
29570	c.ctx_ = ctx
29571	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
29572	for {
29573		x, err := c.Do()
29574		if err != nil {
29575			return err
29576		}
29577		if err := f(x); err != nil {
29578			return err
29579		}
29580		if x.NextPageToken == "" {
29581			return nil
29582		}
29583		c.PageToken(x.NextPageToken)
29584	}
29585}
29586
29587// method id "dfareporting.directorySites.get":
29588
29589type DirectorySitesGetCall struct {
29590	s            *Service
29591	profileId    int64
29592	id           int64
29593	urlParams_   gensupport.URLParams
29594	ifNoneMatch_ string
29595	ctx_         context.Context
29596	header_      http.Header
29597}
29598
29599// Get: Gets one directory site by ID.
29600func (r *DirectorySitesService) Get(profileId int64, id int64) *DirectorySitesGetCall {
29601	c := &DirectorySitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29602	c.profileId = profileId
29603	c.id = id
29604	return c
29605}
29606
29607// Fields allows partial responses to be retrieved. See
29608// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29609// for more information.
29610func (c *DirectorySitesGetCall) Fields(s ...googleapi.Field) *DirectorySitesGetCall {
29611	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29612	return c
29613}
29614
29615// IfNoneMatch sets the optional parameter which makes the operation
29616// fail if the object's ETag matches the given value. This is useful for
29617// getting updates only after the object has changed since the last
29618// request. Use googleapi.IsNotModified to check whether the response
29619// error from Do is the result of In-None-Match.
29620func (c *DirectorySitesGetCall) IfNoneMatch(entityTag string) *DirectorySitesGetCall {
29621	c.ifNoneMatch_ = entityTag
29622	return c
29623}
29624
29625// Context sets the context to be used in this call's Do method. Any
29626// pending HTTP request will be aborted if the provided context is
29627// canceled.
29628func (c *DirectorySitesGetCall) Context(ctx context.Context) *DirectorySitesGetCall {
29629	c.ctx_ = ctx
29630	return c
29631}
29632
29633// Header returns an http.Header that can be modified by the caller to
29634// add HTTP headers to the request.
29635func (c *DirectorySitesGetCall) Header() http.Header {
29636	if c.header_ == nil {
29637		c.header_ = make(http.Header)
29638	}
29639	return c.header_
29640}
29641
29642func (c *DirectorySitesGetCall) doRequest(alt string) (*http.Response, error) {
29643	reqHeaders := make(http.Header)
29644	for k, v := range c.header_ {
29645		reqHeaders[k] = v
29646	}
29647	reqHeaders.Set("User-Agent", c.s.userAgent())
29648	if c.ifNoneMatch_ != "" {
29649		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29650	}
29651	var body io.Reader = nil
29652	c.urlParams_.Set("alt", alt)
29653	c.urlParams_.Set("prettyPrint", "false")
29654	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites/{id}")
29655	urls += "?" + c.urlParams_.Encode()
29656	req, err := http.NewRequest("GET", urls, body)
29657	if err != nil {
29658		return nil, err
29659	}
29660	req.Header = reqHeaders
29661	googleapi.Expand(req.URL, map[string]string{
29662		"profileId": strconv.FormatInt(c.profileId, 10),
29663		"id":        strconv.FormatInt(c.id, 10),
29664	})
29665	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29666}
29667
29668// Do executes the "dfareporting.directorySites.get" call.
29669// Exactly one of *DirectorySite or error will be non-nil. Any non-2xx
29670// status code is an error. Response headers are in either
29671// *DirectorySite.ServerResponse.Header or (if a response was returned
29672// at all) in error.(*googleapi.Error).Header. Use
29673// googleapi.IsNotModified to check whether the returned error was
29674// because http.StatusNotModified was returned.
29675func (c *DirectorySitesGetCall) Do(opts ...googleapi.CallOption) (*DirectorySite, error) {
29676	gensupport.SetOptions(c.urlParams_, opts...)
29677	res, err := c.doRequest("json")
29678	if res != nil && res.StatusCode == http.StatusNotModified {
29679		if res.Body != nil {
29680			res.Body.Close()
29681		}
29682		return nil, &googleapi.Error{
29683			Code:   res.StatusCode,
29684			Header: res.Header,
29685		}
29686	}
29687	if err != nil {
29688		return nil, err
29689	}
29690	defer googleapi.CloseBody(res)
29691	if err := googleapi.CheckResponse(res); err != nil {
29692		return nil, err
29693	}
29694	ret := &DirectorySite{
29695		ServerResponse: googleapi.ServerResponse{
29696			Header:         res.Header,
29697			HTTPStatusCode: res.StatusCode,
29698		},
29699	}
29700	target := &ret
29701	if err := gensupport.DecodeResponse(target, res); err != nil {
29702		return nil, err
29703	}
29704	return ret, nil
29705	// {
29706	//   "description": "Gets one directory site by ID.",
29707	//   "httpMethod": "GET",
29708	//   "id": "dfareporting.directorySites.get",
29709	//   "parameterOrder": [
29710	//     "profileId",
29711	//     "id"
29712	//   ],
29713	//   "parameters": {
29714	//     "id": {
29715	//       "description": "Directory site ID.",
29716	//       "format": "int64",
29717	//       "location": "path",
29718	//       "required": true,
29719	//       "type": "string"
29720	//     },
29721	//     "profileId": {
29722	//       "description": "User profile ID associated with this request.",
29723	//       "format": "int64",
29724	//       "location": "path",
29725	//       "required": true,
29726	//       "type": "string"
29727	//     }
29728	//   },
29729	//   "path": "userprofiles/{profileId}/directorySites/{id}",
29730	//   "response": {
29731	//     "$ref": "DirectorySite"
29732	//   },
29733	//   "scopes": [
29734	//     "https://www.googleapis.com/auth/dfatrafficking"
29735	//   ]
29736	// }
29737
29738}
29739
29740// method id "dfareporting.directorySites.insert":
29741
29742type DirectorySitesInsertCall struct {
29743	s             *Service
29744	profileId     int64
29745	directorysite *DirectorySite
29746	urlParams_    gensupport.URLParams
29747	ctx_          context.Context
29748	header_       http.Header
29749}
29750
29751// Insert: Inserts a new directory site.
29752func (r *DirectorySitesService) Insert(profileId int64, directorysite *DirectorySite) *DirectorySitesInsertCall {
29753	c := &DirectorySitesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29754	c.profileId = profileId
29755	c.directorysite = directorysite
29756	return c
29757}
29758
29759// Fields allows partial responses to be retrieved. See
29760// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29761// for more information.
29762func (c *DirectorySitesInsertCall) Fields(s ...googleapi.Field) *DirectorySitesInsertCall {
29763	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29764	return c
29765}
29766
29767// Context sets the context to be used in this call's Do method. Any
29768// pending HTTP request will be aborted if the provided context is
29769// canceled.
29770func (c *DirectorySitesInsertCall) Context(ctx context.Context) *DirectorySitesInsertCall {
29771	c.ctx_ = ctx
29772	return c
29773}
29774
29775// Header returns an http.Header that can be modified by the caller to
29776// add HTTP headers to the request.
29777func (c *DirectorySitesInsertCall) Header() http.Header {
29778	if c.header_ == nil {
29779		c.header_ = make(http.Header)
29780	}
29781	return c.header_
29782}
29783
29784func (c *DirectorySitesInsertCall) doRequest(alt string) (*http.Response, error) {
29785	reqHeaders := make(http.Header)
29786	for k, v := range c.header_ {
29787		reqHeaders[k] = v
29788	}
29789	reqHeaders.Set("User-Agent", c.s.userAgent())
29790	var body io.Reader = nil
29791	body, err := googleapi.WithoutDataWrapper.JSONReader(c.directorysite)
29792	if err != nil {
29793		return nil, err
29794	}
29795	reqHeaders.Set("Content-Type", "application/json")
29796	c.urlParams_.Set("alt", alt)
29797	c.urlParams_.Set("prettyPrint", "false")
29798	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites")
29799	urls += "?" + c.urlParams_.Encode()
29800	req, err := http.NewRequest("POST", urls, body)
29801	if err != nil {
29802		return nil, err
29803	}
29804	req.Header = reqHeaders
29805	googleapi.Expand(req.URL, map[string]string{
29806		"profileId": strconv.FormatInt(c.profileId, 10),
29807	})
29808	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29809}
29810
29811// Do executes the "dfareporting.directorySites.insert" call.
29812// Exactly one of *DirectorySite or error will be non-nil. Any non-2xx
29813// status code is an error. Response headers are in either
29814// *DirectorySite.ServerResponse.Header or (if a response was returned
29815// at all) in error.(*googleapi.Error).Header. Use
29816// googleapi.IsNotModified to check whether the returned error was
29817// because http.StatusNotModified was returned.
29818func (c *DirectorySitesInsertCall) Do(opts ...googleapi.CallOption) (*DirectorySite, error) {
29819	gensupport.SetOptions(c.urlParams_, opts...)
29820	res, err := c.doRequest("json")
29821	if res != nil && res.StatusCode == http.StatusNotModified {
29822		if res.Body != nil {
29823			res.Body.Close()
29824		}
29825		return nil, &googleapi.Error{
29826			Code:   res.StatusCode,
29827			Header: res.Header,
29828		}
29829	}
29830	if err != nil {
29831		return nil, err
29832	}
29833	defer googleapi.CloseBody(res)
29834	if err := googleapi.CheckResponse(res); err != nil {
29835		return nil, err
29836	}
29837	ret := &DirectorySite{
29838		ServerResponse: googleapi.ServerResponse{
29839			Header:         res.Header,
29840			HTTPStatusCode: res.StatusCode,
29841		},
29842	}
29843	target := &ret
29844	if err := gensupport.DecodeResponse(target, res); err != nil {
29845		return nil, err
29846	}
29847	return ret, nil
29848	// {
29849	//   "description": "Inserts a new directory site.",
29850	//   "httpMethod": "POST",
29851	//   "id": "dfareporting.directorySites.insert",
29852	//   "parameterOrder": [
29853	//     "profileId"
29854	//   ],
29855	//   "parameters": {
29856	//     "profileId": {
29857	//       "description": "User profile ID associated with this request.",
29858	//       "format": "int64",
29859	//       "location": "path",
29860	//       "required": true,
29861	//       "type": "string"
29862	//     }
29863	//   },
29864	//   "path": "userprofiles/{profileId}/directorySites",
29865	//   "request": {
29866	//     "$ref": "DirectorySite"
29867	//   },
29868	//   "response": {
29869	//     "$ref": "DirectorySite"
29870	//   },
29871	//   "scopes": [
29872	//     "https://www.googleapis.com/auth/dfatrafficking"
29873	//   ]
29874	// }
29875
29876}
29877
29878// method id "dfareporting.directorySites.list":
29879
29880type DirectorySitesListCall struct {
29881	s            *Service
29882	profileId    int64
29883	urlParams_   gensupport.URLParams
29884	ifNoneMatch_ string
29885	ctx_         context.Context
29886	header_      http.Header
29887}
29888
29889// List: Retrieves a list of directory sites, possibly filtered. This
29890// method supports paging.
29891func (r *DirectorySitesService) List(profileId int64) *DirectorySitesListCall {
29892	c := &DirectorySitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29893	c.profileId = profileId
29894	return c
29895}
29896
29897// AcceptsInStreamVideoPlacements sets the optional parameter
29898// "acceptsInStreamVideoPlacements": This search filter is no longer
29899// supported and will have no effect on the results returned.
29900func (c *DirectorySitesListCall) AcceptsInStreamVideoPlacements(acceptsInStreamVideoPlacements bool) *DirectorySitesListCall {
29901	c.urlParams_.Set("acceptsInStreamVideoPlacements", fmt.Sprint(acceptsInStreamVideoPlacements))
29902	return c
29903}
29904
29905// AcceptsInterstitialPlacements sets the optional parameter
29906// "acceptsInterstitialPlacements": This search filter is no longer
29907// supported and will have no effect on the results returned.
29908func (c *DirectorySitesListCall) AcceptsInterstitialPlacements(acceptsInterstitialPlacements bool) *DirectorySitesListCall {
29909	c.urlParams_.Set("acceptsInterstitialPlacements", fmt.Sprint(acceptsInterstitialPlacements))
29910	return c
29911}
29912
29913// AcceptsPublisherPaidPlacements sets the optional parameter
29914// "acceptsPublisherPaidPlacements": Select only directory sites that
29915// accept publisher paid placements. This field can be left blank.
29916func (c *DirectorySitesListCall) AcceptsPublisherPaidPlacements(acceptsPublisherPaidPlacements bool) *DirectorySitesListCall {
29917	c.urlParams_.Set("acceptsPublisherPaidPlacements", fmt.Sprint(acceptsPublisherPaidPlacements))
29918	return c
29919}
29920
29921// Active sets the optional parameter "active": Select only active
29922// directory sites. Leave blank to retrieve both active and inactive
29923// directory sites.
29924func (c *DirectorySitesListCall) Active(active bool) *DirectorySitesListCall {
29925	c.urlParams_.Set("active", fmt.Sprint(active))
29926	return c
29927}
29928
29929// CountryId sets the optional parameter "countryId": Select only
29930// directory sites with this country ID.
29931func (c *DirectorySitesListCall) CountryId(countryId int64) *DirectorySitesListCall {
29932	c.urlParams_.Set("countryId", fmt.Sprint(countryId))
29933	return c
29934}
29935
29936// DfpNetworkCode sets the optional parameter "dfpNetworkCode": Select
29937// only directory sites with this Ad Manager network code.
29938func (c *DirectorySitesListCall) DfpNetworkCode(dfpNetworkCode string) *DirectorySitesListCall {
29939	c.urlParams_.Set("dfpNetworkCode", dfpNetworkCode)
29940	return c
29941}
29942
29943// Ids sets the optional parameter "ids": Select only directory sites
29944// with these IDs.
29945func (c *DirectorySitesListCall) Ids(ids ...int64) *DirectorySitesListCall {
29946	var ids_ []string
29947	for _, v := range ids {
29948		ids_ = append(ids_, fmt.Sprint(v))
29949	}
29950	c.urlParams_.SetMulti("ids", ids_)
29951	return c
29952}
29953
29954// MaxResults sets the optional parameter "maxResults": Maximum number
29955// of results to return.
29956func (c *DirectorySitesListCall) MaxResults(maxResults int64) *DirectorySitesListCall {
29957	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
29958	return c
29959}
29960
29961// PageToken sets the optional parameter "pageToken": Value of the
29962// nextPageToken from the previous result page.
29963func (c *DirectorySitesListCall) PageToken(pageToken string) *DirectorySitesListCall {
29964	c.urlParams_.Set("pageToken", pageToken)
29965	return c
29966}
29967
29968// ParentId sets the optional parameter "parentId": Select only
29969// directory sites with this parent ID.
29970func (c *DirectorySitesListCall) ParentId(parentId int64) *DirectorySitesListCall {
29971	c.urlParams_.Set("parentId", fmt.Sprint(parentId))
29972	return c
29973}
29974
29975// SearchString sets the optional parameter "searchString": Allows
29976// searching for objects by name, ID or URL. Wildcards (*) are allowed.
29977// For example, "directory site*2015" will return objects with names
29978// like "directory site June 2015", "directory site April 2015", or
29979// simply "directory site 2015". Most of the searches also add wildcards
29980// implicitly at the start and the end of the search string. For
29981// example, a search string of "directory site" will match objects with
29982// name "my directory site", "directory site 2015" or simply, "directory
29983// site".
29984func (c *DirectorySitesListCall) SearchString(searchString string) *DirectorySitesListCall {
29985	c.urlParams_.Set("searchString", searchString)
29986	return c
29987}
29988
29989// SortField sets the optional parameter "sortField": Field by which to
29990// sort the list.
29991//
29992// Possible values:
29993//   "ID" (default)
29994//   "NAME"
29995func (c *DirectorySitesListCall) SortField(sortField string) *DirectorySitesListCall {
29996	c.urlParams_.Set("sortField", sortField)
29997	return c
29998}
29999
30000// SortOrder sets the optional parameter "sortOrder": Order of sorted
30001// results.
30002//
30003// Possible values:
30004//   "ASCENDING" (default)
30005//   "DESCENDING"
30006func (c *DirectorySitesListCall) SortOrder(sortOrder string) *DirectorySitesListCall {
30007	c.urlParams_.Set("sortOrder", sortOrder)
30008	return c
30009}
30010
30011// Fields allows partial responses to be retrieved. See
30012// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30013// for more information.
30014func (c *DirectorySitesListCall) Fields(s ...googleapi.Field) *DirectorySitesListCall {
30015	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30016	return c
30017}
30018
30019// IfNoneMatch sets the optional parameter which makes the operation
30020// fail if the object's ETag matches the given value. This is useful for
30021// getting updates only after the object has changed since the last
30022// request. Use googleapi.IsNotModified to check whether the response
30023// error from Do is the result of In-None-Match.
30024func (c *DirectorySitesListCall) IfNoneMatch(entityTag string) *DirectorySitesListCall {
30025	c.ifNoneMatch_ = entityTag
30026	return c
30027}
30028
30029// Context sets the context to be used in this call's Do method. Any
30030// pending HTTP request will be aborted if the provided context is
30031// canceled.
30032func (c *DirectorySitesListCall) Context(ctx context.Context) *DirectorySitesListCall {
30033	c.ctx_ = ctx
30034	return c
30035}
30036
30037// Header returns an http.Header that can be modified by the caller to
30038// add HTTP headers to the request.
30039func (c *DirectorySitesListCall) Header() http.Header {
30040	if c.header_ == nil {
30041		c.header_ = make(http.Header)
30042	}
30043	return c.header_
30044}
30045
30046func (c *DirectorySitesListCall) doRequest(alt string) (*http.Response, error) {
30047	reqHeaders := make(http.Header)
30048	for k, v := range c.header_ {
30049		reqHeaders[k] = v
30050	}
30051	reqHeaders.Set("User-Agent", c.s.userAgent())
30052	if c.ifNoneMatch_ != "" {
30053		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30054	}
30055	var body io.Reader = nil
30056	c.urlParams_.Set("alt", alt)
30057	c.urlParams_.Set("prettyPrint", "false")
30058	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites")
30059	urls += "?" + c.urlParams_.Encode()
30060	req, err := http.NewRequest("GET", urls, body)
30061	if err != nil {
30062		return nil, err
30063	}
30064	req.Header = reqHeaders
30065	googleapi.Expand(req.URL, map[string]string{
30066		"profileId": strconv.FormatInt(c.profileId, 10),
30067	})
30068	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30069}
30070
30071// Do executes the "dfareporting.directorySites.list" call.
30072// Exactly one of *DirectorySitesListResponse or error will be non-nil.
30073// Any non-2xx status code is an error. Response headers are in either
30074// *DirectorySitesListResponse.ServerResponse.Header or (if a response
30075// was returned at all) in error.(*googleapi.Error).Header. Use
30076// googleapi.IsNotModified to check whether the returned error was
30077// because http.StatusNotModified was returned.
30078func (c *DirectorySitesListCall) Do(opts ...googleapi.CallOption) (*DirectorySitesListResponse, error) {
30079	gensupport.SetOptions(c.urlParams_, opts...)
30080	res, err := c.doRequest("json")
30081	if res != nil && res.StatusCode == http.StatusNotModified {
30082		if res.Body != nil {
30083			res.Body.Close()
30084		}
30085		return nil, &googleapi.Error{
30086			Code:   res.StatusCode,
30087			Header: res.Header,
30088		}
30089	}
30090	if err != nil {
30091		return nil, err
30092	}
30093	defer googleapi.CloseBody(res)
30094	if err := googleapi.CheckResponse(res); err != nil {
30095		return nil, err
30096	}
30097	ret := &DirectorySitesListResponse{
30098		ServerResponse: googleapi.ServerResponse{
30099			Header:         res.Header,
30100			HTTPStatusCode: res.StatusCode,
30101		},
30102	}
30103	target := &ret
30104	if err := gensupport.DecodeResponse(target, res); err != nil {
30105		return nil, err
30106	}
30107	return ret, nil
30108	// {
30109	//   "description": "Retrieves a list of directory sites, possibly filtered. This method supports paging.",
30110	//   "httpMethod": "GET",
30111	//   "id": "dfareporting.directorySites.list",
30112	//   "parameterOrder": [
30113	//     "profileId"
30114	//   ],
30115	//   "parameters": {
30116	//     "acceptsInStreamVideoPlacements": {
30117	//       "description": "This search filter is no longer supported and will have no effect on the results returned.",
30118	//       "location": "query",
30119	//       "type": "boolean"
30120	//     },
30121	//     "acceptsInterstitialPlacements": {
30122	//       "description": "This search filter is no longer supported and will have no effect on the results returned.",
30123	//       "location": "query",
30124	//       "type": "boolean"
30125	//     },
30126	//     "acceptsPublisherPaidPlacements": {
30127	//       "description": "Select only directory sites that accept publisher paid placements. This field can be left blank.",
30128	//       "location": "query",
30129	//       "type": "boolean"
30130	//     },
30131	//     "active": {
30132	//       "description": "Select only active directory sites. Leave blank to retrieve both active and inactive directory sites.",
30133	//       "location": "query",
30134	//       "type": "boolean"
30135	//     },
30136	//     "countryId": {
30137	//       "description": "Select only directory sites with this country ID.",
30138	//       "format": "int64",
30139	//       "location": "query",
30140	//       "type": "string"
30141	//     },
30142	//     "dfpNetworkCode": {
30143	//       "description": "Select only directory sites with this Ad Manager network code.",
30144	//       "location": "query",
30145	//       "type": "string"
30146	//     },
30147	//     "ids": {
30148	//       "description": "Select only directory sites with these IDs.",
30149	//       "format": "int64",
30150	//       "location": "query",
30151	//       "repeated": true,
30152	//       "type": "string"
30153	//     },
30154	//     "maxResults": {
30155	//       "default": "1000",
30156	//       "description": "Maximum number of results to return.",
30157	//       "format": "int32",
30158	//       "location": "query",
30159	//       "maximum": "1000",
30160	//       "minimum": "0",
30161	//       "type": "integer"
30162	//     },
30163	//     "pageToken": {
30164	//       "description": "Value of the nextPageToken from the previous result page.",
30165	//       "location": "query",
30166	//       "type": "string"
30167	//     },
30168	//     "parentId": {
30169	//       "description": "Select only directory sites with this parent ID.",
30170	//       "format": "int64",
30171	//       "location": "query",
30172	//       "type": "string"
30173	//     },
30174	//     "profileId": {
30175	//       "description": "User profile ID associated with this request.",
30176	//       "format": "int64",
30177	//       "location": "path",
30178	//       "required": true,
30179	//       "type": "string"
30180	//     },
30181	//     "searchString": {
30182	//       "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\".",
30183	//       "location": "query",
30184	//       "type": "string"
30185	//     },
30186	//     "sortField": {
30187	//       "default": "ID",
30188	//       "description": "Field by which to sort the list.",
30189	//       "enum": [
30190	//         "ID",
30191	//         "NAME"
30192	//       ],
30193	//       "enumDescriptions": [
30194	//         "",
30195	//         ""
30196	//       ],
30197	//       "location": "query",
30198	//       "type": "string"
30199	//     },
30200	//     "sortOrder": {
30201	//       "default": "ASCENDING",
30202	//       "description": "Order of sorted results.",
30203	//       "enum": [
30204	//         "ASCENDING",
30205	//         "DESCENDING"
30206	//       ],
30207	//       "enumDescriptions": [
30208	//         "",
30209	//         ""
30210	//       ],
30211	//       "location": "query",
30212	//       "type": "string"
30213	//     }
30214	//   },
30215	//   "path": "userprofiles/{profileId}/directorySites",
30216	//   "response": {
30217	//     "$ref": "DirectorySitesListResponse"
30218	//   },
30219	//   "scopes": [
30220	//     "https://www.googleapis.com/auth/dfatrafficking"
30221	//   ]
30222	// }
30223
30224}
30225
30226// Pages invokes f for each page of results.
30227// A non-nil error returned from f will halt the iteration.
30228// The provided context supersedes any context provided to the Context method.
30229func (c *DirectorySitesListCall) Pages(ctx context.Context, f func(*DirectorySitesListResponse) error) error {
30230	c.ctx_ = ctx
30231	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
30232	for {
30233		x, err := c.Do()
30234		if err != nil {
30235			return err
30236		}
30237		if err := f(x); err != nil {
30238			return err
30239		}
30240		if x.NextPageToken == "" {
30241			return nil
30242		}
30243		c.PageToken(x.NextPageToken)
30244	}
30245}
30246
30247// method id "dfareporting.dynamicTargetingKeys.delete":
30248
30249type DynamicTargetingKeysDeleteCall struct {
30250	s          *Service
30251	profileId  int64
30252	objectId   int64
30253	urlParams_ gensupport.URLParams
30254	ctx_       context.Context
30255	header_    http.Header
30256}
30257
30258// Delete: Deletes an existing dynamic targeting key.
30259func (r *DynamicTargetingKeysService) Delete(profileId int64, objectId int64, name string, objectType string) *DynamicTargetingKeysDeleteCall {
30260	c := &DynamicTargetingKeysDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30261	c.profileId = profileId
30262	c.objectId = objectId
30263	c.urlParams_.Set("name", name)
30264	c.urlParams_.Set("objectType", objectType)
30265	return c
30266}
30267
30268// Fields allows partial responses to be retrieved. See
30269// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30270// for more information.
30271func (c *DynamicTargetingKeysDeleteCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysDeleteCall {
30272	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30273	return c
30274}
30275
30276// Context sets the context to be used in this call's Do method. Any
30277// pending HTTP request will be aborted if the provided context is
30278// canceled.
30279func (c *DynamicTargetingKeysDeleteCall) Context(ctx context.Context) *DynamicTargetingKeysDeleteCall {
30280	c.ctx_ = ctx
30281	return c
30282}
30283
30284// Header returns an http.Header that can be modified by the caller to
30285// add HTTP headers to the request.
30286func (c *DynamicTargetingKeysDeleteCall) Header() http.Header {
30287	if c.header_ == nil {
30288		c.header_ = make(http.Header)
30289	}
30290	return c.header_
30291}
30292
30293func (c *DynamicTargetingKeysDeleteCall) doRequest(alt string) (*http.Response, error) {
30294	reqHeaders := make(http.Header)
30295	for k, v := range c.header_ {
30296		reqHeaders[k] = v
30297	}
30298	reqHeaders.Set("User-Agent", c.s.userAgent())
30299	var body io.Reader = nil
30300	c.urlParams_.Set("alt", alt)
30301	c.urlParams_.Set("prettyPrint", "false")
30302	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys/{objectId}")
30303	urls += "?" + c.urlParams_.Encode()
30304	req, err := http.NewRequest("DELETE", urls, body)
30305	if err != nil {
30306		return nil, err
30307	}
30308	req.Header = reqHeaders
30309	googleapi.Expand(req.URL, map[string]string{
30310		"profileId": strconv.FormatInt(c.profileId, 10),
30311		"objectId":  strconv.FormatInt(c.objectId, 10),
30312	})
30313	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30314}
30315
30316// Do executes the "dfareporting.dynamicTargetingKeys.delete" call.
30317func (c *DynamicTargetingKeysDeleteCall) Do(opts ...googleapi.CallOption) error {
30318	gensupport.SetOptions(c.urlParams_, opts...)
30319	res, err := c.doRequest("json")
30320	if err != nil {
30321		return err
30322	}
30323	defer googleapi.CloseBody(res)
30324	if err := googleapi.CheckResponse(res); err != nil {
30325		return err
30326	}
30327	return nil
30328	// {
30329	//   "description": "Deletes an existing dynamic targeting key.",
30330	//   "httpMethod": "DELETE",
30331	//   "id": "dfareporting.dynamicTargetingKeys.delete",
30332	//   "parameterOrder": [
30333	//     "profileId",
30334	//     "objectId",
30335	//     "name",
30336	//     "objectType"
30337	//   ],
30338	//   "parameters": {
30339	//     "name": {
30340	//       "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.",
30341	//       "location": "query",
30342	//       "required": true,
30343	//       "type": "string"
30344	//     },
30345	//     "objectId": {
30346	//       "description": "ID of the object of this dynamic targeting key. This is a required field.",
30347	//       "format": "int64",
30348	//       "location": "path",
30349	//       "required": true,
30350	//       "type": "string"
30351	//     },
30352	//     "objectType": {
30353	//       "description": "Type of the object of this dynamic targeting key. This is a required field.",
30354	//       "enum": [
30355	//         "OBJECT_AD",
30356	//         "OBJECT_ADVERTISER",
30357	//         "OBJECT_CREATIVE",
30358	//         "OBJECT_PLACEMENT"
30359	//       ],
30360	//       "enumDescriptions": [
30361	//         "",
30362	//         "",
30363	//         "",
30364	//         ""
30365	//       ],
30366	//       "location": "query",
30367	//       "required": true,
30368	//       "type": "string"
30369	//     },
30370	//     "profileId": {
30371	//       "description": "User profile ID associated with this request.",
30372	//       "format": "int64",
30373	//       "location": "path",
30374	//       "required": true,
30375	//       "type": "string"
30376	//     }
30377	//   },
30378	//   "path": "userprofiles/{profileId}/dynamicTargetingKeys/{objectId}",
30379	//   "scopes": [
30380	//     "https://www.googleapis.com/auth/dfatrafficking"
30381	//   ]
30382	// }
30383
30384}
30385
30386// method id "dfareporting.dynamicTargetingKeys.insert":
30387
30388type DynamicTargetingKeysInsertCall struct {
30389	s                   *Service
30390	profileId           int64
30391	dynamictargetingkey *DynamicTargetingKey
30392	urlParams_          gensupport.URLParams
30393	ctx_                context.Context
30394	header_             http.Header
30395}
30396
30397// Insert: Inserts a new dynamic targeting key. Keys must be created at
30398// the advertiser level before being assigned to the advertiser's ads,
30399// creatives, or placements. There is a maximum of 1000 keys per
30400// advertiser, out of which a maximum of 20 keys can be assigned per ad,
30401// creative, or placement.
30402func (r *DynamicTargetingKeysService) Insert(profileId int64, dynamictargetingkey *DynamicTargetingKey) *DynamicTargetingKeysInsertCall {
30403	c := &DynamicTargetingKeysInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30404	c.profileId = profileId
30405	c.dynamictargetingkey = dynamictargetingkey
30406	return c
30407}
30408
30409// Fields allows partial responses to be retrieved. See
30410// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30411// for more information.
30412func (c *DynamicTargetingKeysInsertCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysInsertCall {
30413	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30414	return c
30415}
30416
30417// Context sets the context to be used in this call's Do method. Any
30418// pending HTTP request will be aborted if the provided context is
30419// canceled.
30420func (c *DynamicTargetingKeysInsertCall) Context(ctx context.Context) *DynamicTargetingKeysInsertCall {
30421	c.ctx_ = ctx
30422	return c
30423}
30424
30425// Header returns an http.Header that can be modified by the caller to
30426// add HTTP headers to the request.
30427func (c *DynamicTargetingKeysInsertCall) Header() http.Header {
30428	if c.header_ == nil {
30429		c.header_ = make(http.Header)
30430	}
30431	return c.header_
30432}
30433
30434func (c *DynamicTargetingKeysInsertCall) doRequest(alt string) (*http.Response, error) {
30435	reqHeaders := make(http.Header)
30436	for k, v := range c.header_ {
30437		reqHeaders[k] = v
30438	}
30439	reqHeaders.Set("User-Agent", c.s.userAgent())
30440	var body io.Reader = nil
30441	body, err := googleapi.WithoutDataWrapper.JSONReader(c.dynamictargetingkey)
30442	if err != nil {
30443		return nil, err
30444	}
30445	reqHeaders.Set("Content-Type", "application/json")
30446	c.urlParams_.Set("alt", alt)
30447	c.urlParams_.Set("prettyPrint", "false")
30448	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys")
30449	urls += "?" + c.urlParams_.Encode()
30450	req, err := http.NewRequest("POST", urls, body)
30451	if err != nil {
30452		return nil, err
30453	}
30454	req.Header = reqHeaders
30455	googleapi.Expand(req.URL, map[string]string{
30456		"profileId": strconv.FormatInt(c.profileId, 10),
30457	})
30458	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30459}
30460
30461// Do executes the "dfareporting.dynamicTargetingKeys.insert" call.
30462// Exactly one of *DynamicTargetingKey or error will be non-nil. Any
30463// non-2xx status code is an error. Response headers are in either
30464// *DynamicTargetingKey.ServerResponse.Header or (if a response was
30465// returned at all) in error.(*googleapi.Error).Header. Use
30466// googleapi.IsNotModified to check whether the returned error was
30467// because http.StatusNotModified was returned.
30468func (c *DynamicTargetingKeysInsertCall) Do(opts ...googleapi.CallOption) (*DynamicTargetingKey, error) {
30469	gensupport.SetOptions(c.urlParams_, opts...)
30470	res, err := c.doRequest("json")
30471	if res != nil && res.StatusCode == http.StatusNotModified {
30472		if res.Body != nil {
30473			res.Body.Close()
30474		}
30475		return nil, &googleapi.Error{
30476			Code:   res.StatusCode,
30477			Header: res.Header,
30478		}
30479	}
30480	if err != nil {
30481		return nil, err
30482	}
30483	defer googleapi.CloseBody(res)
30484	if err := googleapi.CheckResponse(res); err != nil {
30485		return nil, err
30486	}
30487	ret := &DynamicTargetingKey{
30488		ServerResponse: googleapi.ServerResponse{
30489			Header:         res.Header,
30490			HTTPStatusCode: res.StatusCode,
30491		},
30492	}
30493	target := &ret
30494	if err := gensupport.DecodeResponse(target, res); err != nil {
30495		return nil, err
30496	}
30497	return ret, nil
30498	// {
30499	//   "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.",
30500	//   "httpMethod": "POST",
30501	//   "id": "dfareporting.dynamicTargetingKeys.insert",
30502	//   "parameterOrder": [
30503	//     "profileId"
30504	//   ],
30505	//   "parameters": {
30506	//     "profileId": {
30507	//       "description": "User profile ID associated with this request.",
30508	//       "format": "int64",
30509	//       "location": "path",
30510	//       "required": true,
30511	//       "type": "string"
30512	//     }
30513	//   },
30514	//   "path": "userprofiles/{profileId}/dynamicTargetingKeys",
30515	//   "request": {
30516	//     "$ref": "DynamicTargetingKey"
30517	//   },
30518	//   "response": {
30519	//     "$ref": "DynamicTargetingKey"
30520	//   },
30521	//   "scopes": [
30522	//     "https://www.googleapis.com/auth/dfatrafficking"
30523	//   ]
30524	// }
30525
30526}
30527
30528// method id "dfareporting.dynamicTargetingKeys.list":
30529
30530type DynamicTargetingKeysListCall struct {
30531	s            *Service
30532	profileId    int64
30533	urlParams_   gensupport.URLParams
30534	ifNoneMatch_ string
30535	ctx_         context.Context
30536	header_      http.Header
30537}
30538
30539// List: Retrieves a list of dynamic targeting keys.
30540func (r *DynamicTargetingKeysService) List(profileId int64) *DynamicTargetingKeysListCall {
30541	c := &DynamicTargetingKeysListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30542	c.profileId = profileId
30543	return c
30544}
30545
30546// AdvertiserId sets the optional parameter "advertiserId": Select only
30547// dynamic targeting keys whose object has this advertiser ID.
30548func (c *DynamicTargetingKeysListCall) AdvertiserId(advertiserId int64) *DynamicTargetingKeysListCall {
30549	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
30550	return c
30551}
30552
30553// Names sets the optional parameter "names": Select only dynamic
30554// targeting keys exactly matching these names.
30555func (c *DynamicTargetingKeysListCall) Names(names ...string) *DynamicTargetingKeysListCall {
30556	c.urlParams_.SetMulti("names", append([]string{}, names...))
30557	return c
30558}
30559
30560// ObjectId sets the optional parameter "objectId": Select only dynamic
30561// targeting keys with this object ID.
30562func (c *DynamicTargetingKeysListCall) ObjectId(objectId int64) *DynamicTargetingKeysListCall {
30563	c.urlParams_.Set("objectId", fmt.Sprint(objectId))
30564	return c
30565}
30566
30567// ObjectType sets the optional parameter "objectType": Select only
30568// dynamic targeting keys with this object type.
30569//
30570// Possible values:
30571//   "OBJECT_AD"
30572//   "OBJECT_ADVERTISER"
30573//   "OBJECT_CREATIVE"
30574//   "OBJECT_PLACEMENT"
30575func (c *DynamicTargetingKeysListCall) ObjectType(objectType string) *DynamicTargetingKeysListCall {
30576	c.urlParams_.Set("objectType", objectType)
30577	return c
30578}
30579
30580// Fields allows partial responses to be retrieved. See
30581// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30582// for more information.
30583func (c *DynamicTargetingKeysListCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysListCall {
30584	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30585	return c
30586}
30587
30588// IfNoneMatch sets the optional parameter which makes the operation
30589// fail if the object's ETag matches the given value. This is useful for
30590// getting updates only after the object has changed since the last
30591// request. Use googleapi.IsNotModified to check whether the response
30592// error from Do is the result of In-None-Match.
30593func (c *DynamicTargetingKeysListCall) IfNoneMatch(entityTag string) *DynamicTargetingKeysListCall {
30594	c.ifNoneMatch_ = entityTag
30595	return c
30596}
30597
30598// Context sets the context to be used in this call's Do method. Any
30599// pending HTTP request will be aborted if the provided context is
30600// canceled.
30601func (c *DynamicTargetingKeysListCall) Context(ctx context.Context) *DynamicTargetingKeysListCall {
30602	c.ctx_ = ctx
30603	return c
30604}
30605
30606// Header returns an http.Header that can be modified by the caller to
30607// add HTTP headers to the request.
30608func (c *DynamicTargetingKeysListCall) Header() http.Header {
30609	if c.header_ == nil {
30610		c.header_ = make(http.Header)
30611	}
30612	return c.header_
30613}
30614
30615func (c *DynamicTargetingKeysListCall) doRequest(alt string) (*http.Response, error) {
30616	reqHeaders := make(http.Header)
30617	for k, v := range c.header_ {
30618		reqHeaders[k] = v
30619	}
30620	reqHeaders.Set("User-Agent", c.s.userAgent())
30621	if c.ifNoneMatch_ != "" {
30622		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30623	}
30624	var body io.Reader = nil
30625	c.urlParams_.Set("alt", alt)
30626	c.urlParams_.Set("prettyPrint", "false")
30627	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys")
30628	urls += "?" + c.urlParams_.Encode()
30629	req, err := http.NewRequest("GET", urls, body)
30630	if err != nil {
30631		return nil, err
30632	}
30633	req.Header = reqHeaders
30634	googleapi.Expand(req.URL, map[string]string{
30635		"profileId": strconv.FormatInt(c.profileId, 10),
30636	})
30637	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30638}
30639
30640// Do executes the "dfareporting.dynamicTargetingKeys.list" call.
30641// Exactly one of *DynamicTargetingKeysListResponse or error will be
30642// non-nil. Any non-2xx status code is an error. Response headers are in
30643// either *DynamicTargetingKeysListResponse.ServerResponse.Header or (if
30644// a response was returned at all) in error.(*googleapi.Error).Header.
30645// Use googleapi.IsNotModified to check whether the returned error was
30646// because http.StatusNotModified was returned.
30647func (c *DynamicTargetingKeysListCall) Do(opts ...googleapi.CallOption) (*DynamicTargetingKeysListResponse, error) {
30648	gensupport.SetOptions(c.urlParams_, opts...)
30649	res, err := c.doRequest("json")
30650	if res != nil && res.StatusCode == http.StatusNotModified {
30651		if res.Body != nil {
30652			res.Body.Close()
30653		}
30654		return nil, &googleapi.Error{
30655			Code:   res.StatusCode,
30656			Header: res.Header,
30657		}
30658	}
30659	if err != nil {
30660		return nil, err
30661	}
30662	defer googleapi.CloseBody(res)
30663	if err := googleapi.CheckResponse(res); err != nil {
30664		return nil, err
30665	}
30666	ret := &DynamicTargetingKeysListResponse{
30667		ServerResponse: googleapi.ServerResponse{
30668			Header:         res.Header,
30669			HTTPStatusCode: res.StatusCode,
30670		},
30671	}
30672	target := &ret
30673	if err := gensupport.DecodeResponse(target, res); err != nil {
30674		return nil, err
30675	}
30676	return ret, nil
30677	// {
30678	//   "description": "Retrieves a list of dynamic targeting keys.",
30679	//   "httpMethod": "GET",
30680	//   "id": "dfareporting.dynamicTargetingKeys.list",
30681	//   "parameterOrder": [
30682	//     "profileId"
30683	//   ],
30684	//   "parameters": {
30685	//     "advertiserId": {
30686	//       "description": "Select only dynamic targeting keys whose object has this advertiser ID.",
30687	//       "format": "int64",
30688	//       "location": "query",
30689	//       "type": "string"
30690	//     },
30691	//     "names": {
30692	//       "description": "Select only dynamic targeting keys exactly matching these names.",
30693	//       "location": "query",
30694	//       "repeated": true,
30695	//       "type": "string"
30696	//     },
30697	//     "objectId": {
30698	//       "description": "Select only dynamic targeting keys with this object ID.",
30699	//       "format": "int64",
30700	//       "location": "query",
30701	//       "type": "string"
30702	//     },
30703	//     "objectType": {
30704	//       "description": "Select only dynamic targeting keys with this object type.",
30705	//       "enum": [
30706	//         "OBJECT_AD",
30707	//         "OBJECT_ADVERTISER",
30708	//         "OBJECT_CREATIVE",
30709	//         "OBJECT_PLACEMENT"
30710	//       ],
30711	//       "enumDescriptions": [
30712	//         "",
30713	//         "",
30714	//         "",
30715	//         ""
30716	//       ],
30717	//       "location": "query",
30718	//       "type": "string"
30719	//     },
30720	//     "profileId": {
30721	//       "description": "User profile ID associated with this request.",
30722	//       "format": "int64",
30723	//       "location": "path",
30724	//       "required": true,
30725	//       "type": "string"
30726	//     }
30727	//   },
30728	//   "path": "userprofiles/{profileId}/dynamicTargetingKeys",
30729	//   "response": {
30730	//     "$ref": "DynamicTargetingKeysListResponse"
30731	//   },
30732	//   "scopes": [
30733	//     "https://www.googleapis.com/auth/dfatrafficking"
30734	//   ]
30735	// }
30736
30737}
30738
30739// method id "dfareporting.eventTags.delete":
30740
30741type EventTagsDeleteCall struct {
30742	s          *Service
30743	profileId  int64
30744	id         int64
30745	urlParams_ gensupport.URLParams
30746	ctx_       context.Context
30747	header_    http.Header
30748}
30749
30750// Delete: Deletes an existing event tag.
30751func (r *EventTagsService) Delete(profileId int64, id int64) *EventTagsDeleteCall {
30752	c := &EventTagsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30753	c.profileId = profileId
30754	c.id = id
30755	return c
30756}
30757
30758// Fields allows partial responses to be retrieved. See
30759// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30760// for more information.
30761func (c *EventTagsDeleteCall) Fields(s ...googleapi.Field) *EventTagsDeleteCall {
30762	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30763	return c
30764}
30765
30766// Context sets the context to be used in this call's Do method. Any
30767// pending HTTP request will be aborted if the provided context is
30768// canceled.
30769func (c *EventTagsDeleteCall) Context(ctx context.Context) *EventTagsDeleteCall {
30770	c.ctx_ = ctx
30771	return c
30772}
30773
30774// Header returns an http.Header that can be modified by the caller to
30775// add HTTP headers to the request.
30776func (c *EventTagsDeleteCall) Header() http.Header {
30777	if c.header_ == nil {
30778		c.header_ = make(http.Header)
30779	}
30780	return c.header_
30781}
30782
30783func (c *EventTagsDeleteCall) doRequest(alt string) (*http.Response, error) {
30784	reqHeaders := make(http.Header)
30785	for k, v := range c.header_ {
30786		reqHeaders[k] = v
30787	}
30788	reqHeaders.Set("User-Agent", c.s.userAgent())
30789	var body io.Reader = nil
30790	c.urlParams_.Set("alt", alt)
30791	c.urlParams_.Set("prettyPrint", "false")
30792	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags/{id}")
30793	urls += "?" + c.urlParams_.Encode()
30794	req, err := http.NewRequest("DELETE", urls, body)
30795	if err != nil {
30796		return nil, err
30797	}
30798	req.Header = reqHeaders
30799	googleapi.Expand(req.URL, map[string]string{
30800		"profileId": strconv.FormatInt(c.profileId, 10),
30801		"id":        strconv.FormatInt(c.id, 10),
30802	})
30803	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30804}
30805
30806// Do executes the "dfareporting.eventTags.delete" call.
30807func (c *EventTagsDeleteCall) Do(opts ...googleapi.CallOption) error {
30808	gensupport.SetOptions(c.urlParams_, opts...)
30809	res, err := c.doRequest("json")
30810	if err != nil {
30811		return err
30812	}
30813	defer googleapi.CloseBody(res)
30814	if err := googleapi.CheckResponse(res); err != nil {
30815		return err
30816	}
30817	return nil
30818	// {
30819	//   "description": "Deletes an existing event tag.",
30820	//   "httpMethod": "DELETE",
30821	//   "id": "dfareporting.eventTags.delete",
30822	//   "parameterOrder": [
30823	//     "profileId",
30824	//     "id"
30825	//   ],
30826	//   "parameters": {
30827	//     "id": {
30828	//       "description": "Event tag ID.",
30829	//       "format": "int64",
30830	//       "location": "path",
30831	//       "required": true,
30832	//       "type": "string"
30833	//     },
30834	//     "profileId": {
30835	//       "description": "User profile ID associated with this request.",
30836	//       "format": "int64",
30837	//       "location": "path",
30838	//       "required": true,
30839	//       "type": "string"
30840	//     }
30841	//   },
30842	//   "path": "userprofiles/{profileId}/eventTags/{id}",
30843	//   "scopes": [
30844	//     "https://www.googleapis.com/auth/dfatrafficking"
30845	//   ]
30846	// }
30847
30848}
30849
30850// method id "dfareporting.eventTags.get":
30851
30852type EventTagsGetCall struct {
30853	s            *Service
30854	profileId    int64
30855	id           int64
30856	urlParams_   gensupport.URLParams
30857	ifNoneMatch_ string
30858	ctx_         context.Context
30859	header_      http.Header
30860}
30861
30862// Get: Gets one event tag by ID.
30863func (r *EventTagsService) Get(profileId int64, id int64) *EventTagsGetCall {
30864	c := &EventTagsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30865	c.profileId = profileId
30866	c.id = id
30867	return c
30868}
30869
30870// Fields allows partial responses to be retrieved. See
30871// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30872// for more information.
30873func (c *EventTagsGetCall) Fields(s ...googleapi.Field) *EventTagsGetCall {
30874	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30875	return c
30876}
30877
30878// IfNoneMatch sets the optional parameter which makes the operation
30879// fail if the object's ETag matches the given value. This is useful for
30880// getting updates only after the object has changed since the last
30881// request. Use googleapi.IsNotModified to check whether the response
30882// error from Do is the result of In-None-Match.
30883func (c *EventTagsGetCall) IfNoneMatch(entityTag string) *EventTagsGetCall {
30884	c.ifNoneMatch_ = entityTag
30885	return c
30886}
30887
30888// Context sets the context to be used in this call's Do method. Any
30889// pending HTTP request will be aborted if the provided context is
30890// canceled.
30891func (c *EventTagsGetCall) Context(ctx context.Context) *EventTagsGetCall {
30892	c.ctx_ = ctx
30893	return c
30894}
30895
30896// Header returns an http.Header that can be modified by the caller to
30897// add HTTP headers to the request.
30898func (c *EventTagsGetCall) Header() http.Header {
30899	if c.header_ == nil {
30900		c.header_ = make(http.Header)
30901	}
30902	return c.header_
30903}
30904
30905func (c *EventTagsGetCall) doRequest(alt string) (*http.Response, error) {
30906	reqHeaders := make(http.Header)
30907	for k, v := range c.header_ {
30908		reqHeaders[k] = v
30909	}
30910	reqHeaders.Set("User-Agent", c.s.userAgent())
30911	if c.ifNoneMatch_ != "" {
30912		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30913	}
30914	var body io.Reader = nil
30915	c.urlParams_.Set("alt", alt)
30916	c.urlParams_.Set("prettyPrint", "false")
30917	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags/{id}")
30918	urls += "?" + c.urlParams_.Encode()
30919	req, err := http.NewRequest("GET", urls, body)
30920	if err != nil {
30921		return nil, err
30922	}
30923	req.Header = reqHeaders
30924	googleapi.Expand(req.URL, map[string]string{
30925		"profileId": strconv.FormatInt(c.profileId, 10),
30926		"id":        strconv.FormatInt(c.id, 10),
30927	})
30928	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30929}
30930
30931// Do executes the "dfareporting.eventTags.get" call.
30932// Exactly one of *EventTag or error will be non-nil. Any non-2xx status
30933// code is an error. Response headers are in either
30934// *EventTag.ServerResponse.Header or (if a response was returned at
30935// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
30936// to check whether the returned error was because
30937// http.StatusNotModified was returned.
30938func (c *EventTagsGetCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
30939	gensupport.SetOptions(c.urlParams_, opts...)
30940	res, err := c.doRequest("json")
30941	if res != nil && res.StatusCode == http.StatusNotModified {
30942		if res.Body != nil {
30943			res.Body.Close()
30944		}
30945		return nil, &googleapi.Error{
30946			Code:   res.StatusCode,
30947			Header: res.Header,
30948		}
30949	}
30950	if err != nil {
30951		return nil, err
30952	}
30953	defer googleapi.CloseBody(res)
30954	if err := googleapi.CheckResponse(res); err != nil {
30955		return nil, err
30956	}
30957	ret := &EventTag{
30958		ServerResponse: googleapi.ServerResponse{
30959			Header:         res.Header,
30960			HTTPStatusCode: res.StatusCode,
30961		},
30962	}
30963	target := &ret
30964	if err := gensupport.DecodeResponse(target, res); err != nil {
30965		return nil, err
30966	}
30967	return ret, nil
30968	// {
30969	//   "description": "Gets one event tag by ID.",
30970	//   "httpMethod": "GET",
30971	//   "id": "dfareporting.eventTags.get",
30972	//   "parameterOrder": [
30973	//     "profileId",
30974	//     "id"
30975	//   ],
30976	//   "parameters": {
30977	//     "id": {
30978	//       "description": "Event tag ID.",
30979	//       "format": "int64",
30980	//       "location": "path",
30981	//       "required": true,
30982	//       "type": "string"
30983	//     },
30984	//     "profileId": {
30985	//       "description": "User profile ID associated with this request.",
30986	//       "format": "int64",
30987	//       "location": "path",
30988	//       "required": true,
30989	//       "type": "string"
30990	//     }
30991	//   },
30992	//   "path": "userprofiles/{profileId}/eventTags/{id}",
30993	//   "response": {
30994	//     "$ref": "EventTag"
30995	//   },
30996	//   "scopes": [
30997	//     "https://www.googleapis.com/auth/dfatrafficking"
30998	//   ]
30999	// }
31000
31001}
31002
31003// method id "dfareporting.eventTags.insert":
31004
31005type EventTagsInsertCall struct {
31006	s          *Service
31007	profileId  int64
31008	eventtag   *EventTag
31009	urlParams_ gensupport.URLParams
31010	ctx_       context.Context
31011	header_    http.Header
31012}
31013
31014// Insert: Inserts a new event tag.
31015func (r *EventTagsService) Insert(profileId int64, eventtag *EventTag) *EventTagsInsertCall {
31016	c := &EventTagsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31017	c.profileId = profileId
31018	c.eventtag = eventtag
31019	return c
31020}
31021
31022// Fields allows partial responses to be retrieved. See
31023// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31024// for more information.
31025func (c *EventTagsInsertCall) Fields(s ...googleapi.Field) *EventTagsInsertCall {
31026	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31027	return c
31028}
31029
31030// Context sets the context to be used in this call's Do method. Any
31031// pending HTTP request will be aborted if the provided context is
31032// canceled.
31033func (c *EventTagsInsertCall) Context(ctx context.Context) *EventTagsInsertCall {
31034	c.ctx_ = ctx
31035	return c
31036}
31037
31038// Header returns an http.Header that can be modified by the caller to
31039// add HTTP headers to the request.
31040func (c *EventTagsInsertCall) Header() http.Header {
31041	if c.header_ == nil {
31042		c.header_ = make(http.Header)
31043	}
31044	return c.header_
31045}
31046
31047func (c *EventTagsInsertCall) doRequest(alt string) (*http.Response, error) {
31048	reqHeaders := make(http.Header)
31049	for k, v := range c.header_ {
31050		reqHeaders[k] = v
31051	}
31052	reqHeaders.Set("User-Agent", c.s.userAgent())
31053	var body io.Reader = nil
31054	body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31055	if err != nil {
31056		return nil, err
31057	}
31058	reqHeaders.Set("Content-Type", "application/json")
31059	c.urlParams_.Set("alt", alt)
31060	c.urlParams_.Set("prettyPrint", "false")
31061	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31062	urls += "?" + c.urlParams_.Encode()
31063	req, err := http.NewRequest("POST", urls, body)
31064	if err != nil {
31065		return nil, err
31066	}
31067	req.Header = reqHeaders
31068	googleapi.Expand(req.URL, map[string]string{
31069		"profileId": strconv.FormatInt(c.profileId, 10),
31070	})
31071	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31072}
31073
31074// Do executes the "dfareporting.eventTags.insert" call.
31075// Exactly one of *EventTag or error will be non-nil. Any non-2xx status
31076// code is an error. Response headers are in either
31077// *EventTag.ServerResponse.Header or (if a response was returned at
31078// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
31079// to check whether the returned error was because
31080// http.StatusNotModified was returned.
31081func (c *EventTagsInsertCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31082	gensupport.SetOptions(c.urlParams_, opts...)
31083	res, err := c.doRequest("json")
31084	if res != nil && res.StatusCode == http.StatusNotModified {
31085		if res.Body != nil {
31086			res.Body.Close()
31087		}
31088		return nil, &googleapi.Error{
31089			Code:   res.StatusCode,
31090			Header: res.Header,
31091		}
31092	}
31093	if err != nil {
31094		return nil, err
31095	}
31096	defer googleapi.CloseBody(res)
31097	if err := googleapi.CheckResponse(res); err != nil {
31098		return nil, err
31099	}
31100	ret := &EventTag{
31101		ServerResponse: googleapi.ServerResponse{
31102			Header:         res.Header,
31103			HTTPStatusCode: res.StatusCode,
31104		},
31105	}
31106	target := &ret
31107	if err := gensupport.DecodeResponse(target, res); err != nil {
31108		return nil, err
31109	}
31110	return ret, nil
31111	// {
31112	//   "description": "Inserts a new event tag.",
31113	//   "httpMethod": "POST",
31114	//   "id": "dfareporting.eventTags.insert",
31115	//   "parameterOrder": [
31116	//     "profileId"
31117	//   ],
31118	//   "parameters": {
31119	//     "profileId": {
31120	//       "description": "User profile ID associated with this request.",
31121	//       "format": "int64",
31122	//       "location": "path",
31123	//       "required": true,
31124	//       "type": "string"
31125	//     }
31126	//   },
31127	//   "path": "userprofiles/{profileId}/eventTags",
31128	//   "request": {
31129	//     "$ref": "EventTag"
31130	//   },
31131	//   "response": {
31132	//     "$ref": "EventTag"
31133	//   },
31134	//   "scopes": [
31135	//     "https://www.googleapis.com/auth/dfatrafficking"
31136	//   ]
31137	// }
31138
31139}
31140
31141// method id "dfareporting.eventTags.list":
31142
31143type EventTagsListCall struct {
31144	s            *Service
31145	profileId    int64
31146	urlParams_   gensupport.URLParams
31147	ifNoneMatch_ string
31148	ctx_         context.Context
31149	header_      http.Header
31150}
31151
31152// List: Retrieves a list of event tags, possibly filtered.
31153func (r *EventTagsService) List(profileId int64) *EventTagsListCall {
31154	c := &EventTagsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31155	c.profileId = profileId
31156	return c
31157}
31158
31159// AdId sets the optional parameter "adId": Select only event tags that
31160// belong to this ad.
31161func (c *EventTagsListCall) AdId(adId int64) *EventTagsListCall {
31162	c.urlParams_.Set("adId", fmt.Sprint(adId))
31163	return c
31164}
31165
31166// AdvertiserId sets the optional parameter "advertiserId": Select only
31167// event tags that belong to this advertiser.
31168func (c *EventTagsListCall) AdvertiserId(advertiserId int64) *EventTagsListCall {
31169	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
31170	return c
31171}
31172
31173// CampaignId sets the optional parameter "campaignId": Select only
31174// event tags that belong to this campaign.
31175func (c *EventTagsListCall) CampaignId(campaignId int64) *EventTagsListCall {
31176	c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
31177	return c
31178}
31179
31180// DefinitionsOnly sets the optional parameter "definitionsOnly":
31181// Examine only the specified campaign or advertiser's event tags for
31182// matching selector criteria. When set to false, the parent advertiser
31183// and parent campaign of the specified ad or campaign is examined as
31184// well. In addition, when set to false, the status field is examined as
31185// well, along with the enabledByDefault field. This parameter can not
31186// be set to true when adId is specified as ads do not define their own
31187// even tags.
31188func (c *EventTagsListCall) DefinitionsOnly(definitionsOnly bool) *EventTagsListCall {
31189	c.urlParams_.Set("definitionsOnly", fmt.Sprint(definitionsOnly))
31190	return c
31191}
31192
31193// Enabled sets the optional parameter "enabled": Select only enabled
31194// event tags. What is considered enabled or disabled depends on the
31195// definitionsOnly parameter. When definitionsOnly is set to true, only
31196// the specified advertiser or campaign's event tags' enabledByDefault
31197// field is examined. When definitionsOnly is set to false, the
31198// specified ad or specified campaign's parent advertiser's or parent
31199// campaign's event tags' enabledByDefault and status fields are
31200// examined as well.
31201func (c *EventTagsListCall) Enabled(enabled bool) *EventTagsListCall {
31202	c.urlParams_.Set("enabled", fmt.Sprint(enabled))
31203	return c
31204}
31205
31206// EventTagTypes sets the optional parameter "eventTagTypes": Select
31207// only event tags with the specified event tag types. Event tag types
31208// can be used to specify whether to use a third-party pixel, a
31209// third-party JavaScript URL, or a third-party click-through URL for
31210// either impression or click tracking.
31211//
31212// Possible values:
31213//   "CLICK_THROUGH_EVENT_TAG"
31214//   "IMPRESSION_IMAGE_EVENT_TAG"
31215//   "IMPRESSION_JAVASCRIPT_EVENT_TAG"
31216func (c *EventTagsListCall) EventTagTypes(eventTagTypes ...string) *EventTagsListCall {
31217	c.urlParams_.SetMulti("eventTagTypes", append([]string{}, eventTagTypes...))
31218	return c
31219}
31220
31221// Ids sets the optional parameter "ids": Select only event tags with
31222// these IDs.
31223func (c *EventTagsListCall) Ids(ids ...int64) *EventTagsListCall {
31224	var ids_ []string
31225	for _, v := range ids {
31226		ids_ = append(ids_, fmt.Sprint(v))
31227	}
31228	c.urlParams_.SetMulti("ids", ids_)
31229	return c
31230}
31231
31232// SearchString sets the optional parameter "searchString": Allows
31233// searching for objects by name or ID. Wildcards (*) are allowed. For
31234// example, "eventtag*2015" will return objects with names like
31235// "eventtag June 2015", "eventtag April 2015", or simply "eventtag
31236// 2015". Most of the searches also add wildcards implicitly at the
31237// start and the end of the search string. For example, a search string
31238// of "eventtag" will match objects with name "my eventtag", "eventtag
31239// 2015", or simply "eventtag".
31240func (c *EventTagsListCall) SearchString(searchString string) *EventTagsListCall {
31241	c.urlParams_.Set("searchString", searchString)
31242	return c
31243}
31244
31245// SortField sets the optional parameter "sortField": Field by which to
31246// sort the list.
31247//
31248// Possible values:
31249//   "ID" (default)
31250//   "NAME"
31251func (c *EventTagsListCall) SortField(sortField string) *EventTagsListCall {
31252	c.urlParams_.Set("sortField", sortField)
31253	return c
31254}
31255
31256// SortOrder sets the optional parameter "sortOrder": Order of sorted
31257// results.
31258//
31259// Possible values:
31260//   "ASCENDING" (default)
31261//   "DESCENDING"
31262func (c *EventTagsListCall) SortOrder(sortOrder string) *EventTagsListCall {
31263	c.urlParams_.Set("sortOrder", sortOrder)
31264	return c
31265}
31266
31267// Fields allows partial responses to be retrieved. See
31268// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31269// for more information.
31270func (c *EventTagsListCall) Fields(s ...googleapi.Field) *EventTagsListCall {
31271	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31272	return c
31273}
31274
31275// IfNoneMatch sets the optional parameter which makes the operation
31276// fail if the object's ETag matches the given value. This is useful for
31277// getting updates only after the object has changed since the last
31278// request. Use googleapi.IsNotModified to check whether the response
31279// error from Do is the result of In-None-Match.
31280func (c *EventTagsListCall) IfNoneMatch(entityTag string) *EventTagsListCall {
31281	c.ifNoneMatch_ = entityTag
31282	return c
31283}
31284
31285// Context sets the context to be used in this call's Do method. Any
31286// pending HTTP request will be aborted if the provided context is
31287// canceled.
31288func (c *EventTagsListCall) Context(ctx context.Context) *EventTagsListCall {
31289	c.ctx_ = ctx
31290	return c
31291}
31292
31293// Header returns an http.Header that can be modified by the caller to
31294// add HTTP headers to the request.
31295func (c *EventTagsListCall) Header() http.Header {
31296	if c.header_ == nil {
31297		c.header_ = make(http.Header)
31298	}
31299	return c.header_
31300}
31301
31302func (c *EventTagsListCall) doRequest(alt string) (*http.Response, error) {
31303	reqHeaders := make(http.Header)
31304	for k, v := range c.header_ {
31305		reqHeaders[k] = v
31306	}
31307	reqHeaders.Set("User-Agent", c.s.userAgent())
31308	if c.ifNoneMatch_ != "" {
31309		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31310	}
31311	var body io.Reader = nil
31312	c.urlParams_.Set("alt", alt)
31313	c.urlParams_.Set("prettyPrint", "false")
31314	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31315	urls += "?" + c.urlParams_.Encode()
31316	req, err := http.NewRequest("GET", urls, body)
31317	if err != nil {
31318		return nil, err
31319	}
31320	req.Header = reqHeaders
31321	googleapi.Expand(req.URL, map[string]string{
31322		"profileId": strconv.FormatInt(c.profileId, 10),
31323	})
31324	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31325}
31326
31327// Do executes the "dfareporting.eventTags.list" call.
31328// Exactly one of *EventTagsListResponse or error will be non-nil. Any
31329// non-2xx status code is an error. Response headers are in either
31330// *EventTagsListResponse.ServerResponse.Header or (if a response was
31331// returned at all) in error.(*googleapi.Error).Header. Use
31332// googleapi.IsNotModified to check whether the returned error was
31333// because http.StatusNotModified was returned.
31334func (c *EventTagsListCall) Do(opts ...googleapi.CallOption) (*EventTagsListResponse, error) {
31335	gensupport.SetOptions(c.urlParams_, opts...)
31336	res, err := c.doRequest("json")
31337	if res != nil && res.StatusCode == http.StatusNotModified {
31338		if res.Body != nil {
31339			res.Body.Close()
31340		}
31341		return nil, &googleapi.Error{
31342			Code:   res.StatusCode,
31343			Header: res.Header,
31344		}
31345	}
31346	if err != nil {
31347		return nil, err
31348	}
31349	defer googleapi.CloseBody(res)
31350	if err := googleapi.CheckResponse(res); err != nil {
31351		return nil, err
31352	}
31353	ret := &EventTagsListResponse{
31354		ServerResponse: googleapi.ServerResponse{
31355			Header:         res.Header,
31356			HTTPStatusCode: res.StatusCode,
31357		},
31358	}
31359	target := &ret
31360	if err := gensupport.DecodeResponse(target, res); err != nil {
31361		return nil, err
31362	}
31363	return ret, nil
31364	// {
31365	//   "description": "Retrieves a list of event tags, possibly filtered.",
31366	//   "httpMethod": "GET",
31367	//   "id": "dfareporting.eventTags.list",
31368	//   "parameterOrder": [
31369	//     "profileId"
31370	//   ],
31371	//   "parameters": {
31372	//     "adId": {
31373	//       "description": "Select only event tags that belong to this ad.",
31374	//       "format": "int64",
31375	//       "location": "query",
31376	//       "type": "string"
31377	//     },
31378	//     "advertiserId": {
31379	//       "description": "Select only event tags that belong to this advertiser.",
31380	//       "format": "int64",
31381	//       "location": "query",
31382	//       "type": "string"
31383	//     },
31384	//     "campaignId": {
31385	//       "description": "Select only event tags that belong to this campaign.",
31386	//       "format": "int64",
31387	//       "location": "query",
31388	//       "type": "string"
31389	//     },
31390	//     "definitionsOnly": {
31391	//       "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.",
31392	//       "location": "query",
31393	//       "type": "boolean"
31394	//     },
31395	//     "enabled": {
31396	//       "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.",
31397	//       "location": "query",
31398	//       "type": "boolean"
31399	//     },
31400	//     "eventTagTypes": {
31401	//       "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.",
31402	//       "enum": [
31403	//         "CLICK_THROUGH_EVENT_TAG",
31404	//         "IMPRESSION_IMAGE_EVENT_TAG",
31405	//         "IMPRESSION_JAVASCRIPT_EVENT_TAG"
31406	//       ],
31407	//       "enumDescriptions": [
31408	//         "",
31409	//         "",
31410	//         ""
31411	//       ],
31412	//       "location": "query",
31413	//       "repeated": true,
31414	//       "type": "string"
31415	//     },
31416	//     "ids": {
31417	//       "description": "Select only event tags with these IDs.",
31418	//       "format": "int64",
31419	//       "location": "query",
31420	//       "repeated": true,
31421	//       "type": "string"
31422	//     },
31423	//     "profileId": {
31424	//       "description": "User profile ID associated with this request.",
31425	//       "format": "int64",
31426	//       "location": "path",
31427	//       "required": true,
31428	//       "type": "string"
31429	//     },
31430	//     "searchString": {
31431	//       "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\".",
31432	//       "location": "query",
31433	//       "type": "string"
31434	//     },
31435	//     "sortField": {
31436	//       "default": "ID",
31437	//       "description": "Field by which to sort the list.",
31438	//       "enum": [
31439	//         "ID",
31440	//         "NAME"
31441	//       ],
31442	//       "enumDescriptions": [
31443	//         "",
31444	//         ""
31445	//       ],
31446	//       "location": "query",
31447	//       "type": "string"
31448	//     },
31449	//     "sortOrder": {
31450	//       "default": "ASCENDING",
31451	//       "description": "Order of sorted results.",
31452	//       "enum": [
31453	//         "ASCENDING",
31454	//         "DESCENDING"
31455	//       ],
31456	//       "enumDescriptions": [
31457	//         "",
31458	//         ""
31459	//       ],
31460	//       "location": "query",
31461	//       "type": "string"
31462	//     }
31463	//   },
31464	//   "path": "userprofiles/{profileId}/eventTags",
31465	//   "response": {
31466	//     "$ref": "EventTagsListResponse"
31467	//   },
31468	//   "scopes": [
31469	//     "https://www.googleapis.com/auth/dfatrafficking"
31470	//   ]
31471	// }
31472
31473}
31474
31475// method id "dfareporting.eventTags.patch":
31476
31477type EventTagsPatchCall struct {
31478	s          *Service
31479	profileId  int64
31480	eventtag   *EventTag
31481	urlParams_ gensupport.URLParams
31482	ctx_       context.Context
31483	header_    http.Header
31484}
31485
31486// Patch: Updates an existing event tag. This method supports patch
31487// semantics.
31488func (r *EventTagsService) Patch(profileId int64, id int64, eventtag *EventTag) *EventTagsPatchCall {
31489	c := &EventTagsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31490	c.profileId = profileId
31491	c.urlParams_.Set("id", fmt.Sprint(id))
31492	c.eventtag = eventtag
31493	return c
31494}
31495
31496// Fields allows partial responses to be retrieved. See
31497// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31498// for more information.
31499func (c *EventTagsPatchCall) Fields(s ...googleapi.Field) *EventTagsPatchCall {
31500	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31501	return c
31502}
31503
31504// Context sets the context to be used in this call's Do method. Any
31505// pending HTTP request will be aborted if the provided context is
31506// canceled.
31507func (c *EventTagsPatchCall) Context(ctx context.Context) *EventTagsPatchCall {
31508	c.ctx_ = ctx
31509	return c
31510}
31511
31512// Header returns an http.Header that can be modified by the caller to
31513// add HTTP headers to the request.
31514func (c *EventTagsPatchCall) Header() http.Header {
31515	if c.header_ == nil {
31516		c.header_ = make(http.Header)
31517	}
31518	return c.header_
31519}
31520
31521func (c *EventTagsPatchCall) doRequest(alt string) (*http.Response, error) {
31522	reqHeaders := make(http.Header)
31523	for k, v := range c.header_ {
31524		reqHeaders[k] = v
31525	}
31526	reqHeaders.Set("User-Agent", c.s.userAgent())
31527	var body io.Reader = nil
31528	body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31529	if err != nil {
31530		return nil, err
31531	}
31532	reqHeaders.Set("Content-Type", "application/json")
31533	c.urlParams_.Set("alt", alt)
31534	c.urlParams_.Set("prettyPrint", "false")
31535	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31536	urls += "?" + c.urlParams_.Encode()
31537	req, err := http.NewRequest("PATCH", urls, body)
31538	if err != nil {
31539		return nil, err
31540	}
31541	req.Header = reqHeaders
31542	googleapi.Expand(req.URL, map[string]string{
31543		"profileId": strconv.FormatInt(c.profileId, 10),
31544	})
31545	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31546}
31547
31548// Do executes the "dfareporting.eventTags.patch" call.
31549// Exactly one of *EventTag or error will be non-nil. Any non-2xx status
31550// code is an error. Response headers are in either
31551// *EventTag.ServerResponse.Header or (if a response was returned at
31552// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
31553// to check whether the returned error was because
31554// http.StatusNotModified was returned.
31555func (c *EventTagsPatchCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31556	gensupport.SetOptions(c.urlParams_, opts...)
31557	res, err := c.doRequest("json")
31558	if res != nil && res.StatusCode == http.StatusNotModified {
31559		if res.Body != nil {
31560			res.Body.Close()
31561		}
31562		return nil, &googleapi.Error{
31563			Code:   res.StatusCode,
31564			Header: res.Header,
31565		}
31566	}
31567	if err != nil {
31568		return nil, err
31569	}
31570	defer googleapi.CloseBody(res)
31571	if err := googleapi.CheckResponse(res); err != nil {
31572		return nil, err
31573	}
31574	ret := &EventTag{
31575		ServerResponse: googleapi.ServerResponse{
31576			Header:         res.Header,
31577			HTTPStatusCode: res.StatusCode,
31578		},
31579	}
31580	target := &ret
31581	if err := gensupport.DecodeResponse(target, res); err != nil {
31582		return nil, err
31583	}
31584	return ret, nil
31585	// {
31586	//   "description": "Updates an existing event tag. This method supports patch semantics.",
31587	//   "httpMethod": "PATCH",
31588	//   "id": "dfareporting.eventTags.patch",
31589	//   "parameterOrder": [
31590	//     "profileId",
31591	//     "id"
31592	//   ],
31593	//   "parameters": {
31594	//     "id": {
31595	//       "description": "Event tag ID.",
31596	//       "format": "int64",
31597	//       "location": "query",
31598	//       "required": true,
31599	//       "type": "string"
31600	//     },
31601	//     "profileId": {
31602	//       "description": "User profile ID associated with this request.",
31603	//       "format": "int64",
31604	//       "location": "path",
31605	//       "required": true,
31606	//       "type": "string"
31607	//     }
31608	//   },
31609	//   "path": "userprofiles/{profileId}/eventTags",
31610	//   "request": {
31611	//     "$ref": "EventTag"
31612	//   },
31613	//   "response": {
31614	//     "$ref": "EventTag"
31615	//   },
31616	//   "scopes": [
31617	//     "https://www.googleapis.com/auth/dfatrafficking"
31618	//   ]
31619	// }
31620
31621}
31622
31623// method id "dfareporting.eventTags.update":
31624
31625type EventTagsUpdateCall struct {
31626	s          *Service
31627	profileId  int64
31628	eventtag   *EventTag
31629	urlParams_ gensupport.URLParams
31630	ctx_       context.Context
31631	header_    http.Header
31632}
31633
31634// Update: Updates an existing event tag.
31635func (r *EventTagsService) Update(profileId int64, eventtag *EventTag) *EventTagsUpdateCall {
31636	c := &EventTagsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31637	c.profileId = profileId
31638	c.eventtag = eventtag
31639	return c
31640}
31641
31642// Fields allows partial responses to be retrieved. See
31643// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31644// for more information.
31645func (c *EventTagsUpdateCall) Fields(s ...googleapi.Field) *EventTagsUpdateCall {
31646	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31647	return c
31648}
31649
31650// Context sets the context to be used in this call's Do method. Any
31651// pending HTTP request will be aborted if the provided context is
31652// canceled.
31653func (c *EventTagsUpdateCall) Context(ctx context.Context) *EventTagsUpdateCall {
31654	c.ctx_ = ctx
31655	return c
31656}
31657
31658// Header returns an http.Header that can be modified by the caller to
31659// add HTTP headers to the request.
31660func (c *EventTagsUpdateCall) Header() http.Header {
31661	if c.header_ == nil {
31662		c.header_ = make(http.Header)
31663	}
31664	return c.header_
31665}
31666
31667func (c *EventTagsUpdateCall) doRequest(alt string) (*http.Response, error) {
31668	reqHeaders := make(http.Header)
31669	for k, v := range c.header_ {
31670		reqHeaders[k] = v
31671	}
31672	reqHeaders.Set("User-Agent", c.s.userAgent())
31673	var body io.Reader = nil
31674	body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31675	if err != nil {
31676		return nil, err
31677	}
31678	reqHeaders.Set("Content-Type", "application/json")
31679	c.urlParams_.Set("alt", alt)
31680	c.urlParams_.Set("prettyPrint", "false")
31681	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31682	urls += "?" + c.urlParams_.Encode()
31683	req, err := http.NewRequest("PUT", urls, body)
31684	if err != nil {
31685		return nil, err
31686	}
31687	req.Header = reqHeaders
31688	googleapi.Expand(req.URL, map[string]string{
31689		"profileId": strconv.FormatInt(c.profileId, 10),
31690	})
31691	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31692}
31693
31694// Do executes the "dfareporting.eventTags.update" call.
31695// Exactly one of *EventTag or error will be non-nil. Any non-2xx status
31696// code is an error. Response headers are in either
31697// *EventTag.ServerResponse.Header or (if a response was returned at
31698// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
31699// to check whether the returned error was because
31700// http.StatusNotModified was returned.
31701func (c *EventTagsUpdateCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31702	gensupport.SetOptions(c.urlParams_, opts...)
31703	res, err := c.doRequest("json")
31704	if res != nil && res.StatusCode == http.StatusNotModified {
31705		if res.Body != nil {
31706			res.Body.Close()
31707		}
31708		return nil, &googleapi.Error{
31709			Code:   res.StatusCode,
31710			Header: res.Header,
31711		}
31712	}
31713	if err != nil {
31714		return nil, err
31715	}
31716	defer googleapi.CloseBody(res)
31717	if err := googleapi.CheckResponse(res); err != nil {
31718		return nil, err
31719	}
31720	ret := &EventTag{
31721		ServerResponse: googleapi.ServerResponse{
31722			Header:         res.Header,
31723			HTTPStatusCode: res.StatusCode,
31724		},
31725	}
31726	target := &ret
31727	if err := gensupport.DecodeResponse(target, res); err != nil {
31728		return nil, err
31729	}
31730	return ret, nil
31731	// {
31732	//   "description": "Updates an existing event tag.",
31733	//   "httpMethod": "PUT",
31734	//   "id": "dfareporting.eventTags.update",
31735	//   "parameterOrder": [
31736	//     "profileId"
31737	//   ],
31738	//   "parameters": {
31739	//     "profileId": {
31740	//       "description": "User profile ID associated with this request.",
31741	//       "format": "int64",
31742	//       "location": "path",
31743	//       "required": true,
31744	//       "type": "string"
31745	//     }
31746	//   },
31747	//   "path": "userprofiles/{profileId}/eventTags",
31748	//   "request": {
31749	//     "$ref": "EventTag"
31750	//   },
31751	//   "response": {
31752	//     "$ref": "EventTag"
31753	//   },
31754	//   "scopes": [
31755	//     "https://www.googleapis.com/auth/dfatrafficking"
31756	//   ]
31757	// }
31758
31759}
31760
31761// method id "dfareporting.files.get":
31762
31763type FilesGetCall struct {
31764	s            *Service
31765	reportId     int64
31766	fileId       int64
31767	urlParams_   gensupport.URLParams
31768	ifNoneMatch_ string
31769	ctx_         context.Context
31770	header_      http.Header
31771}
31772
31773// Get: Retrieves a report file by its report ID and file ID. This
31774// method supports media download.
31775func (r *FilesService) Get(reportId int64, fileId int64) *FilesGetCall {
31776	c := &FilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31777	c.reportId = reportId
31778	c.fileId = fileId
31779	return c
31780}
31781
31782// Fields allows partial responses to be retrieved. See
31783// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31784// for more information.
31785func (c *FilesGetCall) Fields(s ...googleapi.Field) *FilesGetCall {
31786	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31787	return c
31788}
31789
31790// IfNoneMatch sets the optional parameter which makes the operation
31791// fail if the object's ETag matches the given value. This is useful for
31792// getting updates only after the object has changed since the last
31793// request. Use googleapi.IsNotModified to check whether the response
31794// error from Do is the result of In-None-Match.
31795func (c *FilesGetCall) IfNoneMatch(entityTag string) *FilesGetCall {
31796	c.ifNoneMatch_ = entityTag
31797	return c
31798}
31799
31800// Context sets the context to be used in this call's Do and Download
31801// methods. Any pending HTTP request will be aborted if the provided
31802// context is canceled.
31803func (c *FilesGetCall) Context(ctx context.Context) *FilesGetCall {
31804	c.ctx_ = ctx
31805	return c
31806}
31807
31808// Header returns an http.Header that can be modified by the caller to
31809// add HTTP headers to the request.
31810func (c *FilesGetCall) Header() http.Header {
31811	if c.header_ == nil {
31812		c.header_ = make(http.Header)
31813	}
31814	return c.header_
31815}
31816
31817func (c *FilesGetCall) doRequest(alt string) (*http.Response, error) {
31818	reqHeaders := make(http.Header)
31819	for k, v := range c.header_ {
31820		reqHeaders[k] = v
31821	}
31822	reqHeaders.Set("User-Agent", c.s.userAgent())
31823	if c.ifNoneMatch_ != "" {
31824		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31825	}
31826	var body io.Reader = nil
31827	c.urlParams_.Set("alt", alt)
31828	c.urlParams_.Set("prettyPrint", "false")
31829	urls := googleapi.ResolveRelative(c.s.BasePath, "reports/{reportId}/files/{fileId}")
31830	urls += "?" + c.urlParams_.Encode()
31831	req, err := http.NewRequest("GET", urls, body)
31832	if err != nil {
31833		return nil, err
31834	}
31835	req.Header = reqHeaders
31836	googleapi.Expand(req.URL, map[string]string{
31837		"reportId": strconv.FormatInt(c.reportId, 10),
31838		"fileId":   strconv.FormatInt(c.fileId, 10),
31839	})
31840	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31841}
31842
31843// Download fetches the API endpoint's "media" value, instead of the normal
31844// API response value. If the returned error is nil, the Response is guaranteed to
31845// have a 2xx status code. Callers must close the Response.Body as usual.
31846func (c *FilesGetCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
31847	gensupport.SetOptions(c.urlParams_, opts...)
31848	res, err := c.doRequest("media")
31849	if err != nil {
31850		return nil, err
31851	}
31852	if err := googleapi.CheckMediaResponse(res); err != nil {
31853		res.Body.Close()
31854		return nil, err
31855	}
31856	return res, nil
31857}
31858
31859// Do executes the "dfareporting.files.get" call.
31860// Exactly one of *File or error will be non-nil. Any non-2xx status
31861// code is an error. Response headers are in either
31862// *File.ServerResponse.Header or (if a response was returned at all) in
31863// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31864// whether the returned error was because http.StatusNotModified was
31865// returned.
31866func (c *FilesGetCall) Do(opts ...googleapi.CallOption) (*File, error) {
31867	gensupport.SetOptions(c.urlParams_, opts...)
31868	res, err := c.doRequest("json")
31869	if res != nil && res.StatusCode == http.StatusNotModified {
31870		if res.Body != nil {
31871			res.Body.Close()
31872		}
31873		return nil, &googleapi.Error{
31874			Code:   res.StatusCode,
31875			Header: res.Header,
31876		}
31877	}
31878	if err != nil {
31879		return nil, err
31880	}
31881	defer googleapi.CloseBody(res)
31882	if err := googleapi.CheckResponse(res); err != nil {
31883		return nil, err
31884	}
31885	ret := &File{
31886		ServerResponse: googleapi.ServerResponse{
31887			Header:         res.Header,
31888			HTTPStatusCode: res.StatusCode,
31889		},
31890	}
31891	target := &ret
31892	if err := gensupport.DecodeResponse(target, res); err != nil {
31893		return nil, err
31894	}
31895	return ret, nil
31896	// {
31897	//   "description": "Retrieves a report file by its report ID and file ID. This method supports media download.",
31898	//   "httpMethod": "GET",
31899	//   "id": "dfareporting.files.get",
31900	//   "parameterOrder": [
31901	//     "reportId",
31902	//     "fileId"
31903	//   ],
31904	//   "parameters": {
31905	//     "fileId": {
31906	//       "description": "The ID of the report file.",
31907	//       "format": "int64",
31908	//       "location": "path",
31909	//       "required": true,
31910	//       "type": "string"
31911	//     },
31912	//     "reportId": {
31913	//       "description": "The ID of the report.",
31914	//       "format": "int64",
31915	//       "location": "path",
31916	//       "required": true,
31917	//       "type": "string"
31918	//     }
31919	//   },
31920	//   "path": "reports/{reportId}/files/{fileId}",
31921	//   "response": {
31922	//     "$ref": "File"
31923	//   },
31924	//   "scopes": [
31925	//     "https://www.googleapis.com/auth/dfareporting"
31926	//   ],
31927	//   "supportsMediaDownload": true
31928	// }
31929
31930}
31931
31932// method id "dfareporting.files.list":
31933
31934type FilesListCall struct {
31935	s            *Service
31936	profileId    int64
31937	urlParams_   gensupport.URLParams
31938	ifNoneMatch_ string
31939	ctx_         context.Context
31940	header_      http.Header
31941}
31942
31943// List: Lists files for a user profile.
31944func (r *FilesService) List(profileId int64) *FilesListCall {
31945	c := &FilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31946	c.profileId = profileId
31947	return c
31948}
31949
31950// MaxResults sets the optional parameter "maxResults": Maximum number
31951// of results to return.
31952func (c *FilesListCall) MaxResults(maxResults int64) *FilesListCall {
31953	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
31954	return c
31955}
31956
31957// PageToken sets the optional parameter "pageToken": The value of the
31958// nextToken from the previous result page.
31959func (c *FilesListCall) PageToken(pageToken string) *FilesListCall {
31960	c.urlParams_.Set("pageToken", pageToken)
31961	return c
31962}
31963
31964// Scope sets the optional parameter "scope": The scope that defines
31965// which results are returned.
31966//
31967// Possible values:
31968//   "ALL" - All files in account.
31969//   "MINE" (default) - My files.
31970//   "SHARED_WITH_ME" - Files shared with me.
31971func (c *FilesListCall) Scope(scope string) *FilesListCall {
31972	c.urlParams_.Set("scope", scope)
31973	return c
31974}
31975
31976// SortField sets the optional parameter "sortField": The field by which
31977// to sort the list.
31978//
31979// Possible values:
31980//   "ID" - Sort by file ID.
31981//   "LAST_MODIFIED_TIME" (default) - Sort by 'lastmodifiedAt' field.
31982func (c *FilesListCall) SortField(sortField string) *FilesListCall {
31983	c.urlParams_.Set("sortField", sortField)
31984	return c
31985}
31986
31987// SortOrder sets the optional parameter "sortOrder": Order of sorted
31988// results.
31989//
31990// Possible values:
31991//   "ASCENDING" - Ascending order.
31992//   "DESCENDING" (default) - Descending order.
31993func (c *FilesListCall) SortOrder(sortOrder string) *FilesListCall {
31994	c.urlParams_.Set("sortOrder", sortOrder)
31995	return c
31996}
31997
31998// Fields allows partial responses to be retrieved. See
31999// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32000// for more information.
32001func (c *FilesListCall) Fields(s ...googleapi.Field) *FilesListCall {
32002	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32003	return c
32004}
32005
32006// IfNoneMatch sets the optional parameter which makes the operation
32007// fail if the object's ETag matches the given value. This is useful for
32008// getting updates only after the object has changed since the last
32009// request. Use googleapi.IsNotModified to check whether the response
32010// error from Do is the result of In-None-Match.
32011func (c *FilesListCall) IfNoneMatch(entityTag string) *FilesListCall {
32012	c.ifNoneMatch_ = entityTag
32013	return c
32014}
32015
32016// Context sets the context to be used in this call's Do method. Any
32017// pending HTTP request will be aborted if the provided context is
32018// canceled.
32019func (c *FilesListCall) Context(ctx context.Context) *FilesListCall {
32020	c.ctx_ = ctx
32021	return c
32022}
32023
32024// Header returns an http.Header that can be modified by the caller to
32025// add HTTP headers to the request.
32026func (c *FilesListCall) Header() http.Header {
32027	if c.header_ == nil {
32028		c.header_ = make(http.Header)
32029	}
32030	return c.header_
32031}
32032
32033func (c *FilesListCall) doRequest(alt string) (*http.Response, error) {
32034	reqHeaders := make(http.Header)
32035	for k, v := range c.header_ {
32036		reqHeaders[k] = v
32037	}
32038	reqHeaders.Set("User-Agent", c.s.userAgent())
32039	if c.ifNoneMatch_ != "" {
32040		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32041	}
32042	var body io.Reader = nil
32043	c.urlParams_.Set("alt", alt)
32044	c.urlParams_.Set("prettyPrint", "false")
32045	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/files")
32046	urls += "?" + c.urlParams_.Encode()
32047	req, err := http.NewRequest("GET", urls, body)
32048	if err != nil {
32049		return nil, err
32050	}
32051	req.Header = reqHeaders
32052	googleapi.Expand(req.URL, map[string]string{
32053		"profileId": strconv.FormatInt(c.profileId, 10),
32054	})
32055	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32056}
32057
32058// Do executes the "dfareporting.files.list" call.
32059// Exactly one of *FileList or error will be non-nil. Any non-2xx status
32060// code is an error. Response headers are in either
32061// *FileList.ServerResponse.Header or (if a response was returned at
32062// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
32063// to check whether the returned error was because
32064// http.StatusNotModified was returned.
32065func (c *FilesListCall) Do(opts ...googleapi.CallOption) (*FileList, error) {
32066	gensupport.SetOptions(c.urlParams_, opts...)
32067	res, err := c.doRequest("json")
32068	if res != nil && res.StatusCode == http.StatusNotModified {
32069		if res.Body != nil {
32070			res.Body.Close()
32071		}
32072		return nil, &googleapi.Error{
32073			Code:   res.StatusCode,
32074			Header: res.Header,
32075		}
32076	}
32077	if err != nil {
32078		return nil, err
32079	}
32080	defer googleapi.CloseBody(res)
32081	if err := googleapi.CheckResponse(res); err != nil {
32082		return nil, err
32083	}
32084	ret := &FileList{
32085		ServerResponse: googleapi.ServerResponse{
32086			Header:         res.Header,
32087			HTTPStatusCode: res.StatusCode,
32088		},
32089	}
32090	target := &ret
32091	if err := gensupport.DecodeResponse(target, res); err != nil {
32092		return nil, err
32093	}
32094	return ret, nil
32095	// {
32096	//   "description": "Lists files for a user profile.",
32097	//   "httpMethod": "GET",
32098	//   "id": "dfareporting.files.list",
32099	//   "parameterOrder": [
32100	//     "profileId"
32101	//   ],
32102	//   "parameters": {
32103	//     "maxResults": {
32104	//       "default": "10",
32105	//       "description": "Maximum number of results to return.",
32106	//       "format": "int32",
32107	//       "location": "query",
32108	//       "maximum": "10",
32109	//       "minimum": "0",
32110	//       "type": "integer"
32111	//     },
32112	//     "pageToken": {
32113	//       "description": "The value of the nextToken from the previous result page.",
32114	//       "location": "query",
32115	//       "type": "string"
32116	//     },
32117	//     "profileId": {
32118	//       "description": "The DFA profile ID.",
32119	//       "format": "int64",
32120	//       "location": "path",
32121	//       "required": true,
32122	//       "type": "string"
32123	//     },
32124	//     "scope": {
32125	//       "default": "MINE",
32126	//       "description": "The scope that defines which results are returned.",
32127	//       "enum": [
32128	//         "ALL",
32129	//         "MINE",
32130	//         "SHARED_WITH_ME"
32131	//       ],
32132	//       "enumDescriptions": [
32133	//         "All files in account.",
32134	//         "My files.",
32135	//         "Files shared with me."
32136	//       ],
32137	//       "location": "query",
32138	//       "type": "string"
32139	//     },
32140	//     "sortField": {
32141	//       "default": "LAST_MODIFIED_TIME",
32142	//       "description": "The field by which to sort the list.",
32143	//       "enum": [
32144	//         "ID",
32145	//         "LAST_MODIFIED_TIME"
32146	//       ],
32147	//       "enumDescriptions": [
32148	//         "Sort by file ID.",
32149	//         "Sort by 'lastmodifiedAt' field."
32150	//       ],
32151	//       "location": "query",
32152	//       "type": "string"
32153	//     },
32154	//     "sortOrder": {
32155	//       "default": "DESCENDING",
32156	//       "description": "Order of sorted results.",
32157	//       "enum": [
32158	//         "ASCENDING",
32159	//         "DESCENDING"
32160	//       ],
32161	//       "enumDescriptions": [
32162	//         "Ascending order.",
32163	//         "Descending order."
32164	//       ],
32165	//       "location": "query",
32166	//       "type": "string"
32167	//     }
32168	//   },
32169	//   "path": "userprofiles/{profileId}/files",
32170	//   "response": {
32171	//     "$ref": "FileList"
32172	//   },
32173	//   "scopes": [
32174	//     "https://www.googleapis.com/auth/dfareporting"
32175	//   ]
32176	// }
32177
32178}
32179
32180// Pages invokes f for each page of results.
32181// A non-nil error returned from f will halt the iteration.
32182// The provided context supersedes any context provided to the Context method.
32183func (c *FilesListCall) Pages(ctx context.Context, f func(*FileList) error) error {
32184	c.ctx_ = ctx
32185	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
32186	for {
32187		x, err := c.Do()
32188		if err != nil {
32189			return err
32190		}
32191		if err := f(x); err != nil {
32192			return err
32193		}
32194		if x.NextPageToken == "" {
32195			return nil
32196		}
32197		c.PageToken(x.NextPageToken)
32198	}
32199}
32200
32201// method id "dfareporting.floodlightActivities.delete":
32202
32203type FloodlightActivitiesDeleteCall struct {
32204	s          *Service
32205	profileId  int64
32206	id         int64
32207	urlParams_ gensupport.URLParams
32208	ctx_       context.Context
32209	header_    http.Header
32210}
32211
32212// Delete: Deletes an existing floodlight activity.
32213func (r *FloodlightActivitiesService) Delete(profileId int64, id int64) *FloodlightActivitiesDeleteCall {
32214	c := &FloodlightActivitiesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32215	c.profileId = profileId
32216	c.id = id
32217	return c
32218}
32219
32220// Fields allows partial responses to be retrieved. See
32221// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32222// for more information.
32223func (c *FloodlightActivitiesDeleteCall) Fields(s ...googleapi.Field) *FloodlightActivitiesDeleteCall {
32224	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32225	return c
32226}
32227
32228// Context sets the context to be used in this call's Do method. Any
32229// pending HTTP request will be aborted if the provided context is
32230// canceled.
32231func (c *FloodlightActivitiesDeleteCall) Context(ctx context.Context) *FloodlightActivitiesDeleteCall {
32232	c.ctx_ = ctx
32233	return c
32234}
32235
32236// Header returns an http.Header that can be modified by the caller to
32237// add HTTP headers to the request.
32238func (c *FloodlightActivitiesDeleteCall) Header() http.Header {
32239	if c.header_ == nil {
32240		c.header_ = make(http.Header)
32241	}
32242	return c.header_
32243}
32244
32245func (c *FloodlightActivitiesDeleteCall) doRequest(alt string) (*http.Response, error) {
32246	reqHeaders := make(http.Header)
32247	for k, v := range c.header_ {
32248		reqHeaders[k] = v
32249	}
32250	reqHeaders.Set("User-Agent", c.s.userAgent())
32251	var body io.Reader = nil
32252	c.urlParams_.Set("alt", alt)
32253	c.urlParams_.Set("prettyPrint", "false")
32254	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/{id}")
32255	urls += "?" + c.urlParams_.Encode()
32256	req, err := http.NewRequest("DELETE", urls, body)
32257	if err != nil {
32258		return nil, err
32259	}
32260	req.Header = reqHeaders
32261	googleapi.Expand(req.URL, map[string]string{
32262		"profileId": strconv.FormatInt(c.profileId, 10),
32263		"id":        strconv.FormatInt(c.id, 10),
32264	})
32265	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32266}
32267
32268// Do executes the "dfareporting.floodlightActivities.delete" call.
32269func (c *FloodlightActivitiesDeleteCall) Do(opts ...googleapi.CallOption) error {
32270	gensupport.SetOptions(c.urlParams_, opts...)
32271	res, err := c.doRequest("json")
32272	if err != nil {
32273		return err
32274	}
32275	defer googleapi.CloseBody(res)
32276	if err := googleapi.CheckResponse(res); err != nil {
32277		return err
32278	}
32279	return nil
32280	// {
32281	//   "description": "Deletes an existing floodlight activity.",
32282	//   "httpMethod": "DELETE",
32283	//   "id": "dfareporting.floodlightActivities.delete",
32284	//   "parameterOrder": [
32285	//     "profileId",
32286	//     "id"
32287	//   ],
32288	//   "parameters": {
32289	//     "id": {
32290	//       "description": "Floodlight activity ID.",
32291	//       "format": "int64",
32292	//       "location": "path",
32293	//       "required": true,
32294	//       "type": "string"
32295	//     },
32296	//     "profileId": {
32297	//       "description": "User profile ID associated with this request.",
32298	//       "format": "int64",
32299	//       "location": "path",
32300	//       "required": true,
32301	//       "type": "string"
32302	//     }
32303	//   },
32304	//   "path": "userprofiles/{profileId}/floodlightActivities/{id}",
32305	//   "scopes": [
32306	//     "https://www.googleapis.com/auth/dfatrafficking"
32307	//   ]
32308	// }
32309
32310}
32311
32312// method id "dfareporting.floodlightActivities.generatetag":
32313
32314type FloodlightActivitiesGeneratetagCall struct {
32315	s          *Service
32316	profileId  int64
32317	urlParams_ gensupport.URLParams
32318	ctx_       context.Context
32319	header_    http.Header
32320}
32321
32322// Generatetag: Generates a tag for a floodlight activity.
32323func (r *FloodlightActivitiesService) Generatetag(profileId int64) *FloodlightActivitiesGeneratetagCall {
32324	c := &FloodlightActivitiesGeneratetagCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32325	c.profileId = profileId
32326	return c
32327}
32328
32329// FloodlightActivityId sets the optional parameter
32330// "floodlightActivityId": Floodlight activity ID for which we want to
32331// generate a tag.
32332func (c *FloodlightActivitiesGeneratetagCall) FloodlightActivityId(floodlightActivityId int64) *FloodlightActivitiesGeneratetagCall {
32333	c.urlParams_.Set("floodlightActivityId", fmt.Sprint(floodlightActivityId))
32334	return c
32335}
32336
32337// Fields allows partial responses to be retrieved. See
32338// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32339// for more information.
32340func (c *FloodlightActivitiesGeneratetagCall) Fields(s ...googleapi.Field) *FloodlightActivitiesGeneratetagCall {
32341	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32342	return c
32343}
32344
32345// Context sets the context to be used in this call's Do method. Any
32346// pending HTTP request will be aborted if the provided context is
32347// canceled.
32348func (c *FloodlightActivitiesGeneratetagCall) Context(ctx context.Context) *FloodlightActivitiesGeneratetagCall {
32349	c.ctx_ = ctx
32350	return c
32351}
32352
32353// Header returns an http.Header that can be modified by the caller to
32354// add HTTP headers to the request.
32355func (c *FloodlightActivitiesGeneratetagCall) Header() http.Header {
32356	if c.header_ == nil {
32357		c.header_ = make(http.Header)
32358	}
32359	return c.header_
32360}
32361
32362func (c *FloodlightActivitiesGeneratetagCall) doRequest(alt string) (*http.Response, error) {
32363	reqHeaders := make(http.Header)
32364	for k, v := range c.header_ {
32365		reqHeaders[k] = v
32366	}
32367	reqHeaders.Set("User-Agent", c.s.userAgent())
32368	var body io.Reader = nil
32369	c.urlParams_.Set("alt", alt)
32370	c.urlParams_.Set("prettyPrint", "false")
32371	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/generatetag")
32372	urls += "?" + c.urlParams_.Encode()
32373	req, err := http.NewRequest("POST", urls, body)
32374	if err != nil {
32375		return nil, err
32376	}
32377	req.Header = reqHeaders
32378	googleapi.Expand(req.URL, map[string]string{
32379		"profileId": strconv.FormatInt(c.profileId, 10),
32380	})
32381	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32382}
32383
32384// Do executes the "dfareporting.floodlightActivities.generatetag" call.
32385// Exactly one of *FloodlightActivitiesGenerateTagResponse or error will
32386// be non-nil. Any non-2xx status code is an error. Response headers are
32387// in either
32388// *FloodlightActivitiesGenerateTagResponse.ServerResponse.Header or (if
32389// a response was returned at all) in error.(*googleapi.Error).Header.
32390// Use googleapi.IsNotModified to check whether the returned error was
32391// because http.StatusNotModified was returned.
32392func (c *FloodlightActivitiesGeneratetagCall) Do(opts ...googleapi.CallOption) (*FloodlightActivitiesGenerateTagResponse, error) {
32393	gensupport.SetOptions(c.urlParams_, opts...)
32394	res, err := c.doRequest("json")
32395	if res != nil && res.StatusCode == http.StatusNotModified {
32396		if res.Body != nil {
32397			res.Body.Close()
32398		}
32399		return nil, &googleapi.Error{
32400			Code:   res.StatusCode,
32401			Header: res.Header,
32402		}
32403	}
32404	if err != nil {
32405		return nil, err
32406	}
32407	defer googleapi.CloseBody(res)
32408	if err := googleapi.CheckResponse(res); err != nil {
32409		return nil, err
32410	}
32411	ret := &FloodlightActivitiesGenerateTagResponse{
32412		ServerResponse: googleapi.ServerResponse{
32413			Header:         res.Header,
32414			HTTPStatusCode: res.StatusCode,
32415		},
32416	}
32417	target := &ret
32418	if err := gensupport.DecodeResponse(target, res); err != nil {
32419		return nil, err
32420	}
32421	return ret, nil
32422	// {
32423	//   "description": "Generates a tag for a floodlight activity.",
32424	//   "httpMethod": "POST",
32425	//   "id": "dfareporting.floodlightActivities.generatetag",
32426	//   "parameterOrder": [
32427	//     "profileId"
32428	//   ],
32429	//   "parameters": {
32430	//     "floodlightActivityId": {
32431	//       "description": "Floodlight activity ID for which we want to generate a tag.",
32432	//       "format": "int64",
32433	//       "location": "query",
32434	//       "type": "string"
32435	//     },
32436	//     "profileId": {
32437	//       "description": "User profile ID associated with this request.",
32438	//       "format": "int64",
32439	//       "location": "path",
32440	//       "required": true,
32441	//       "type": "string"
32442	//     }
32443	//   },
32444	//   "path": "userprofiles/{profileId}/floodlightActivities/generatetag",
32445	//   "response": {
32446	//     "$ref": "FloodlightActivitiesGenerateTagResponse"
32447	//   },
32448	//   "scopes": [
32449	//     "https://www.googleapis.com/auth/dfatrafficking"
32450	//   ]
32451	// }
32452
32453}
32454
32455// method id "dfareporting.floodlightActivities.get":
32456
32457type FloodlightActivitiesGetCall struct {
32458	s            *Service
32459	profileId    int64
32460	id           int64
32461	urlParams_   gensupport.URLParams
32462	ifNoneMatch_ string
32463	ctx_         context.Context
32464	header_      http.Header
32465}
32466
32467// Get: Gets one floodlight activity by ID.
32468func (r *FloodlightActivitiesService) Get(profileId int64, id int64) *FloodlightActivitiesGetCall {
32469	c := &FloodlightActivitiesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32470	c.profileId = profileId
32471	c.id = id
32472	return c
32473}
32474
32475// Fields allows partial responses to be retrieved. See
32476// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32477// for more information.
32478func (c *FloodlightActivitiesGetCall) Fields(s ...googleapi.Field) *FloodlightActivitiesGetCall {
32479	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32480	return c
32481}
32482
32483// IfNoneMatch sets the optional parameter which makes the operation
32484// fail if the object's ETag matches the given value. This is useful for
32485// getting updates only after the object has changed since the last
32486// request. Use googleapi.IsNotModified to check whether the response
32487// error from Do is the result of In-None-Match.
32488func (c *FloodlightActivitiesGetCall) IfNoneMatch(entityTag string) *FloodlightActivitiesGetCall {
32489	c.ifNoneMatch_ = entityTag
32490	return c
32491}
32492
32493// Context sets the context to be used in this call's Do method. Any
32494// pending HTTP request will be aborted if the provided context is
32495// canceled.
32496func (c *FloodlightActivitiesGetCall) Context(ctx context.Context) *FloodlightActivitiesGetCall {
32497	c.ctx_ = ctx
32498	return c
32499}
32500
32501// Header returns an http.Header that can be modified by the caller to
32502// add HTTP headers to the request.
32503func (c *FloodlightActivitiesGetCall) Header() http.Header {
32504	if c.header_ == nil {
32505		c.header_ = make(http.Header)
32506	}
32507	return c.header_
32508}
32509
32510func (c *FloodlightActivitiesGetCall) doRequest(alt string) (*http.Response, error) {
32511	reqHeaders := make(http.Header)
32512	for k, v := range c.header_ {
32513		reqHeaders[k] = v
32514	}
32515	reqHeaders.Set("User-Agent", c.s.userAgent())
32516	if c.ifNoneMatch_ != "" {
32517		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32518	}
32519	var body io.Reader = nil
32520	c.urlParams_.Set("alt", alt)
32521	c.urlParams_.Set("prettyPrint", "false")
32522	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/{id}")
32523	urls += "?" + c.urlParams_.Encode()
32524	req, err := http.NewRequest("GET", urls, body)
32525	if err != nil {
32526		return nil, err
32527	}
32528	req.Header = reqHeaders
32529	googleapi.Expand(req.URL, map[string]string{
32530		"profileId": strconv.FormatInt(c.profileId, 10),
32531		"id":        strconv.FormatInt(c.id, 10),
32532	})
32533	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32534}
32535
32536// Do executes the "dfareporting.floodlightActivities.get" call.
32537// Exactly one of *FloodlightActivity or error will be non-nil. Any
32538// non-2xx status code is an error. Response headers are in either
32539// *FloodlightActivity.ServerResponse.Header or (if a response was
32540// returned at all) in error.(*googleapi.Error).Header. Use
32541// googleapi.IsNotModified to check whether the returned error was
32542// because http.StatusNotModified was returned.
32543func (c *FloodlightActivitiesGetCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
32544	gensupport.SetOptions(c.urlParams_, opts...)
32545	res, err := c.doRequest("json")
32546	if res != nil && res.StatusCode == http.StatusNotModified {
32547		if res.Body != nil {
32548			res.Body.Close()
32549		}
32550		return nil, &googleapi.Error{
32551			Code:   res.StatusCode,
32552			Header: res.Header,
32553		}
32554	}
32555	if err != nil {
32556		return nil, err
32557	}
32558	defer googleapi.CloseBody(res)
32559	if err := googleapi.CheckResponse(res); err != nil {
32560		return nil, err
32561	}
32562	ret := &FloodlightActivity{
32563		ServerResponse: googleapi.ServerResponse{
32564			Header:         res.Header,
32565			HTTPStatusCode: res.StatusCode,
32566		},
32567	}
32568	target := &ret
32569	if err := gensupport.DecodeResponse(target, res); err != nil {
32570		return nil, err
32571	}
32572	return ret, nil
32573	// {
32574	//   "description": "Gets one floodlight activity by ID.",
32575	//   "httpMethod": "GET",
32576	//   "id": "dfareporting.floodlightActivities.get",
32577	//   "parameterOrder": [
32578	//     "profileId",
32579	//     "id"
32580	//   ],
32581	//   "parameters": {
32582	//     "id": {
32583	//       "description": "Floodlight activity ID.",
32584	//       "format": "int64",
32585	//       "location": "path",
32586	//       "required": true,
32587	//       "type": "string"
32588	//     },
32589	//     "profileId": {
32590	//       "description": "User profile ID associated with this request.",
32591	//       "format": "int64",
32592	//       "location": "path",
32593	//       "required": true,
32594	//       "type": "string"
32595	//     }
32596	//   },
32597	//   "path": "userprofiles/{profileId}/floodlightActivities/{id}",
32598	//   "response": {
32599	//     "$ref": "FloodlightActivity"
32600	//   },
32601	//   "scopes": [
32602	//     "https://www.googleapis.com/auth/dfatrafficking"
32603	//   ]
32604	// }
32605
32606}
32607
32608// method id "dfareporting.floodlightActivities.insert":
32609
32610type FloodlightActivitiesInsertCall struct {
32611	s                  *Service
32612	profileId          int64
32613	floodlightactivity *FloodlightActivity
32614	urlParams_         gensupport.URLParams
32615	ctx_               context.Context
32616	header_            http.Header
32617}
32618
32619// Insert: Inserts a new floodlight activity.
32620func (r *FloodlightActivitiesService) Insert(profileId int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesInsertCall {
32621	c := &FloodlightActivitiesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32622	c.profileId = profileId
32623	c.floodlightactivity = floodlightactivity
32624	return c
32625}
32626
32627// Fields allows partial responses to be retrieved. See
32628// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32629// for more information.
32630func (c *FloodlightActivitiesInsertCall) Fields(s ...googleapi.Field) *FloodlightActivitiesInsertCall {
32631	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32632	return c
32633}
32634
32635// Context sets the context to be used in this call's Do method. Any
32636// pending HTTP request will be aborted if the provided context is
32637// canceled.
32638func (c *FloodlightActivitiesInsertCall) Context(ctx context.Context) *FloodlightActivitiesInsertCall {
32639	c.ctx_ = ctx
32640	return c
32641}
32642
32643// Header returns an http.Header that can be modified by the caller to
32644// add HTTP headers to the request.
32645func (c *FloodlightActivitiesInsertCall) Header() http.Header {
32646	if c.header_ == nil {
32647		c.header_ = make(http.Header)
32648	}
32649	return c.header_
32650}
32651
32652func (c *FloodlightActivitiesInsertCall) doRequest(alt string) (*http.Response, error) {
32653	reqHeaders := make(http.Header)
32654	for k, v := range c.header_ {
32655		reqHeaders[k] = v
32656	}
32657	reqHeaders.Set("User-Agent", c.s.userAgent())
32658	var body io.Reader = nil
32659	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
32660	if err != nil {
32661		return nil, err
32662	}
32663	reqHeaders.Set("Content-Type", "application/json")
32664	c.urlParams_.Set("alt", alt)
32665	c.urlParams_.Set("prettyPrint", "false")
32666	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
32667	urls += "?" + c.urlParams_.Encode()
32668	req, err := http.NewRequest("POST", urls, body)
32669	if err != nil {
32670		return nil, err
32671	}
32672	req.Header = reqHeaders
32673	googleapi.Expand(req.URL, map[string]string{
32674		"profileId": strconv.FormatInt(c.profileId, 10),
32675	})
32676	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32677}
32678
32679// Do executes the "dfareporting.floodlightActivities.insert" call.
32680// Exactly one of *FloodlightActivity or error will be non-nil. Any
32681// non-2xx status code is an error. Response headers are in either
32682// *FloodlightActivity.ServerResponse.Header or (if a response was
32683// returned at all) in error.(*googleapi.Error).Header. Use
32684// googleapi.IsNotModified to check whether the returned error was
32685// because http.StatusNotModified was returned.
32686func (c *FloodlightActivitiesInsertCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
32687	gensupport.SetOptions(c.urlParams_, opts...)
32688	res, err := c.doRequest("json")
32689	if res != nil && res.StatusCode == http.StatusNotModified {
32690		if res.Body != nil {
32691			res.Body.Close()
32692		}
32693		return nil, &googleapi.Error{
32694			Code:   res.StatusCode,
32695			Header: res.Header,
32696		}
32697	}
32698	if err != nil {
32699		return nil, err
32700	}
32701	defer googleapi.CloseBody(res)
32702	if err := googleapi.CheckResponse(res); err != nil {
32703		return nil, err
32704	}
32705	ret := &FloodlightActivity{
32706		ServerResponse: googleapi.ServerResponse{
32707			Header:         res.Header,
32708			HTTPStatusCode: res.StatusCode,
32709		},
32710	}
32711	target := &ret
32712	if err := gensupport.DecodeResponse(target, res); err != nil {
32713		return nil, err
32714	}
32715	return ret, nil
32716	// {
32717	//   "description": "Inserts a new floodlight activity.",
32718	//   "httpMethod": "POST",
32719	//   "id": "dfareporting.floodlightActivities.insert",
32720	//   "parameterOrder": [
32721	//     "profileId"
32722	//   ],
32723	//   "parameters": {
32724	//     "profileId": {
32725	//       "description": "User profile ID associated with this request.",
32726	//       "format": "int64",
32727	//       "location": "path",
32728	//       "required": true,
32729	//       "type": "string"
32730	//     }
32731	//   },
32732	//   "path": "userprofiles/{profileId}/floodlightActivities",
32733	//   "request": {
32734	//     "$ref": "FloodlightActivity"
32735	//   },
32736	//   "response": {
32737	//     "$ref": "FloodlightActivity"
32738	//   },
32739	//   "scopes": [
32740	//     "https://www.googleapis.com/auth/dfatrafficking"
32741	//   ]
32742	// }
32743
32744}
32745
32746// method id "dfareporting.floodlightActivities.list":
32747
32748type FloodlightActivitiesListCall struct {
32749	s            *Service
32750	profileId    int64
32751	urlParams_   gensupport.URLParams
32752	ifNoneMatch_ string
32753	ctx_         context.Context
32754	header_      http.Header
32755}
32756
32757// List: Retrieves a list of floodlight activities, possibly filtered.
32758// This method supports paging.
32759func (r *FloodlightActivitiesService) List(profileId int64) *FloodlightActivitiesListCall {
32760	c := &FloodlightActivitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32761	c.profileId = profileId
32762	return c
32763}
32764
32765// AdvertiserId sets the optional parameter "advertiserId": Select only
32766// floodlight activities for the specified advertiser ID. Must specify
32767// either ids, advertiserId, or floodlightConfigurationId for a
32768// non-empty result.
32769func (c *FloodlightActivitiesListCall) AdvertiserId(advertiserId int64) *FloodlightActivitiesListCall {
32770	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
32771	return c
32772}
32773
32774// FloodlightActivityGroupIds sets the optional parameter
32775// "floodlightActivityGroupIds": Select only floodlight activities with
32776// the specified floodlight activity group IDs.
32777func (c *FloodlightActivitiesListCall) FloodlightActivityGroupIds(floodlightActivityGroupIds ...int64) *FloodlightActivitiesListCall {
32778	var floodlightActivityGroupIds_ []string
32779	for _, v := range floodlightActivityGroupIds {
32780		floodlightActivityGroupIds_ = append(floodlightActivityGroupIds_, fmt.Sprint(v))
32781	}
32782	c.urlParams_.SetMulti("floodlightActivityGroupIds", floodlightActivityGroupIds_)
32783	return c
32784}
32785
32786// FloodlightActivityGroupName sets the optional parameter
32787// "floodlightActivityGroupName": Select only floodlight activities with
32788// the specified floodlight activity group name.
32789func (c *FloodlightActivitiesListCall) FloodlightActivityGroupName(floodlightActivityGroupName string) *FloodlightActivitiesListCall {
32790	c.urlParams_.Set("floodlightActivityGroupName", floodlightActivityGroupName)
32791	return c
32792}
32793
32794// FloodlightActivityGroupTagString sets the optional parameter
32795// "floodlightActivityGroupTagString": Select only floodlight activities
32796// with the specified floodlight activity group tag string.
32797func (c *FloodlightActivitiesListCall) FloodlightActivityGroupTagString(floodlightActivityGroupTagString string) *FloodlightActivitiesListCall {
32798	c.urlParams_.Set("floodlightActivityGroupTagString", floodlightActivityGroupTagString)
32799	return c
32800}
32801
32802// FloodlightActivityGroupType sets the optional parameter
32803// "floodlightActivityGroupType": Select only floodlight activities with
32804// the specified floodlight activity group type.
32805//
32806// Possible values:
32807//   "COUNTER"
32808//   "SALE"
32809func (c *FloodlightActivitiesListCall) FloodlightActivityGroupType(floodlightActivityGroupType string) *FloodlightActivitiesListCall {
32810	c.urlParams_.Set("floodlightActivityGroupType", floodlightActivityGroupType)
32811	return c
32812}
32813
32814// FloodlightConfigurationId sets the optional parameter
32815// "floodlightConfigurationId": Select only floodlight activities for
32816// the specified floodlight configuration ID. Must specify either ids,
32817// advertiserId, or floodlightConfigurationId for a non-empty result.
32818func (c *FloodlightActivitiesListCall) FloodlightConfigurationId(floodlightConfigurationId int64) *FloodlightActivitiesListCall {
32819	c.urlParams_.Set("floodlightConfigurationId", fmt.Sprint(floodlightConfigurationId))
32820	return c
32821}
32822
32823// Ids sets the optional parameter "ids": Select only floodlight
32824// activities with the specified IDs. Must specify either ids,
32825// advertiserId, or floodlightConfigurationId for a non-empty result.
32826func (c *FloodlightActivitiesListCall) Ids(ids ...int64) *FloodlightActivitiesListCall {
32827	var ids_ []string
32828	for _, v := range ids {
32829		ids_ = append(ids_, fmt.Sprint(v))
32830	}
32831	c.urlParams_.SetMulti("ids", ids_)
32832	return c
32833}
32834
32835// MaxResults sets the optional parameter "maxResults": Maximum number
32836// of results to return.
32837func (c *FloodlightActivitiesListCall) MaxResults(maxResults int64) *FloodlightActivitiesListCall {
32838	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
32839	return c
32840}
32841
32842// PageToken sets the optional parameter "pageToken": Value of the
32843// nextPageToken from the previous result page.
32844func (c *FloodlightActivitiesListCall) PageToken(pageToken string) *FloodlightActivitiesListCall {
32845	c.urlParams_.Set("pageToken", pageToken)
32846	return c
32847}
32848
32849// SearchString sets the optional parameter "searchString": Allows
32850// searching for objects by name or ID. Wildcards (*) are allowed. For
32851// example, "floodlightactivity*2015" will return objects with names
32852// like "floodlightactivity June 2015", "floodlightactivity April 2015",
32853// or simply "floodlightactivity 2015". Most of the searches also add
32854// wildcards implicitly at the start and the end of the search string.
32855// For example, a search string of "floodlightactivity" will match
32856// objects with name "my floodlightactivity activity",
32857// "floodlightactivity 2015", or simply "floodlightactivity".
32858func (c *FloodlightActivitiesListCall) SearchString(searchString string) *FloodlightActivitiesListCall {
32859	c.urlParams_.Set("searchString", searchString)
32860	return c
32861}
32862
32863// SortField sets the optional parameter "sortField": Field by which to
32864// sort the list.
32865//
32866// Possible values:
32867//   "ID" (default)
32868//   "NAME"
32869func (c *FloodlightActivitiesListCall) SortField(sortField string) *FloodlightActivitiesListCall {
32870	c.urlParams_.Set("sortField", sortField)
32871	return c
32872}
32873
32874// SortOrder sets the optional parameter "sortOrder": Order of sorted
32875// results.
32876//
32877// Possible values:
32878//   "ASCENDING" (default)
32879//   "DESCENDING"
32880func (c *FloodlightActivitiesListCall) SortOrder(sortOrder string) *FloodlightActivitiesListCall {
32881	c.urlParams_.Set("sortOrder", sortOrder)
32882	return c
32883}
32884
32885// TagString sets the optional parameter "tagString": Select only
32886// floodlight activities with the specified tag string.
32887func (c *FloodlightActivitiesListCall) TagString(tagString string) *FloodlightActivitiesListCall {
32888	c.urlParams_.Set("tagString", tagString)
32889	return c
32890}
32891
32892// Fields allows partial responses to be retrieved. See
32893// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32894// for more information.
32895func (c *FloodlightActivitiesListCall) Fields(s ...googleapi.Field) *FloodlightActivitiesListCall {
32896	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32897	return c
32898}
32899
32900// IfNoneMatch sets the optional parameter which makes the operation
32901// fail if the object's ETag matches the given value. This is useful for
32902// getting updates only after the object has changed since the last
32903// request. Use googleapi.IsNotModified to check whether the response
32904// error from Do is the result of In-None-Match.
32905func (c *FloodlightActivitiesListCall) IfNoneMatch(entityTag string) *FloodlightActivitiesListCall {
32906	c.ifNoneMatch_ = entityTag
32907	return c
32908}
32909
32910// Context sets the context to be used in this call's Do method. Any
32911// pending HTTP request will be aborted if the provided context is
32912// canceled.
32913func (c *FloodlightActivitiesListCall) Context(ctx context.Context) *FloodlightActivitiesListCall {
32914	c.ctx_ = ctx
32915	return c
32916}
32917
32918// Header returns an http.Header that can be modified by the caller to
32919// add HTTP headers to the request.
32920func (c *FloodlightActivitiesListCall) Header() http.Header {
32921	if c.header_ == nil {
32922		c.header_ = make(http.Header)
32923	}
32924	return c.header_
32925}
32926
32927func (c *FloodlightActivitiesListCall) doRequest(alt string) (*http.Response, error) {
32928	reqHeaders := make(http.Header)
32929	for k, v := range c.header_ {
32930		reqHeaders[k] = v
32931	}
32932	reqHeaders.Set("User-Agent", c.s.userAgent())
32933	if c.ifNoneMatch_ != "" {
32934		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32935	}
32936	var body io.Reader = nil
32937	c.urlParams_.Set("alt", alt)
32938	c.urlParams_.Set("prettyPrint", "false")
32939	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
32940	urls += "?" + c.urlParams_.Encode()
32941	req, err := http.NewRequest("GET", urls, body)
32942	if err != nil {
32943		return nil, err
32944	}
32945	req.Header = reqHeaders
32946	googleapi.Expand(req.URL, map[string]string{
32947		"profileId": strconv.FormatInt(c.profileId, 10),
32948	})
32949	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32950}
32951
32952// Do executes the "dfareporting.floodlightActivities.list" call.
32953// Exactly one of *FloodlightActivitiesListResponse or error will be
32954// non-nil. Any non-2xx status code is an error. Response headers are in
32955// either *FloodlightActivitiesListResponse.ServerResponse.Header or (if
32956// a response was returned at all) in error.(*googleapi.Error).Header.
32957// Use googleapi.IsNotModified to check whether the returned error was
32958// because http.StatusNotModified was returned.
32959func (c *FloodlightActivitiesListCall) Do(opts ...googleapi.CallOption) (*FloodlightActivitiesListResponse, error) {
32960	gensupport.SetOptions(c.urlParams_, opts...)
32961	res, err := c.doRequest("json")
32962	if res != nil && res.StatusCode == http.StatusNotModified {
32963		if res.Body != nil {
32964			res.Body.Close()
32965		}
32966		return nil, &googleapi.Error{
32967			Code:   res.StatusCode,
32968			Header: res.Header,
32969		}
32970	}
32971	if err != nil {
32972		return nil, err
32973	}
32974	defer googleapi.CloseBody(res)
32975	if err := googleapi.CheckResponse(res); err != nil {
32976		return nil, err
32977	}
32978	ret := &FloodlightActivitiesListResponse{
32979		ServerResponse: googleapi.ServerResponse{
32980			Header:         res.Header,
32981			HTTPStatusCode: res.StatusCode,
32982		},
32983	}
32984	target := &ret
32985	if err := gensupport.DecodeResponse(target, res); err != nil {
32986		return nil, err
32987	}
32988	return ret, nil
32989	// {
32990	//   "description": "Retrieves a list of floodlight activities, possibly filtered. This method supports paging.",
32991	//   "httpMethod": "GET",
32992	//   "id": "dfareporting.floodlightActivities.list",
32993	//   "parameterOrder": [
32994	//     "profileId"
32995	//   ],
32996	//   "parameters": {
32997	//     "advertiserId": {
32998	//       "description": "Select only floodlight activities for the specified advertiser ID. Must specify either ids, advertiserId, or floodlightConfigurationId for a non-empty result.",
32999	//       "format": "int64",
33000	//       "location": "query",
33001	//       "type": "string"
33002	//     },
33003	//     "floodlightActivityGroupIds": {
33004	//       "description": "Select only floodlight activities with the specified floodlight activity group IDs.",
33005	//       "format": "int64",
33006	//       "location": "query",
33007	//       "repeated": true,
33008	//       "type": "string"
33009	//     },
33010	//     "floodlightActivityGroupName": {
33011	//       "description": "Select only floodlight activities with the specified floodlight activity group name.",
33012	//       "location": "query",
33013	//       "type": "string"
33014	//     },
33015	//     "floodlightActivityGroupTagString": {
33016	//       "description": "Select only floodlight activities with the specified floodlight activity group tag string.",
33017	//       "location": "query",
33018	//       "type": "string"
33019	//     },
33020	//     "floodlightActivityGroupType": {
33021	//       "description": "Select only floodlight activities with the specified floodlight activity group type.",
33022	//       "enum": [
33023	//         "COUNTER",
33024	//         "SALE"
33025	//       ],
33026	//       "enumDescriptions": [
33027	//         "",
33028	//         ""
33029	//       ],
33030	//       "location": "query",
33031	//       "type": "string"
33032	//     },
33033	//     "floodlightConfigurationId": {
33034	//       "description": "Select only floodlight activities for the specified floodlight configuration ID. Must specify either ids, advertiserId, or floodlightConfigurationId for a non-empty result.",
33035	//       "format": "int64",
33036	//       "location": "query",
33037	//       "type": "string"
33038	//     },
33039	//     "ids": {
33040	//       "description": "Select only floodlight activities with the specified IDs. Must specify either ids, advertiserId, or floodlightConfigurationId for a non-empty result.",
33041	//       "format": "int64",
33042	//       "location": "query",
33043	//       "repeated": true,
33044	//       "type": "string"
33045	//     },
33046	//     "maxResults": {
33047	//       "default": "1000",
33048	//       "description": "Maximum number of results to return.",
33049	//       "format": "int32",
33050	//       "location": "query",
33051	//       "maximum": "1000",
33052	//       "minimum": "0",
33053	//       "type": "integer"
33054	//     },
33055	//     "pageToken": {
33056	//       "description": "Value of the nextPageToken from the previous result page.",
33057	//       "location": "query",
33058	//       "type": "string"
33059	//     },
33060	//     "profileId": {
33061	//       "description": "User profile ID associated with this request.",
33062	//       "format": "int64",
33063	//       "location": "path",
33064	//       "required": true,
33065	//       "type": "string"
33066	//     },
33067	//     "searchString": {
33068	//       "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\".",
33069	//       "location": "query",
33070	//       "type": "string"
33071	//     },
33072	//     "sortField": {
33073	//       "default": "ID",
33074	//       "description": "Field by which to sort the list.",
33075	//       "enum": [
33076	//         "ID",
33077	//         "NAME"
33078	//       ],
33079	//       "enumDescriptions": [
33080	//         "",
33081	//         ""
33082	//       ],
33083	//       "location": "query",
33084	//       "type": "string"
33085	//     },
33086	//     "sortOrder": {
33087	//       "default": "ASCENDING",
33088	//       "description": "Order of sorted results.",
33089	//       "enum": [
33090	//         "ASCENDING",
33091	//         "DESCENDING"
33092	//       ],
33093	//       "enumDescriptions": [
33094	//         "",
33095	//         ""
33096	//       ],
33097	//       "location": "query",
33098	//       "type": "string"
33099	//     },
33100	//     "tagString": {
33101	//       "description": "Select only floodlight activities with the specified tag string.",
33102	//       "location": "query",
33103	//       "type": "string"
33104	//     }
33105	//   },
33106	//   "path": "userprofiles/{profileId}/floodlightActivities",
33107	//   "response": {
33108	//     "$ref": "FloodlightActivitiesListResponse"
33109	//   },
33110	//   "scopes": [
33111	//     "https://www.googleapis.com/auth/dfatrafficking"
33112	//   ]
33113	// }
33114
33115}
33116
33117// Pages invokes f for each page of results.
33118// A non-nil error returned from f will halt the iteration.
33119// The provided context supersedes any context provided to the Context method.
33120func (c *FloodlightActivitiesListCall) Pages(ctx context.Context, f func(*FloodlightActivitiesListResponse) error) error {
33121	c.ctx_ = ctx
33122	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
33123	for {
33124		x, err := c.Do()
33125		if err != nil {
33126			return err
33127		}
33128		if err := f(x); err != nil {
33129			return err
33130		}
33131		if x.NextPageToken == "" {
33132			return nil
33133		}
33134		c.PageToken(x.NextPageToken)
33135	}
33136}
33137
33138// method id "dfareporting.floodlightActivities.patch":
33139
33140type FloodlightActivitiesPatchCall struct {
33141	s                  *Service
33142	profileId          int64
33143	floodlightactivity *FloodlightActivity
33144	urlParams_         gensupport.URLParams
33145	ctx_               context.Context
33146	header_            http.Header
33147}
33148
33149// Patch: Updates an existing floodlight activity. This method supports
33150// patch semantics.
33151func (r *FloodlightActivitiesService) Patch(profileId int64, id int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesPatchCall {
33152	c := &FloodlightActivitiesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33153	c.profileId = profileId
33154	c.urlParams_.Set("id", fmt.Sprint(id))
33155	c.floodlightactivity = floodlightactivity
33156	return c
33157}
33158
33159// Fields allows partial responses to be retrieved. See
33160// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33161// for more information.
33162func (c *FloodlightActivitiesPatchCall) Fields(s ...googleapi.Field) *FloodlightActivitiesPatchCall {
33163	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33164	return c
33165}
33166
33167// Context sets the context to be used in this call's Do method. Any
33168// pending HTTP request will be aborted if the provided context is
33169// canceled.
33170func (c *FloodlightActivitiesPatchCall) Context(ctx context.Context) *FloodlightActivitiesPatchCall {
33171	c.ctx_ = ctx
33172	return c
33173}
33174
33175// Header returns an http.Header that can be modified by the caller to
33176// add HTTP headers to the request.
33177func (c *FloodlightActivitiesPatchCall) Header() http.Header {
33178	if c.header_ == nil {
33179		c.header_ = make(http.Header)
33180	}
33181	return c.header_
33182}
33183
33184func (c *FloodlightActivitiesPatchCall) doRequest(alt string) (*http.Response, error) {
33185	reqHeaders := make(http.Header)
33186	for k, v := range c.header_ {
33187		reqHeaders[k] = v
33188	}
33189	reqHeaders.Set("User-Agent", c.s.userAgent())
33190	var body io.Reader = nil
33191	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
33192	if err != nil {
33193		return nil, err
33194	}
33195	reqHeaders.Set("Content-Type", "application/json")
33196	c.urlParams_.Set("alt", alt)
33197	c.urlParams_.Set("prettyPrint", "false")
33198	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33199	urls += "?" + c.urlParams_.Encode()
33200	req, err := http.NewRequest("PATCH", urls, body)
33201	if err != nil {
33202		return nil, err
33203	}
33204	req.Header = reqHeaders
33205	googleapi.Expand(req.URL, map[string]string{
33206		"profileId": strconv.FormatInt(c.profileId, 10),
33207	})
33208	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33209}
33210
33211// Do executes the "dfareporting.floodlightActivities.patch" call.
33212// Exactly one of *FloodlightActivity or error will be non-nil. Any
33213// non-2xx status code is an error. Response headers are in either
33214// *FloodlightActivity.ServerResponse.Header or (if a response was
33215// returned at all) in error.(*googleapi.Error).Header. Use
33216// googleapi.IsNotModified to check whether the returned error was
33217// because http.StatusNotModified was returned.
33218func (c *FloodlightActivitiesPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
33219	gensupport.SetOptions(c.urlParams_, opts...)
33220	res, err := c.doRequest("json")
33221	if res != nil && res.StatusCode == http.StatusNotModified {
33222		if res.Body != nil {
33223			res.Body.Close()
33224		}
33225		return nil, &googleapi.Error{
33226			Code:   res.StatusCode,
33227			Header: res.Header,
33228		}
33229	}
33230	if err != nil {
33231		return nil, err
33232	}
33233	defer googleapi.CloseBody(res)
33234	if err := googleapi.CheckResponse(res); err != nil {
33235		return nil, err
33236	}
33237	ret := &FloodlightActivity{
33238		ServerResponse: googleapi.ServerResponse{
33239			Header:         res.Header,
33240			HTTPStatusCode: res.StatusCode,
33241		},
33242	}
33243	target := &ret
33244	if err := gensupport.DecodeResponse(target, res); err != nil {
33245		return nil, err
33246	}
33247	return ret, nil
33248	// {
33249	//   "description": "Updates an existing floodlight activity. This method supports patch semantics.",
33250	//   "httpMethod": "PATCH",
33251	//   "id": "dfareporting.floodlightActivities.patch",
33252	//   "parameterOrder": [
33253	//     "profileId",
33254	//     "id"
33255	//   ],
33256	//   "parameters": {
33257	//     "id": {
33258	//       "description": "Floodlight activity ID.",
33259	//       "format": "int64",
33260	//       "location": "query",
33261	//       "required": true,
33262	//       "type": "string"
33263	//     },
33264	//     "profileId": {
33265	//       "description": "User profile ID associated with this request.",
33266	//       "format": "int64",
33267	//       "location": "path",
33268	//       "required": true,
33269	//       "type": "string"
33270	//     }
33271	//   },
33272	//   "path": "userprofiles/{profileId}/floodlightActivities",
33273	//   "request": {
33274	//     "$ref": "FloodlightActivity"
33275	//   },
33276	//   "response": {
33277	//     "$ref": "FloodlightActivity"
33278	//   },
33279	//   "scopes": [
33280	//     "https://www.googleapis.com/auth/dfatrafficking"
33281	//   ]
33282	// }
33283
33284}
33285
33286// method id "dfareporting.floodlightActivities.update":
33287
33288type FloodlightActivitiesUpdateCall struct {
33289	s                  *Service
33290	profileId          int64
33291	floodlightactivity *FloodlightActivity
33292	urlParams_         gensupport.URLParams
33293	ctx_               context.Context
33294	header_            http.Header
33295}
33296
33297// Update: Updates an existing floodlight activity.
33298func (r *FloodlightActivitiesService) Update(profileId int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesUpdateCall {
33299	c := &FloodlightActivitiesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33300	c.profileId = profileId
33301	c.floodlightactivity = floodlightactivity
33302	return c
33303}
33304
33305// Fields allows partial responses to be retrieved. See
33306// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33307// for more information.
33308func (c *FloodlightActivitiesUpdateCall) Fields(s ...googleapi.Field) *FloodlightActivitiesUpdateCall {
33309	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33310	return c
33311}
33312
33313// Context sets the context to be used in this call's Do method. Any
33314// pending HTTP request will be aborted if the provided context is
33315// canceled.
33316func (c *FloodlightActivitiesUpdateCall) Context(ctx context.Context) *FloodlightActivitiesUpdateCall {
33317	c.ctx_ = ctx
33318	return c
33319}
33320
33321// Header returns an http.Header that can be modified by the caller to
33322// add HTTP headers to the request.
33323func (c *FloodlightActivitiesUpdateCall) Header() http.Header {
33324	if c.header_ == nil {
33325		c.header_ = make(http.Header)
33326	}
33327	return c.header_
33328}
33329
33330func (c *FloodlightActivitiesUpdateCall) doRequest(alt string) (*http.Response, error) {
33331	reqHeaders := make(http.Header)
33332	for k, v := range c.header_ {
33333		reqHeaders[k] = v
33334	}
33335	reqHeaders.Set("User-Agent", c.s.userAgent())
33336	var body io.Reader = nil
33337	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
33338	if err != nil {
33339		return nil, err
33340	}
33341	reqHeaders.Set("Content-Type", "application/json")
33342	c.urlParams_.Set("alt", alt)
33343	c.urlParams_.Set("prettyPrint", "false")
33344	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33345	urls += "?" + c.urlParams_.Encode()
33346	req, err := http.NewRequest("PUT", urls, body)
33347	if err != nil {
33348		return nil, err
33349	}
33350	req.Header = reqHeaders
33351	googleapi.Expand(req.URL, map[string]string{
33352		"profileId": strconv.FormatInt(c.profileId, 10),
33353	})
33354	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33355}
33356
33357// Do executes the "dfareporting.floodlightActivities.update" call.
33358// Exactly one of *FloodlightActivity or error will be non-nil. Any
33359// non-2xx status code is an error. Response headers are in either
33360// *FloodlightActivity.ServerResponse.Header or (if a response was
33361// returned at all) in error.(*googleapi.Error).Header. Use
33362// googleapi.IsNotModified to check whether the returned error was
33363// because http.StatusNotModified was returned.
33364func (c *FloodlightActivitiesUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
33365	gensupport.SetOptions(c.urlParams_, opts...)
33366	res, err := c.doRequest("json")
33367	if res != nil && res.StatusCode == http.StatusNotModified {
33368		if res.Body != nil {
33369			res.Body.Close()
33370		}
33371		return nil, &googleapi.Error{
33372			Code:   res.StatusCode,
33373			Header: res.Header,
33374		}
33375	}
33376	if err != nil {
33377		return nil, err
33378	}
33379	defer googleapi.CloseBody(res)
33380	if err := googleapi.CheckResponse(res); err != nil {
33381		return nil, err
33382	}
33383	ret := &FloodlightActivity{
33384		ServerResponse: googleapi.ServerResponse{
33385			Header:         res.Header,
33386			HTTPStatusCode: res.StatusCode,
33387		},
33388	}
33389	target := &ret
33390	if err := gensupport.DecodeResponse(target, res); err != nil {
33391		return nil, err
33392	}
33393	return ret, nil
33394	// {
33395	//   "description": "Updates an existing floodlight activity.",
33396	//   "httpMethod": "PUT",
33397	//   "id": "dfareporting.floodlightActivities.update",
33398	//   "parameterOrder": [
33399	//     "profileId"
33400	//   ],
33401	//   "parameters": {
33402	//     "profileId": {
33403	//       "description": "User profile ID associated with this request.",
33404	//       "format": "int64",
33405	//       "location": "path",
33406	//       "required": true,
33407	//       "type": "string"
33408	//     }
33409	//   },
33410	//   "path": "userprofiles/{profileId}/floodlightActivities",
33411	//   "request": {
33412	//     "$ref": "FloodlightActivity"
33413	//   },
33414	//   "response": {
33415	//     "$ref": "FloodlightActivity"
33416	//   },
33417	//   "scopes": [
33418	//     "https://www.googleapis.com/auth/dfatrafficking"
33419	//   ]
33420	// }
33421
33422}
33423
33424// method id "dfareporting.floodlightActivityGroups.get":
33425
33426type FloodlightActivityGroupsGetCall struct {
33427	s            *Service
33428	profileId    int64
33429	id           int64
33430	urlParams_   gensupport.URLParams
33431	ifNoneMatch_ string
33432	ctx_         context.Context
33433	header_      http.Header
33434}
33435
33436// Get: Gets one floodlight activity group by ID.
33437func (r *FloodlightActivityGroupsService) Get(profileId int64, id int64) *FloodlightActivityGroupsGetCall {
33438	c := &FloodlightActivityGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33439	c.profileId = profileId
33440	c.id = id
33441	return c
33442}
33443
33444// Fields allows partial responses to be retrieved. See
33445// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33446// for more information.
33447func (c *FloodlightActivityGroupsGetCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsGetCall {
33448	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33449	return c
33450}
33451
33452// IfNoneMatch sets the optional parameter which makes the operation
33453// fail if the object's ETag matches the given value. This is useful for
33454// getting updates only after the object has changed since the last
33455// request. Use googleapi.IsNotModified to check whether the response
33456// error from Do is the result of In-None-Match.
33457func (c *FloodlightActivityGroupsGetCall) IfNoneMatch(entityTag string) *FloodlightActivityGroupsGetCall {
33458	c.ifNoneMatch_ = entityTag
33459	return c
33460}
33461
33462// Context sets the context to be used in this call's Do method. Any
33463// pending HTTP request will be aborted if the provided context is
33464// canceled.
33465func (c *FloodlightActivityGroupsGetCall) Context(ctx context.Context) *FloodlightActivityGroupsGetCall {
33466	c.ctx_ = ctx
33467	return c
33468}
33469
33470// Header returns an http.Header that can be modified by the caller to
33471// add HTTP headers to the request.
33472func (c *FloodlightActivityGroupsGetCall) Header() http.Header {
33473	if c.header_ == nil {
33474		c.header_ = make(http.Header)
33475	}
33476	return c.header_
33477}
33478
33479func (c *FloodlightActivityGroupsGetCall) doRequest(alt string) (*http.Response, error) {
33480	reqHeaders := make(http.Header)
33481	for k, v := range c.header_ {
33482		reqHeaders[k] = v
33483	}
33484	reqHeaders.Set("User-Agent", c.s.userAgent())
33485	if c.ifNoneMatch_ != "" {
33486		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33487	}
33488	var body io.Reader = nil
33489	c.urlParams_.Set("alt", alt)
33490	c.urlParams_.Set("prettyPrint", "false")
33491	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups/{id}")
33492	urls += "?" + c.urlParams_.Encode()
33493	req, err := http.NewRequest("GET", urls, body)
33494	if err != nil {
33495		return nil, err
33496	}
33497	req.Header = reqHeaders
33498	googleapi.Expand(req.URL, map[string]string{
33499		"profileId": strconv.FormatInt(c.profileId, 10),
33500		"id":        strconv.FormatInt(c.id, 10),
33501	})
33502	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33503}
33504
33505// Do executes the "dfareporting.floodlightActivityGroups.get" call.
33506// Exactly one of *FloodlightActivityGroup or error will be non-nil. Any
33507// non-2xx status code is an error. Response headers are in either
33508// *FloodlightActivityGroup.ServerResponse.Header or (if a response was
33509// returned at all) in error.(*googleapi.Error).Header. Use
33510// googleapi.IsNotModified to check whether the returned error was
33511// because http.StatusNotModified was returned.
33512func (c *FloodlightActivityGroupsGetCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
33513	gensupport.SetOptions(c.urlParams_, opts...)
33514	res, err := c.doRequest("json")
33515	if res != nil && res.StatusCode == http.StatusNotModified {
33516		if res.Body != nil {
33517			res.Body.Close()
33518		}
33519		return nil, &googleapi.Error{
33520			Code:   res.StatusCode,
33521			Header: res.Header,
33522		}
33523	}
33524	if err != nil {
33525		return nil, err
33526	}
33527	defer googleapi.CloseBody(res)
33528	if err := googleapi.CheckResponse(res); err != nil {
33529		return nil, err
33530	}
33531	ret := &FloodlightActivityGroup{
33532		ServerResponse: googleapi.ServerResponse{
33533			Header:         res.Header,
33534			HTTPStatusCode: res.StatusCode,
33535		},
33536	}
33537	target := &ret
33538	if err := gensupport.DecodeResponse(target, res); err != nil {
33539		return nil, err
33540	}
33541	return ret, nil
33542	// {
33543	//   "description": "Gets one floodlight activity group by ID.",
33544	//   "httpMethod": "GET",
33545	//   "id": "dfareporting.floodlightActivityGroups.get",
33546	//   "parameterOrder": [
33547	//     "profileId",
33548	//     "id"
33549	//   ],
33550	//   "parameters": {
33551	//     "id": {
33552	//       "description": "Floodlight activity Group ID.",
33553	//       "format": "int64",
33554	//       "location": "path",
33555	//       "required": true,
33556	//       "type": "string"
33557	//     },
33558	//     "profileId": {
33559	//       "description": "User profile ID associated with this request.",
33560	//       "format": "int64",
33561	//       "location": "path",
33562	//       "required": true,
33563	//       "type": "string"
33564	//     }
33565	//   },
33566	//   "path": "userprofiles/{profileId}/floodlightActivityGroups/{id}",
33567	//   "response": {
33568	//     "$ref": "FloodlightActivityGroup"
33569	//   },
33570	//   "scopes": [
33571	//     "https://www.googleapis.com/auth/dfatrafficking"
33572	//   ]
33573	// }
33574
33575}
33576
33577// method id "dfareporting.floodlightActivityGroups.insert":
33578
33579type FloodlightActivityGroupsInsertCall struct {
33580	s                       *Service
33581	profileId               int64
33582	floodlightactivitygroup *FloodlightActivityGroup
33583	urlParams_              gensupport.URLParams
33584	ctx_                    context.Context
33585	header_                 http.Header
33586}
33587
33588// Insert: Inserts a new floodlight activity group.
33589func (r *FloodlightActivityGroupsService) Insert(profileId int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsInsertCall {
33590	c := &FloodlightActivityGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33591	c.profileId = profileId
33592	c.floodlightactivitygroup = floodlightactivitygroup
33593	return c
33594}
33595
33596// Fields allows partial responses to be retrieved. See
33597// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33598// for more information.
33599func (c *FloodlightActivityGroupsInsertCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsInsertCall {
33600	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33601	return c
33602}
33603
33604// Context sets the context to be used in this call's Do method. Any
33605// pending HTTP request will be aborted if the provided context is
33606// canceled.
33607func (c *FloodlightActivityGroupsInsertCall) Context(ctx context.Context) *FloodlightActivityGroupsInsertCall {
33608	c.ctx_ = ctx
33609	return c
33610}
33611
33612// Header returns an http.Header that can be modified by the caller to
33613// add HTTP headers to the request.
33614func (c *FloodlightActivityGroupsInsertCall) Header() http.Header {
33615	if c.header_ == nil {
33616		c.header_ = make(http.Header)
33617	}
33618	return c.header_
33619}
33620
33621func (c *FloodlightActivityGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
33622	reqHeaders := make(http.Header)
33623	for k, v := range c.header_ {
33624		reqHeaders[k] = v
33625	}
33626	reqHeaders.Set("User-Agent", c.s.userAgent())
33627	var body io.Reader = nil
33628	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
33629	if err != nil {
33630		return nil, err
33631	}
33632	reqHeaders.Set("Content-Type", "application/json")
33633	c.urlParams_.Set("alt", alt)
33634	c.urlParams_.Set("prettyPrint", "false")
33635	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
33636	urls += "?" + c.urlParams_.Encode()
33637	req, err := http.NewRequest("POST", urls, body)
33638	if err != nil {
33639		return nil, err
33640	}
33641	req.Header = reqHeaders
33642	googleapi.Expand(req.URL, map[string]string{
33643		"profileId": strconv.FormatInt(c.profileId, 10),
33644	})
33645	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33646}
33647
33648// Do executes the "dfareporting.floodlightActivityGroups.insert" call.
33649// Exactly one of *FloodlightActivityGroup or error will be non-nil. Any
33650// non-2xx status code is an error. Response headers are in either
33651// *FloodlightActivityGroup.ServerResponse.Header or (if a response was
33652// returned at all) in error.(*googleapi.Error).Header. Use
33653// googleapi.IsNotModified to check whether the returned error was
33654// because http.StatusNotModified was returned.
33655func (c *FloodlightActivityGroupsInsertCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
33656	gensupport.SetOptions(c.urlParams_, opts...)
33657	res, err := c.doRequest("json")
33658	if res != nil && res.StatusCode == http.StatusNotModified {
33659		if res.Body != nil {
33660			res.Body.Close()
33661		}
33662		return nil, &googleapi.Error{
33663			Code:   res.StatusCode,
33664			Header: res.Header,
33665		}
33666	}
33667	if err != nil {
33668		return nil, err
33669	}
33670	defer googleapi.CloseBody(res)
33671	if err := googleapi.CheckResponse(res); err != nil {
33672		return nil, err
33673	}
33674	ret := &FloodlightActivityGroup{
33675		ServerResponse: googleapi.ServerResponse{
33676			Header:         res.Header,
33677			HTTPStatusCode: res.StatusCode,
33678		},
33679	}
33680	target := &ret
33681	if err := gensupport.DecodeResponse(target, res); err != nil {
33682		return nil, err
33683	}
33684	return ret, nil
33685	// {
33686	//   "description": "Inserts a new floodlight activity group.",
33687	//   "httpMethod": "POST",
33688	//   "id": "dfareporting.floodlightActivityGroups.insert",
33689	//   "parameterOrder": [
33690	//     "profileId"
33691	//   ],
33692	//   "parameters": {
33693	//     "profileId": {
33694	//       "description": "User profile ID associated with this request.",
33695	//       "format": "int64",
33696	//       "location": "path",
33697	//       "required": true,
33698	//       "type": "string"
33699	//     }
33700	//   },
33701	//   "path": "userprofiles/{profileId}/floodlightActivityGroups",
33702	//   "request": {
33703	//     "$ref": "FloodlightActivityGroup"
33704	//   },
33705	//   "response": {
33706	//     "$ref": "FloodlightActivityGroup"
33707	//   },
33708	//   "scopes": [
33709	//     "https://www.googleapis.com/auth/dfatrafficking"
33710	//   ]
33711	// }
33712
33713}
33714
33715// method id "dfareporting.floodlightActivityGroups.list":
33716
33717type FloodlightActivityGroupsListCall struct {
33718	s            *Service
33719	profileId    int64
33720	urlParams_   gensupport.URLParams
33721	ifNoneMatch_ string
33722	ctx_         context.Context
33723	header_      http.Header
33724}
33725
33726// List: Retrieves a list of floodlight activity groups, possibly
33727// filtered. This method supports paging.
33728func (r *FloodlightActivityGroupsService) List(profileId int64) *FloodlightActivityGroupsListCall {
33729	c := &FloodlightActivityGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33730	c.profileId = profileId
33731	return c
33732}
33733
33734// AdvertiserId sets the optional parameter "advertiserId": Select only
33735// floodlight activity groups with the specified advertiser ID. Must
33736// specify either advertiserId or floodlightConfigurationId for a
33737// non-empty result.
33738func (c *FloodlightActivityGroupsListCall) AdvertiserId(advertiserId int64) *FloodlightActivityGroupsListCall {
33739	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
33740	return c
33741}
33742
33743// FloodlightConfigurationId sets the optional parameter
33744// "floodlightConfigurationId": Select only floodlight activity groups
33745// with the specified floodlight configuration ID. Must specify either
33746// advertiserId, or floodlightConfigurationId for a non-empty result.
33747func (c *FloodlightActivityGroupsListCall) FloodlightConfigurationId(floodlightConfigurationId int64) *FloodlightActivityGroupsListCall {
33748	c.urlParams_.Set("floodlightConfigurationId", fmt.Sprint(floodlightConfigurationId))
33749	return c
33750}
33751
33752// Ids sets the optional parameter "ids": Select only floodlight
33753// activity groups with the specified IDs. Must specify either
33754// advertiserId or floodlightConfigurationId for a non-empty result.
33755func (c *FloodlightActivityGroupsListCall) Ids(ids ...int64) *FloodlightActivityGroupsListCall {
33756	var ids_ []string
33757	for _, v := range ids {
33758		ids_ = append(ids_, fmt.Sprint(v))
33759	}
33760	c.urlParams_.SetMulti("ids", ids_)
33761	return c
33762}
33763
33764// MaxResults sets the optional parameter "maxResults": Maximum number
33765// of results to return.
33766func (c *FloodlightActivityGroupsListCall) MaxResults(maxResults int64) *FloodlightActivityGroupsListCall {
33767	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
33768	return c
33769}
33770
33771// PageToken sets the optional parameter "pageToken": Value of the
33772// nextPageToken from the previous result page.
33773func (c *FloodlightActivityGroupsListCall) PageToken(pageToken string) *FloodlightActivityGroupsListCall {
33774	c.urlParams_.Set("pageToken", pageToken)
33775	return c
33776}
33777
33778// SearchString sets the optional parameter "searchString": Allows
33779// searching for objects by name or ID. Wildcards (*) are allowed. For
33780// example, "floodlightactivitygroup*2015" will return objects with
33781// names like "floodlightactivitygroup June 2015",
33782// "floodlightactivitygroup April 2015", or simply
33783// "floodlightactivitygroup 2015". Most of the searches also add
33784// wildcards implicitly at the start and the end of the search string.
33785// For example, a search string of "floodlightactivitygroup" will match
33786// objects with name "my floodlightactivitygroup activity",
33787// "floodlightactivitygroup 2015", or simply "floodlightactivitygroup".
33788func (c *FloodlightActivityGroupsListCall) SearchString(searchString string) *FloodlightActivityGroupsListCall {
33789	c.urlParams_.Set("searchString", searchString)
33790	return c
33791}
33792
33793// SortField sets the optional parameter "sortField": Field by which to
33794// sort the list.
33795//
33796// Possible values:
33797//   "ID" (default)
33798//   "NAME"
33799func (c *FloodlightActivityGroupsListCall) SortField(sortField string) *FloodlightActivityGroupsListCall {
33800	c.urlParams_.Set("sortField", sortField)
33801	return c
33802}
33803
33804// SortOrder sets the optional parameter "sortOrder": Order of sorted
33805// results.
33806//
33807// Possible values:
33808//   "ASCENDING" (default)
33809//   "DESCENDING"
33810func (c *FloodlightActivityGroupsListCall) SortOrder(sortOrder string) *FloodlightActivityGroupsListCall {
33811	c.urlParams_.Set("sortOrder", sortOrder)
33812	return c
33813}
33814
33815// Type sets the optional parameter "type": Select only floodlight
33816// activity groups with the specified floodlight activity group type.
33817//
33818// Possible values:
33819//   "COUNTER"
33820//   "SALE"
33821func (c *FloodlightActivityGroupsListCall) Type(type_ string) *FloodlightActivityGroupsListCall {
33822	c.urlParams_.Set("type", type_)
33823	return c
33824}
33825
33826// Fields allows partial responses to be retrieved. See
33827// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33828// for more information.
33829func (c *FloodlightActivityGroupsListCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsListCall {
33830	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33831	return c
33832}
33833
33834// IfNoneMatch sets the optional parameter which makes the operation
33835// fail if the object's ETag matches the given value. This is useful for
33836// getting updates only after the object has changed since the last
33837// request. Use googleapi.IsNotModified to check whether the response
33838// error from Do is the result of In-None-Match.
33839func (c *FloodlightActivityGroupsListCall) IfNoneMatch(entityTag string) *FloodlightActivityGroupsListCall {
33840	c.ifNoneMatch_ = entityTag
33841	return c
33842}
33843
33844// Context sets the context to be used in this call's Do method. Any
33845// pending HTTP request will be aborted if the provided context is
33846// canceled.
33847func (c *FloodlightActivityGroupsListCall) Context(ctx context.Context) *FloodlightActivityGroupsListCall {
33848	c.ctx_ = ctx
33849	return c
33850}
33851
33852// Header returns an http.Header that can be modified by the caller to
33853// add HTTP headers to the request.
33854func (c *FloodlightActivityGroupsListCall) Header() http.Header {
33855	if c.header_ == nil {
33856		c.header_ = make(http.Header)
33857	}
33858	return c.header_
33859}
33860
33861func (c *FloodlightActivityGroupsListCall) doRequest(alt string) (*http.Response, error) {
33862	reqHeaders := make(http.Header)
33863	for k, v := range c.header_ {
33864		reqHeaders[k] = v
33865	}
33866	reqHeaders.Set("User-Agent", c.s.userAgent())
33867	if c.ifNoneMatch_ != "" {
33868		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33869	}
33870	var body io.Reader = nil
33871	c.urlParams_.Set("alt", alt)
33872	c.urlParams_.Set("prettyPrint", "false")
33873	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
33874	urls += "?" + c.urlParams_.Encode()
33875	req, err := http.NewRequest("GET", urls, body)
33876	if err != nil {
33877		return nil, err
33878	}
33879	req.Header = reqHeaders
33880	googleapi.Expand(req.URL, map[string]string{
33881		"profileId": strconv.FormatInt(c.profileId, 10),
33882	})
33883	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33884}
33885
33886// Do executes the "dfareporting.floodlightActivityGroups.list" call.
33887// Exactly one of *FloodlightActivityGroupsListResponse or error will be
33888// non-nil. Any non-2xx status code is an error. Response headers are in
33889// either *FloodlightActivityGroupsListResponse.ServerResponse.Header or
33890// (if a response was returned at all) in
33891// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33892// whether the returned error was because http.StatusNotModified was
33893// returned.
33894func (c *FloodlightActivityGroupsListCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroupsListResponse, error) {
33895	gensupport.SetOptions(c.urlParams_, opts...)
33896	res, err := c.doRequest("json")
33897	if res != nil && res.StatusCode == http.StatusNotModified {
33898		if res.Body != nil {
33899			res.Body.Close()
33900		}
33901		return nil, &googleapi.Error{
33902			Code:   res.StatusCode,
33903			Header: res.Header,
33904		}
33905	}
33906	if err != nil {
33907		return nil, err
33908	}
33909	defer googleapi.CloseBody(res)
33910	if err := googleapi.CheckResponse(res); err != nil {
33911		return nil, err
33912	}
33913	ret := &FloodlightActivityGroupsListResponse{
33914		ServerResponse: googleapi.ServerResponse{
33915			Header:         res.Header,
33916			HTTPStatusCode: res.StatusCode,
33917		},
33918	}
33919	target := &ret
33920	if err := gensupport.DecodeResponse(target, res); err != nil {
33921		return nil, err
33922	}
33923	return ret, nil
33924	// {
33925	//   "description": "Retrieves a list of floodlight activity groups, possibly filtered. This method supports paging.",
33926	//   "httpMethod": "GET",
33927	//   "id": "dfareporting.floodlightActivityGroups.list",
33928	//   "parameterOrder": [
33929	//     "profileId"
33930	//   ],
33931	//   "parameters": {
33932	//     "advertiserId": {
33933	//       "description": "Select only floodlight activity groups with the specified advertiser ID. Must specify either advertiserId or floodlightConfigurationId for a non-empty result.",
33934	//       "format": "int64",
33935	//       "location": "query",
33936	//       "type": "string"
33937	//     },
33938	//     "floodlightConfigurationId": {
33939	//       "description": "Select only floodlight activity groups with the specified floodlight configuration ID. Must specify either advertiserId, or floodlightConfigurationId for a non-empty result.",
33940	//       "format": "int64",
33941	//       "location": "query",
33942	//       "type": "string"
33943	//     },
33944	//     "ids": {
33945	//       "description": "Select only floodlight activity groups with the specified IDs. Must specify either advertiserId or floodlightConfigurationId for a non-empty result.",
33946	//       "format": "int64",
33947	//       "location": "query",
33948	//       "repeated": true,
33949	//       "type": "string"
33950	//     },
33951	//     "maxResults": {
33952	//       "default": "1000",
33953	//       "description": "Maximum number of results to return.",
33954	//       "format": "int32",
33955	//       "location": "query",
33956	//       "maximum": "1000",
33957	//       "minimum": "0",
33958	//       "type": "integer"
33959	//     },
33960	//     "pageToken": {
33961	//       "description": "Value of the nextPageToken from the previous result page.",
33962	//       "location": "query",
33963	//       "type": "string"
33964	//     },
33965	//     "profileId": {
33966	//       "description": "User profile ID associated with this request.",
33967	//       "format": "int64",
33968	//       "location": "path",
33969	//       "required": true,
33970	//       "type": "string"
33971	//     },
33972	//     "searchString": {
33973	//       "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\".",
33974	//       "location": "query",
33975	//       "type": "string"
33976	//     },
33977	//     "sortField": {
33978	//       "default": "ID",
33979	//       "description": "Field by which to sort the list.",
33980	//       "enum": [
33981	//         "ID",
33982	//         "NAME"
33983	//       ],
33984	//       "enumDescriptions": [
33985	//         "",
33986	//         ""
33987	//       ],
33988	//       "location": "query",
33989	//       "type": "string"
33990	//     },
33991	//     "sortOrder": {
33992	//       "default": "ASCENDING",
33993	//       "description": "Order of sorted results.",
33994	//       "enum": [
33995	//         "ASCENDING",
33996	//         "DESCENDING"
33997	//       ],
33998	//       "enumDescriptions": [
33999	//         "",
34000	//         ""
34001	//       ],
34002	//       "location": "query",
34003	//       "type": "string"
34004	//     },
34005	//     "type": {
34006	//       "description": "Select only floodlight activity groups with the specified floodlight activity group type.",
34007	//       "enum": [
34008	//         "COUNTER",
34009	//         "SALE"
34010	//       ],
34011	//       "enumDescriptions": [
34012	//         "",
34013	//         ""
34014	//       ],
34015	//       "location": "query",
34016	//       "type": "string"
34017	//     }
34018	//   },
34019	//   "path": "userprofiles/{profileId}/floodlightActivityGroups",
34020	//   "response": {
34021	//     "$ref": "FloodlightActivityGroupsListResponse"
34022	//   },
34023	//   "scopes": [
34024	//     "https://www.googleapis.com/auth/dfatrafficking"
34025	//   ]
34026	// }
34027
34028}
34029
34030// Pages invokes f for each page of results.
34031// A non-nil error returned from f will halt the iteration.
34032// The provided context supersedes any context provided to the Context method.
34033func (c *FloodlightActivityGroupsListCall) Pages(ctx context.Context, f func(*FloodlightActivityGroupsListResponse) error) error {
34034	c.ctx_ = ctx
34035	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
34036	for {
34037		x, err := c.Do()
34038		if err != nil {
34039			return err
34040		}
34041		if err := f(x); err != nil {
34042			return err
34043		}
34044		if x.NextPageToken == "" {
34045			return nil
34046		}
34047		c.PageToken(x.NextPageToken)
34048	}
34049}
34050
34051// method id "dfareporting.floodlightActivityGroups.patch":
34052
34053type FloodlightActivityGroupsPatchCall struct {
34054	s                       *Service
34055	profileId               int64
34056	floodlightactivitygroup *FloodlightActivityGroup
34057	urlParams_              gensupport.URLParams
34058	ctx_                    context.Context
34059	header_                 http.Header
34060}
34061
34062// Patch: Updates an existing floodlight activity group. This method
34063// supports patch semantics.
34064func (r *FloodlightActivityGroupsService) Patch(profileId int64, id int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsPatchCall {
34065	c := &FloodlightActivityGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34066	c.profileId = profileId
34067	c.urlParams_.Set("id", fmt.Sprint(id))
34068	c.floodlightactivitygroup = floodlightactivitygroup
34069	return c
34070}
34071
34072// Fields allows partial responses to be retrieved. See
34073// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34074// for more information.
34075func (c *FloodlightActivityGroupsPatchCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsPatchCall {
34076	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34077	return c
34078}
34079
34080// Context sets the context to be used in this call's Do method. Any
34081// pending HTTP request will be aborted if the provided context is
34082// canceled.
34083func (c *FloodlightActivityGroupsPatchCall) Context(ctx context.Context) *FloodlightActivityGroupsPatchCall {
34084	c.ctx_ = ctx
34085	return c
34086}
34087
34088// Header returns an http.Header that can be modified by the caller to
34089// add HTTP headers to the request.
34090func (c *FloodlightActivityGroupsPatchCall) Header() http.Header {
34091	if c.header_ == nil {
34092		c.header_ = make(http.Header)
34093	}
34094	return c.header_
34095}
34096
34097func (c *FloodlightActivityGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
34098	reqHeaders := make(http.Header)
34099	for k, v := range c.header_ {
34100		reqHeaders[k] = v
34101	}
34102	reqHeaders.Set("User-Agent", c.s.userAgent())
34103	var body io.Reader = nil
34104	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
34105	if err != nil {
34106		return nil, err
34107	}
34108	reqHeaders.Set("Content-Type", "application/json")
34109	c.urlParams_.Set("alt", alt)
34110	c.urlParams_.Set("prettyPrint", "false")
34111	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34112	urls += "?" + c.urlParams_.Encode()
34113	req, err := http.NewRequest("PATCH", urls, body)
34114	if err != nil {
34115		return nil, err
34116	}
34117	req.Header = reqHeaders
34118	googleapi.Expand(req.URL, map[string]string{
34119		"profileId": strconv.FormatInt(c.profileId, 10),
34120	})
34121	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34122}
34123
34124// Do executes the "dfareporting.floodlightActivityGroups.patch" call.
34125// Exactly one of *FloodlightActivityGroup or error will be non-nil. Any
34126// non-2xx status code is an error. Response headers are in either
34127// *FloodlightActivityGroup.ServerResponse.Header or (if a response was
34128// returned at all) in error.(*googleapi.Error).Header. Use
34129// googleapi.IsNotModified to check whether the returned error was
34130// because http.StatusNotModified was returned.
34131func (c *FloodlightActivityGroupsPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
34132	gensupport.SetOptions(c.urlParams_, opts...)
34133	res, err := c.doRequest("json")
34134	if res != nil && res.StatusCode == http.StatusNotModified {
34135		if res.Body != nil {
34136			res.Body.Close()
34137		}
34138		return nil, &googleapi.Error{
34139			Code:   res.StatusCode,
34140			Header: res.Header,
34141		}
34142	}
34143	if err != nil {
34144		return nil, err
34145	}
34146	defer googleapi.CloseBody(res)
34147	if err := googleapi.CheckResponse(res); err != nil {
34148		return nil, err
34149	}
34150	ret := &FloodlightActivityGroup{
34151		ServerResponse: googleapi.ServerResponse{
34152			Header:         res.Header,
34153			HTTPStatusCode: res.StatusCode,
34154		},
34155	}
34156	target := &ret
34157	if err := gensupport.DecodeResponse(target, res); err != nil {
34158		return nil, err
34159	}
34160	return ret, nil
34161	// {
34162	//   "description": "Updates an existing floodlight activity group. This method supports patch semantics.",
34163	//   "httpMethod": "PATCH",
34164	//   "id": "dfareporting.floodlightActivityGroups.patch",
34165	//   "parameterOrder": [
34166	//     "profileId",
34167	//     "id"
34168	//   ],
34169	//   "parameters": {
34170	//     "id": {
34171	//       "description": "Floodlight activity Group ID.",
34172	//       "format": "int64",
34173	//       "location": "query",
34174	//       "required": true,
34175	//       "type": "string"
34176	//     },
34177	//     "profileId": {
34178	//       "description": "User profile ID associated with this request.",
34179	//       "format": "int64",
34180	//       "location": "path",
34181	//       "required": true,
34182	//       "type": "string"
34183	//     }
34184	//   },
34185	//   "path": "userprofiles/{profileId}/floodlightActivityGroups",
34186	//   "request": {
34187	//     "$ref": "FloodlightActivityGroup"
34188	//   },
34189	//   "response": {
34190	//     "$ref": "FloodlightActivityGroup"
34191	//   },
34192	//   "scopes": [
34193	//     "https://www.googleapis.com/auth/dfatrafficking"
34194	//   ]
34195	// }
34196
34197}
34198
34199// method id "dfareporting.floodlightActivityGroups.update":
34200
34201type FloodlightActivityGroupsUpdateCall struct {
34202	s                       *Service
34203	profileId               int64
34204	floodlightactivitygroup *FloodlightActivityGroup
34205	urlParams_              gensupport.URLParams
34206	ctx_                    context.Context
34207	header_                 http.Header
34208}
34209
34210// Update: Updates an existing floodlight activity group.
34211func (r *FloodlightActivityGroupsService) Update(profileId int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsUpdateCall {
34212	c := &FloodlightActivityGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34213	c.profileId = profileId
34214	c.floodlightactivitygroup = floodlightactivitygroup
34215	return c
34216}
34217
34218// Fields allows partial responses to be retrieved. See
34219// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34220// for more information.
34221func (c *FloodlightActivityGroupsUpdateCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsUpdateCall {
34222	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34223	return c
34224}
34225
34226// Context sets the context to be used in this call's Do method. Any
34227// pending HTTP request will be aborted if the provided context is
34228// canceled.
34229func (c *FloodlightActivityGroupsUpdateCall) Context(ctx context.Context) *FloodlightActivityGroupsUpdateCall {
34230	c.ctx_ = ctx
34231	return c
34232}
34233
34234// Header returns an http.Header that can be modified by the caller to
34235// add HTTP headers to the request.
34236func (c *FloodlightActivityGroupsUpdateCall) Header() http.Header {
34237	if c.header_ == nil {
34238		c.header_ = make(http.Header)
34239	}
34240	return c.header_
34241}
34242
34243func (c *FloodlightActivityGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
34244	reqHeaders := make(http.Header)
34245	for k, v := range c.header_ {
34246		reqHeaders[k] = v
34247	}
34248	reqHeaders.Set("User-Agent", c.s.userAgent())
34249	var body io.Reader = nil
34250	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
34251	if err != nil {
34252		return nil, err
34253	}
34254	reqHeaders.Set("Content-Type", "application/json")
34255	c.urlParams_.Set("alt", alt)
34256	c.urlParams_.Set("prettyPrint", "false")
34257	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34258	urls += "?" + c.urlParams_.Encode()
34259	req, err := http.NewRequest("PUT", urls, body)
34260	if err != nil {
34261		return nil, err
34262	}
34263	req.Header = reqHeaders
34264	googleapi.Expand(req.URL, map[string]string{
34265		"profileId": strconv.FormatInt(c.profileId, 10),
34266	})
34267	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34268}
34269
34270// Do executes the "dfareporting.floodlightActivityGroups.update" call.
34271// Exactly one of *FloodlightActivityGroup or error will be non-nil. Any
34272// non-2xx status code is an error. Response headers are in either
34273// *FloodlightActivityGroup.ServerResponse.Header or (if a response was
34274// returned at all) in error.(*googleapi.Error).Header. Use
34275// googleapi.IsNotModified to check whether the returned error was
34276// because http.StatusNotModified was returned.
34277func (c *FloodlightActivityGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
34278	gensupport.SetOptions(c.urlParams_, opts...)
34279	res, err := c.doRequest("json")
34280	if res != nil && res.StatusCode == http.StatusNotModified {
34281		if res.Body != nil {
34282			res.Body.Close()
34283		}
34284		return nil, &googleapi.Error{
34285			Code:   res.StatusCode,
34286			Header: res.Header,
34287		}
34288	}
34289	if err != nil {
34290		return nil, err
34291	}
34292	defer googleapi.CloseBody(res)
34293	if err := googleapi.CheckResponse(res); err != nil {
34294		return nil, err
34295	}
34296	ret := &FloodlightActivityGroup{
34297		ServerResponse: googleapi.ServerResponse{
34298			Header:         res.Header,
34299			HTTPStatusCode: res.StatusCode,
34300		},
34301	}
34302	target := &ret
34303	if err := gensupport.DecodeResponse(target, res); err != nil {
34304		return nil, err
34305	}
34306	return ret, nil
34307	// {
34308	//   "description": "Updates an existing floodlight activity group.",
34309	//   "httpMethod": "PUT",
34310	//   "id": "dfareporting.floodlightActivityGroups.update",
34311	//   "parameterOrder": [
34312	//     "profileId"
34313	//   ],
34314	//   "parameters": {
34315	//     "profileId": {
34316	//       "description": "User profile ID associated with this request.",
34317	//       "format": "int64",
34318	//       "location": "path",
34319	//       "required": true,
34320	//       "type": "string"
34321	//     }
34322	//   },
34323	//   "path": "userprofiles/{profileId}/floodlightActivityGroups",
34324	//   "request": {
34325	//     "$ref": "FloodlightActivityGroup"
34326	//   },
34327	//   "response": {
34328	//     "$ref": "FloodlightActivityGroup"
34329	//   },
34330	//   "scopes": [
34331	//     "https://www.googleapis.com/auth/dfatrafficking"
34332	//   ]
34333	// }
34334
34335}
34336
34337// method id "dfareporting.floodlightConfigurations.get":
34338
34339type FloodlightConfigurationsGetCall struct {
34340	s            *Service
34341	profileId    int64
34342	id           int64
34343	urlParams_   gensupport.URLParams
34344	ifNoneMatch_ string
34345	ctx_         context.Context
34346	header_      http.Header
34347}
34348
34349// Get: Gets one floodlight configuration by ID.
34350func (r *FloodlightConfigurationsService) Get(profileId int64, id int64) *FloodlightConfigurationsGetCall {
34351	c := &FloodlightConfigurationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34352	c.profileId = profileId
34353	c.id = id
34354	return c
34355}
34356
34357// Fields allows partial responses to be retrieved. See
34358// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34359// for more information.
34360func (c *FloodlightConfigurationsGetCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsGetCall {
34361	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34362	return c
34363}
34364
34365// IfNoneMatch sets the optional parameter which makes the operation
34366// fail if the object's ETag matches the given value. This is useful for
34367// getting updates only after the object has changed since the last
34368// request. Use googleapi.IsNotModified to check whether the response
34369// error from Do is the result of In-None-Match.
34370func (c *FloodlightConfigurationsGetCall) IfNoneMatch(entityTag string) *FloodlightConfigurationsGetCall {
34371	c.ifNoneMatch_ = entityTag
34372	return c
34373}
34374
34375// Context sets the context to be used in this call's Do method. Any
34376// pending HTTP request will be aborted if the provided context is
34377// canceled.
34378func (c *FloodlightConfigurationsGetCall) Context(ctx context.Context) *FloodlightConfigurationsGetCall {
34379	c.ctx_ = ctx
34380	return c
34381}
34382
34383// Header returns an http.Header that can be modified by the caller to
34384// add HTTP headers to the request.
34385func (c *FloodlightConfigurationsGetCall) Header() http.Header {
34386	if c.header_ == nil {
34387		c.header_ = make(http.Header)
34388	}
34389	return c.header_
34390}
34391
34392func (c *FloodlightConfigurationsGetCall) doRequest(alt string) (*http.Response, error) {
34393	reqHeaders := make(http.Header)
34394	for k, v := range c.header_ {
34395		reqHeaders[k] = v
34396	}
34397	reqHeaders.Set("User-Agent", c.s.userAgent())
34398	if c.ifNoneMatch_ != "" {
34399		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34400	}
34401	var body io.Reader = nil
34402	c.urlParams_.Set("alt", alt)
34403	c.urlParams_.Set("prettyPrint", "false")
34404	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations/{id}")
34405	urls += "?" + c.urlParams_.Encode()
34406	req, err := http.NewRequest("GET", urls, body)
34407	if err != nil {
34408		return nil, err
34409	}
34410	req.Header = reqHeaders
34411	googleapi.Expand(req.URL, map[string]string{
34412		"profileId": strconv.FormatInt(c.profileId, 10),
34413		"id":        strconv.FormatInt(c.id, 10),
34414	})
34415	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34416}
34417
34418// Do executes the "dfareporting.floodlightConfigurations.get" call.
34419// Exactly one of *FloodlightConfiguration or error will be non-nil. Any
34420// non-2xx status code is an error. Response headers are in either
34421// *FloodlightConfiguration.ServerResponse.Header or (if a response was
34422// returned at all) in error.(*googleapi.Error).Header. Use
34423// googleapi.IsNotModified to check whether the returned error was
34424// because http.StatusNotModified was returned.
34425func (c *FloodlightConfigurationsGetCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
34426	gensupport.SetOptions(c.urlParams_, opts...)
34427	res, err := c.doRequest("json")
34428	if res != nil && res.StatusCode == http.StatusNotModified {
34429		if res.Body != nil {
34430			res.Body.Close()
34431		}
34432		return nil, &googleapi.Error{
34433			Code:   res.StatusCode,
34434			Header: res.Header,
34435		}
34436	}
34437	if err != nil {
34438		return nil, err
34439	}
34440	defer googleapi.CloseBody(res)
34441	if err := googleapi.CheckResponse(res); err != nil {
34442		return nil, err
34443	}
34444	ret := &FloodlightConfiguration{
34445		ServerResponse: googleapi.ServerResponse{
34446			Header:         res.Header,
34447			HTTPStatusCode: res.StatusCode,
34448		},
34449	}
34450	target := &ret
34451	if err := gensupport.DecodeResponse(target, res); err != nil {
34452		return nil, err
34453	}
34454	return ret, nil
34455	// {
34456	//   "description": "Gets one floodlight configuration by ID.",
34457	//   "httpMethod": "GET",
34458	//   "id": "dfareporting.floodlightConfigurations.get",
34459	//   "parameterOrder": [
34460	//     "profileId",
34461	//     "id"
34462	//   ],
34463	//   "parameters": {
34464	//     "id": {
34465	//       "description": "Floodlight configuration ID.",
34466	//       "format": "int64",
34467	//       "location": "path",
34468	//       "required": true,
34469	//       "type": "string"
34470	//     },
34471	//     "profileId": {
34472	//       "description": "User profile ID associated with this request.",
34473	//       "format": "int64",
34474	//       "location": "path",
34475	//       "required": true,
34476	//       "type": "string"
34477	//     }
34478	//   },
34479	//   "path": "userprofiles/{profileId}/floodlightConfigurations/{id}",
34480	//   "response": {
34481	//     "$ref": "FloodlightConfiguration"
34482	//   },
34483	//   "scopes": [
34484	//     "https://www.googleapis.com/auth/dfatrafficking"
34485	//   ]
34486	// }
34487
34488}
34489
34490// method id "dfareporting.floodlightConfigurations.list":
34491
34492type FloodlightConfigurationsListCall struct {
34493	s            *Service
34494	profileId    int64
34495	urlParams_   gensupport.URLParams
34496	ifNoneMatch_ string
34497	ctx_         context.Context
34498	header_      http.Header
34499}
34500
34501// List: Retrieves a list of floodlight configurations, possibly
34502// filtered.
34503func (r *FloodlightConfigurationsService) List(profileId int64) *FloodlightConfigurationsListCall {
34504	c := &FloodlightConfigurationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34505	c.profileId = profileId
34506	return c
34507}
34508
34509// Ids sets the optional parameter "ids": Set of IDs of floodlight
34510// configurations to retrieve. Required field; otherwise an empty list
34511// will be returned.
34512func (c *FloodlightConfigurationsListCall) Ids(ids ...int64) *FloodlightConfigurationsListCall {
34513	var ids_ []string
34514	for _, v := range ids {
34515		ids_ = append(ids_, fmt.Sprint(v))
34516	}
34517	c.urlParams_.SetMulti("ids", ids_)
34518	return c
34519}
34520
34521// Fields allows partial responses to be retrieved. See
34522// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34523// for more information.
34524func (c *FloodlightConfigurationsListCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsListCall {
34525	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34526	return c
34527}
34528
34529// IfNoneMatch sets the optional parameter which makes the operation
34530// fail if the object's ETag matches the given value. This is useful for
34531// getting updates only after the object has changed since the last
34532// request. Use googleapi.IsNotModified to check whether the response
34533// error from Do is the result of In-None-Match.
34534func (c *FloodlightConfigurationsListCall) IfNoneMatch(entityTag string) *FloodlightConfigurationsListCall {
34535	c.ifNoneMatch_ = entityTag
34536	return c
34537}
34538
34539// Context sets the context to be used in this call's Do method. Any
34540// pending HTTP request will be aborted if the provided context is
34541// canceled.
34542func (c *FloodlightConfigurationsListCall) Context(ctx context.Context) *FloodlightConfigurationsListCall {
34543	c.ctx_ = ctx
34544	return c
34545}
34546
34547// Header returns an http.Header that can be modified by the caller to
34548// add HTTP headers to the request.
34549func (c *FloodlightConfigurationsListCall) Header() http.Header {
34550	if c.header_ == nil {
34551		c.header_ = make(http.Header)
34552	}
34553	return c.header_
34554}
34555
34556func (c *FloodlightConfigurationsListCall) doRequest(alt string) (*http.Response, error) {
34557	reqHeaders := make(http.Header)
34558	for k, v := range c.header_ {
34559		reqHeaders[k] = v
34560	}
34561	reqHeaders.Set("User-Agent", c.s.userAgent())
34562	if c.ifNoneMatch_ != "" {
34563		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34564	}
34565	var body io.Reader = nil
34566	c.urlParams_.Set("alt", alt)
34567	c.urlParams_.Set("prettyPrint", "false")
34568	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
34569	urls += "?" + c.urlParams_.Encode()
34570	req, err := http.NewRequest("GET", urls, body)
34571	if err != nil {
34572		return nil, err
34573	}
34574	req.Header = reqHeaders
34575	googleapi.Expand(req.URL, map[string]string{
34576		"profileId": strconv.FormatInt(c.profileId, 10),
34577	})
34578	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34579}
34580
34581// Do executes the "dfareporting.floodlightConfigurations.list" call.
34582// Exactly one of *FloodlightConfigurationsListResponse or error will be
34583// non-nil. Any non-2xx status code is an error. Response headers are in
34584// either *FloodlightConfigurationsListResponse.ServerResponse.Header or
34585// (if a response was returned at all) in
34586// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
34587// whether the returned error was because http.StatusNotModified was
34588// returned.
34589func (c *FloodlightConfigurationsListCall) Do(opts ...googleapi.CallOption) (*FloodlightConfigurationsListResponse, error) {
34590	gensupport.SetOptions(c.urlParams_, opts...)
34591	res, err := c.doRequest("json")
34592	if res != nil && res.StatusCode == http.StatusNotModified {
34593		if res.Body != nil {
34594			res.Body.Close()
34595		}
34596		return nil, &googleapi.Error{
34597			Code:   res.StatusCode,
34598			Header: res.Header,
34599		}
34600	}
34601	if err != nil {
34602		return nil, err
34603	}
34604	defer googleapi.CloseBody(res)
34605	if err := googleapi.CheckResponse(res); err != nil {
34606		return nil, err
34607	}
34608	ret := &FloodlightConfigurationsListResponse{
34609		ServerResponse: googleapi.ServerResponse{
34610			Header:         res.Header,
34611			HTTPStatusCode: res.StatusCode,
34612		},
34613	}
34614	target := &ret
34615	if err := gensupport.DecodeResponse(target, res); err != nil {
34616		return nil, err
34617	}
34618	return ret, nil
34619	// {
34620	//   "description": "Retrieves a list of floodlight configurations, possibly filtered.",
34621	//   "httpMethod": "GET",
34622	//   "id": "dfareporting.floodlightConfigurations.list",
34623	//   "parameterOrder": [
34624	//     "profileId"
34625	//   ],
34626	//   "parameters": {
34627	//     "ids": {
34628	//       "description": "Set of IDs of floodlight configurations to retrieve. Required field; otherwise an empty list will be returned.",
34629	//       "format": "int64",
34630	//       "location": "query",
34631	//       "repeated": true,
34632	//       "type": "string"
34633	//     },
34634	//     "profileId": {
34635	//       "description": "User profile ID associated with this request.",
34636	//       "format": "int64",
34637	//       "location": "path",
34638	//       "required": true,
34639	//       "type": "string"
34640	//     }
34641	//   },
34642	//   "path": "userprofiles/{profileId}/floodlightConfigurations",
34643	//   "response": {
34644	//     "$ref": "FloodlightConfigurationsListResponse"
34645	//   },
34646	//   "scopes": [
34647	//     "https://www.googleapis.com/auth/dfatrafficking"
34648	//   ]
34649	// }
34650
34651}
34652
34653// method id "dfareporting.floodlightConfigurations.patch":
34654
34655type FloodlightConfigurationsPatchCall struct {
34656	s                       *Service
34657	profileId               int64
34658	floodlightconfiguration *FloodlightConfiguration
34659	urlParams_              gensupport.URLParams
34660	ctx_                    context.Context
34661	header_                 http.Header
34662}
34663
34664// Patch: Updates an existing floodlight configuration. This method
34665// supports patch semantics.
34666func (r *FloodlightConfigurationsService) Patch(profileId int64, id int64, floodlightconfiguration *FloodlightConfiguration) *FloodlightConfigurationsPatchCall {
34667	c := &FloodlightConfigurationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34668	c.profileId = profileId
34669	c.urlParams_.Set("id", fmt.Sprint(id))
34670	c.floodlightconfiguration = floodlightconfiguration
34671	return c
34672}
34673
34674// Fields allows partial responses to be retrieved. See
34675// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34676// for more information.
34677func (c *FloodlightConfigurationsPatchCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsPatchCall {
34678	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34679	return c
34680}
34681
34682// Context sets the context to be used in this call's Do method. Any
34683// pending HTTP request will be aborted if the provided context is
34684// canceled.
34685func (c *FloodlightConfigurationsPatchCall) Context(ctx context.Context) *FloodlightConfigurationsPatchCall {
34686	c.ctx_ = ctx
34687	return c
34688}
34689
34690// Header returns an http.Header that can be modified by the caller to
34691// add HTTP headers to the request.
34692func (c *FloodlightConfigurationsPatchCall) Header() http.Header {
34693	if c.header_ == nil {
34694		c.header_ = make(http.Header)
34695	}
34696	return c.header_
34697}
34698
34699func (c *FloodlightConfigurationsPatchCall) doRequest(alt string) (*http.Response, error) {
34700	reqHeaders := make(http.Header)
34701	for k, v := range c.header_ {
34702		reqHeaders[k] = v
34703	}
34704	reqHeaders.Set("User-Agent", c.s.userAgent())
34705	var body io.Reader = nil
34706	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightconfiguration)
34707	if err != nil {
34708		return nil, err
34709	}
34710	reqHeaders.Set("Content-Type", "application/json")
34711	c.urlParams_.Set("alt", alt)
34712	c.urlParams_.Set("prettyPrint", "false")
34713	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
34714	urls += "?" + c.urlParams_.Encode()
34715	req, err := http.NewRequest("PATCH", urls, body)
34716	if err != nil {
34717		return nil, err
34718	}
34719	req.Header = reqHeaders
34720	googleapi.Expand(req.URL, map[string]string{
34721		"profileId": strconv.FormatInt(c.profileId, 10),
34722	})
34723	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34724}
34725
34726// Do executes the "dfareporting.floodlightConfigurations.patch" call.
34727// Exactly one of *FloodlightConfiguration or error will be non-nil. Any
34728// non-2xx status code is an error. Response headers are in either
34729// *FloodlightConfiguration.ServerResponse.Header or (if a response was
34730// returned at all) in error.(*googleapi.Error).Header. Use
34731// googleapi.IsNotModified to check whether the returned error was
34732// because http.StatusNotModified was returned.
34733func (c *FloodlightConfigurationsPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
34734	gensupport.SetOptions(c.urlParams_, opts...)
34735	res, err := c.doRequest("json")
34736	if res != nil && res.StatusCode == http.StatusNotModified {
34737		if res.Body != nil {
34738			res.Body.Close()
34739		}
34740		return nil, &googleapi.Error{
34741			Code:   res.StatusCode,
34742			Header: res.Header,
34743		}
34744	}
34745	if err != nil {
34746		return nil, err
34747	}
34748	defer googleapi.CloseBody(res)
34749	if err := googleapi.CheckResponse(res); err != nil {
34750		return nil, err
34751	}
34752	ret := &FloodlightConfiguration{
34753		ServerResponse: googleapi.ServerResponse{
34754			Header:         res.Header,
34755			HTTPStatusCode: res.StatusCode,
34756		},
34757	}
34758	target := &ret
34759	if err := gensupport.DecodeResponse(target, res); err != nil {
34760		return nil, err
34761	}
34762	return ret, nil
34763	// {
34764	//   "description": "Updates an existing floodlight configuration. This method supports patch semantics.",
34765	//   "httpMethod": "PATCH",
34766	//   "id": "dfareporting.floodlightConfigurations.patch",
34767	//   "parameterOrder": [
34768	//     "profileId",
34769	//     "id"
34770	//   ],
34771	//   "parameters": {
34772	//     "id": {
34773	//       "description": "Floodlight configuration ID.",
34774	//       "format": "int64",
34775	//       "location": "query",
34776	//       "required": true,
34777	//       "type": "string"
34778	//     },
34779	//     "profileId": {
34780	//       "description": "User profile ID associated with this request.",
34781	//       "format": "int64",
34782	//       "location": "path",
34783	//       "required": true,
34784	//       "type": "string"
34785	//     }
34786	//   },
34787	//   "path": "userprofiles/{profileId}/floodlightConfigurations",
34788	//   "request": {
34789	//     "$ref": "FloodlightConfiguration"
34790	//   },
34791	//   "response": {
34792	//     "$ref": "FloodlightConfiguration"
34793	//   },
34794	//   "scopes": [
34795	//     "https://www.googleapis.com/auth/dfatrafficking"
34796	//   ]
34797	// }
34798
34799}
34800
34801// method id "dfareporting.floodlightConfigurations.update":
34802
34803type FloodlightConfigurationsUpdateCall struct {
34804	s                       *Service
34805	profileId               int64
34806	floodlightconfiguration *FloodlightConfiguration
34807	urlParams_              gensupport.URLParams
34808	ctx_                    context.Context
34809	header_                 http.Header
34810}
34811
34812// Update: Updates an existing floodlight configuration.
34813func (r *FloodlightConfigurationsService) Update(profileId int64, floodlightconfiguration *FloodlightConfiguration) *FloodlightConfigurationsUpdateCall {
34814	c := &FloodlightConfigurationsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34815	c.profileId = profileId
34816	c.floodlightconfiguration = floodlightconfiguration
34817	return c
34818}
34819
34820// Fields allows partial responses to be retrieved. See
34821// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34822// for more information.
34823func (c *FloodlightConfigurationsUpdateCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsUpdateCall {
34824	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34825	return c
34826}
34827
34828// Context sets the context to be used in this call's Do method. Any
34829// pending HTTP request will be aborted if the provided context is
34830// canceled.
34831func (c *FloodlightConfigurationsUpdateCall) Context(ctx context.Context) *FloodlightConfigurationsUpdateCall {
34832	c.ctx_ = ctx
34833	return c
34834}
34835
34836// Header returns an http.Header that can be modified by the caller to
34837// add HTTP headers to the request.
34838func (c *FloodlightConfigurationsUpdateCall) Header() http.Header {
34839	if c.header_ == nil {
34840		c.header_ = make(http.Header)
34841	}
34842	return c.header_
34843}
34844
34845func (c *FloodlightConfigurationsUpdateCall) doRequest(alt string) (*http.Response, error) {
34846	reqHeaders := make(http.Header)
34847	for k, v := range c.header_ {
34848		reqHeaders[k] = v
34849	}
34850	reqHeaders.Set("User-Agent", c.s.userAgent())
34851	var body io.Reader = nil
34852	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightconfiguration)
34853	if err != nil {
34854		return nil, err
34855	}
34856	reqHeaders.Set("Content-Type", "application/json")
34857	c.urlParams_.Set("alt", alt)
34858	c.urlParams_.Set("prettyPrint", "false")
34859	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
34860	urls += "?" + c.urlParams_.Encode()
34861	req, err := http.NewRequest("PUT", urls, body)
34862	if err != nil {
34863		return nil, err
34864	}
34865	req.Header = reqHeaders
34866	googleapi.Expand(req.URL, map[string]string{
34867		"profileId": strconv.FormatInt(c.profileId, 10),
34868	})
34869	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34870}
34871
34872// Do executes the "dfareporting.floodlightConfigurations.update" call.
34873// Exactly one of *FloodlightConfiguration or error will be non-nil. Any
34874// non-2xx status code is an error. Response headers are in either
34875// *FloodlightConfiguration.ServerResponse.Header or (if a response was
34876// returned at all) in error.(*googleapi.Error).Header. Use
34877// googleapi.IsNotModified to check whether the returned error was
34878// because http.StatusNotModified was returned.
34879func (c *FloodlightConfigurationsUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
34880	gensupport.SetOptions(c.urlParams_, opts...)
34881	res, err := c.doRequest("json")
34882	if res != nil && res.StatusCode == http.StatusNotModified {
34883		if res.Body != nil {
34884			res.Body.Close()
34885		}
34886		return nil, &googleapi.Error{
34887			Code:   res.StatusCode,
34888			Header: res.Header,
34889		}
34890	}
34891	if err != nil {
34892		return nil, err
34893	}
34894	defer googleapi.CloseBody(res)
34895	if err := googleapi.CheckResponse(res); err != nil {
34896		return nil, err
34897	}
34898	ret := &FloodlightConfiguration{
34899		ServerResponse: googleapi.ServerResponse{
34900			Header:         res.Header,
34901			HTTPStatusCode: res.StatusCode,
34902		},
34903	}
34904	target := &ret
34905	if err := gensupport.DecodeResponse(target, res); err != nil {
34906		return nil, err
34907	}
34908	return ret, nil
34909	// {
34910	//   "description": "Updates an existing floodlight configuration.",
34911	//   "httpMethod": "PUT",
34912	//   "id": "dfareporting.floodlightConfigurations.update",
34913	//   "parameterOrder": [
34914	//     "profileId"
34915	//   ],
34916	//   "parameters": {
34917	//     "profileId": {
34918	//       "description": "User profile ID associated with this request.",
34919	//       "format": "int64",
34920	//       "location": "path",
34921	//       "required": true,
34922	//       "type": "string"
34923	//     }
34924	//   },
34925	//   "path": "userprofiles/{profileId}/floodlightConfigurations",
34926	//   "request": {
34927	//     "$ref": "FloodlightConfiguration"
34928	//   },
34929	//   "response": {
34930	//     "$ref": "FloodlightConfiguration"
34931	//   },
34932	//   "scopes": [
34933	//     "https://www.googleapis.com/auth/dfatrafficking"
34934	//   ]
34935	// }
34936
34937}
34938
34939// method id "dfareporting.inventoryItems.get":
34940
34941type InventoryItemsGetCall struct {
34942	s            *Service
34943	profileId    int64
34944	projectId    int64
34945	id           int64
34946	urlParams_   gensupport.URLParams
34947	ifNoneMatch_ string
34948	ctx_         context.Context
34949	header_      http.Header
34950}
34951
34952// Get: Gets one inventory item by ID.
34953func (r *InventoryItemsService) Get(profileId int64, projectId int64, id int64) *InventoryItemsGetCall {
34954	c := &InventoryItemsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34955	c.profileId = profileId
34956	c.projectId = projectId
34957	c.id = id
34958	return c
34959}
34960
34961// Fields allows partial responses to be retrieved. See
34962// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34963// for more information.
34964func (c *InventoryItemsGetCall) Fields(s ...googleapi.Field) *InventoryItemsGetCall {
34965	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34966	return c
34967}
34968
34969// IfNoneMatch sets the optional parameter which makes the operation
34970// fail if the object's ETag matches the given value. This is useful for
34971// getting updates only after the object has changed since the last
34972// request. Use googleapi.IsNotModified to check whether the response
34973// error from Do is the result of In-None-Match.
34974func (c *InventoryItemsGetCall) IfNoneMatch(entityTag string) *InventoryItemsGetCall {
34975	c.ifNoneMatch_ = entityTag
34976	return c
34977}
34978
34979// Context sets the context to be used in this call's Do method. Any
34980// pending HTTP request will be aborted if the provided context is
34981// canceled.
34982func (c *InventoryItemsGetCall) Context(ctx context.Context) *InventoryItemsGetCall {
34983	c.ctx_ = ctx
34984	return c
34985}
34986
34987// Header returns an http.Header that can be modified by the caller to
34988// add HTTP headers to the request.
34989func (c *InventoryItemsGetCall) Header() http.Header {
34990	if c.header_ == nil {
34991		c.header_ = make(http.Header)
34992	}
34993	return c.header_
34994}
34995
34996func (c *InventoryItemsGetCall) doRequest(alt string) (*http.Response, error) {
34997	reqHeaders := make(http.Header)
34998	for k, v := range c.header_ {
34999		reqHeaders[k] = v
35000	}
35001	reqHeaders.Set("User-Agent", c.s.userAgent())
35002	if c.ifNoneMatch_ != "" {
35003		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35004	}
35005	var body io.Reader = nil
35006	c.urlParams_.Set("alt", alt)
35007	c.urlParams_.Set("prettyPrint", "false")
35008	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/inventoryItems/{id}")
35009	urls += "?" + c.urlParams_.Encode()
35010	req, err := http.NewRequest("GET", urls, body)
35011	if err != nil {
35012		return nil, err
35013	}
35014	req.Header = reqHeaders
35015	googleapi.Expand(req.URL, map[string]string{
35016		"profileId": strconv.FormatInt(c.profileId, 10),
35017		"projectId": strconv.FormatInt(c.projectId, 10),
35018		"id":        strconv.FormatInt(c.id, 10),
35019	})
35020	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35021}
35022
35023// Do executes the "dfareporting.inventoryItems.get" call.
35024// Exactly one of *InventoryItem or error will be non-nil. Any non-2xx
35025// status code is an error. Response headers are in either
35026// *InventoryItem.ServerResponse.Header or (if a response was returned
35027// at all) in error.(*googleapi.Error).Header. Use
35028// googleapi.IsNotModified to check whether the returned error was
35029// because http.StatusNotModified was returned.
35030func (c *InventoryItemsGetCall) Do(opts ...googleapi.CallOption) (*InventoryItem, error) {
35031	gensupport.SetOptions(c.urlParams_, opts...)
35032	res, err := c.doRequest("json")
35033	if res != nil && res.StatusCode == http.StatusNotModified {
35034		if res.Body != nil {
35035			res.Body.Close()
35036		}
35037		return nil, &googleapi.Error{
35038			Code:   res.StatusCode,
35039			Header: res.Header,
35040		}
35041	}
35042	if err != nil {
35043		return nil, err
35044	}
35045	defer googleapi.CloseBody(res)
35046	if err := googleapi.CheckResponse(res); err != nil {
35047		return nil, err
35048	}
35049	ret := &InventoryItem{
35050		ServerResponse: googleapi.ServerResponse{
35051			Header:         res.Header,
35052			HTTPStatusCode: res.StatusCode,
35053		},
35054	}
35055	target := &ret
35056	if err := gensupport.DecodeResponse(target, res); err != nil {
35057		return nil, err
35058	}
35059	return ret, nil
35060	// {
35061	//   "description": "Gets one inventory item by ID.",
35062	//   "httpMethod": "GET",
35063	//   "id": "dfareporting.inventoryItems.get",
35064	//   "parameterOrder": [
35065	//     "profileId",
35066	//     "projectId",
35067	//     "id"
35068	//   ],
35069	//   "parameters": {
35070	//     "id": {
35071	//       "description": "Inventory item ID.",
35072	//       "format": "int64",
35073	//       "location": "path",
35074	//       "required": true,
35075	//       "type": "string"
35076	//     },
35077	//     "profileId": {
35078	//       "description": "User profile ID associated with this request.",
35079	//       "format": "int64",
35080	//       "location": "path",
35081	//       "required": true,
35082	//       "type": "string"
35083	//     },
35084	//     "projectId": {
35085	//       "description": "Project ID for order documents.",
35086	//       "format": "int64",
35087	//       "location": "path",
35088	//       "required": true,
35089	//       "type": "string"
35090	//     }
35091	//   },
35092	//   "path": "userprofiles/{profileId}/projects/{projectId}/inventoryItems/{id}",
35093	//   "response": {
35094	//     "$ref": "InventoryItem"
35095	//   },
35096	//   "scopes": [
35097	//     "https://www.googleapis.com/auth/dfatrafficking"
35098	//   ]
35099	// }
35100
35101}
35102
35103// method id "dfareporting.inventoryItems.list":
35104
35105type InventoryItemsListCall struct {
35106	s            *Service
35107	profileId    int64
35108	projectId    int64
35109	urlParams_   gensupport.URLParams
35110	ifNoneMatch_ string
35111	ctx_         context.Context
35112	header_      http.Header
35113}
35114
35115// List: Retrieves a list of inventory items, possibly filtered. This
35116// method supports paging.
35117func (r *InventoryItemsService) List(profileId int64, projectId int64) *InventoryItemsListCall {
35118	c := &InventoryItemsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35119	c.profileId = profileId
35120	c.projectId = projectId
35121	return c
35122}
35123
35124// Ids sets the optional parameter "ids": Select only inventory items
35125// with these IDs.
35126func (c *InventoryItemsListCall) Ids(ids ...int64) *InventoryItemsListCall {
35127	var ids_ []string
35128	for _, v := range ids {
35129		ids_ = append(ids_, fmt.Sprint(v))
35130	}
35131	c.urlParams_.SetMulti("ids", ids_)
35132	return c
35133}
35134
35135// InPlan sets the optional parameter "inPlan": Select only inventory
35136// items that are in plan.
35137func (c *InventoryItemsListCall) InPlan(inPlan bool) *InventoryItemsListCall {
35138	c.urlParams_.Set("inPlan", fmt.Sprint(inPlan))
35139	return c
35140}
35141
35142// MaxResults sets the optional parameter "maxResults": Maximum number
35143// of results to return.
35144func (c *InventoryItemsListCall) MaxResults(maxResults int64) *InventoryItemsListCall {
35145	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
35146	return c
35147}
35148
35149// OrderId sets the optional parameter "orderId": Select only inventory
35150// items that belong to specified orders.
35151func (c *InventoryItemsListCall) OrderId(orderId ...int64) *InventoryItemsListCall {
35152	var orderId_ []string
35153	for _, v := range orderId {
35154		orderId_ = append(orderId_, fmt.Sprint(v))
35155	}
35156	c.urlParams_.SetMulti("orderId", orderId_)
35157	return c
35158}
35159
35160// PageToken sets the optional parameter "pageToken": Value of the
35161// nextPageToken from the previous result page.
35162func (c *InventoryItemsListCall) PageToken(pageToken string) *InventoryItemsListCall {
35163	c.urlParams_.Set("pageToken", pageToken)
35164	return c
35165}
35166
35167// SiteId sets the optional parameter "siteId": Select only inventory
35168// items that are associated with these sites.
35169func (c *InventoryItemsListCall) SiteId(siteId ...int64) *InventoryItemsListCall {
35170	var siteId_ []string
35171	for _, v := range siteId {
35172		siteId_ = append(siteId_, fmt.Sprint(v))
35173	}
35174	c.urlParams_.SetMulti("siteId", siteId_)
35175	return c
35176}
35177
35178// SortField sets the optional parameter "sortField": Field by which to
35179// sort the list.
35180//
35181// Possible values:
35182//   "ID" (default)
35183//   "NAME"
35184func (c *InventoryItemsListCall) SortField(sortField string) *InventoryItemsListCall {
35185	c.urlParams_.Set("sortField", sortField)
35186	return c
35187}
35188
35189// SortOrder sets the optional parameter "sortOrder": Order of sorted
35190// results.
35191//
35192// Possible values:
35193//   "ASCENDING" (default)
35194//   "DESCENDING"
35195func (c *InventoryItemsListCall) SortOrder(sortOrder string) *InventoryItemsListCall {
35196	c.urlParams_.Set("sortOrder", sortOrder)
35197	return c
35198}
35199
35200// Type sets the optional parameter "type": Select only inventory items
35201// with this type.
35202//
35203// Possible values:
35204//   "PLANNING_PLACEMENT_TYPE_CREDIT"
35205//   "PLANNING_PLACEMENT_TYPE_REGULAR"
35206func (c *InventoryItemsListCall) Type(type_ string) *InventoryItemsListCall {
35207	c.urlParams_.Set("type", type_)
35208	return c
35209}
35210
35211// Fields allows partial responses to be retrieved. See
35212// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35213// for more information.
35214func (c *InventoryItemsListCall) Fields(s ...googleapi.Field) *InventoryItemsListCall {
35215	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35216	return c
35217}
35218
35219// IfNoneMatch sets the optional parameter which makes the operation
35220// fail if the object's ETag matches the given value. This is useful for
35221// getting updates only after the object has changed since the last
35222// request. Use googleapi.IsNotModified to check whether the response
35223// error from Do is the result of In-None-Match.
35224func (c *InventoryItemsListCall) IfNoneMatch(entityTag string) *InventoryItemsListCall {
35225	c.ifNoneMatch_ = entityTag
35226	return c
35227}
35228
35229// Context sets the context to be used in this call's Do method. Any
35230// pending HTTP request will be aborted if the provided context is
35231// canceled.
35232func (c *InventoryItemsListCall) Context(ctx context.Context) *InventoryItemsListCall {
35233	c.ctx_ = ctx
35234	return c
35235}
35236
35237// Header returns an http.Header that can be modified by the caller to
35238// add HTTP headers to the request.
35239func (c *InventoryItemsListCall) Header() http.Header {
35240	if c.header_ == nil {
35241		c.header_ = make(http.Header)
35242	}
35243	return c.header_
35244}
35245
35246func (c *InventoryItemsListCall) doRequest(alt string) (*http.Response, error) {
35247	reqHeaders := make(http.Header)
35248	for k, v := range c.header_ {
35249		reqHeaders[k] = v
35250	}
35251	reqHeaders.Set("User-Agent", c.s.userAgent())
35252	if c.ifNoneMatch_ != "" {
35253		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35254	}
35255	var body io.Reader = nil
35256	c.urlParams_.Set("alt", alt)
35257	c.urlParams_.Set("prettyPrint", "false")
35258	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/inventoryItems")
35259	urls += "?" + c.urlParams_.Encode()
35260	req, err := http.NewRequest("GET", urls, body)
35261	if err != nil {
35262		return nil, err
35263	}
35264	req.Header = reqHeaders
35265	googleapi.Expand(req.URL, map[string]string{
35266		"profileId": strconv.FormatInt(c.profileId, 10),
35267		"projectId": strconv.FormatInt(c.projectId, 10),
35268	})
35269	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35270}
35271
35272// Do executes the "dfareporting.inventoryItems.list" call.
35273// Exactly one of *InventoryItemsListResponse or error will be non-nil.
35274// Any non-2xx status code is an error. Response headers are in either
35275// *InventoryItemsListResponse.ServerResponse.Header or (if a response
35276// was 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 *InventoryItemsListCall) Do(opts ...googleapi.CallOption) (*InventoryItemsListResponse, error) {
35280	gensupport.SetOptions(c.urlParams_, opts...)
35281	res, err := c.doRequest("json")
35282	if res != nil && res.StatusCode == http.StatusNotModified {
35283		if res.Body != nil {
35284			res.Body.Close()
35285		}
35286		return nil, &googleapi.Error{
35287			Code:   res.StatusCode,
35288			Header: res.Header,
35289		}
35290	}
35291	if err != nil {
35292		return nil, err
35293	}
35294	defer googleapi.CloseBody(res)
35295	if err := googleapi.CheckResponse(res); err != nil {
35296		return nil, err
35297	}
35298	ret := &InventoryItemsListResponse{
35299		ServerResponse: googleapi.ServerResponse{
35300			Header:         res.Header,
35301			HTTPStatusCode: res.StatusCode,
35302		},
35303	}
35304	target := &ret
35305	if err := gensupport.DecodeResponse(target, res); err != nil {
35306		return nil, err
35307	}
35308	return ret, nil
35309	// {
35310	//   "description": "Retrieves a list of inventory items, possibly filtered. This method supports paging.",
35311	//   "httpMethod": "GET",
35312	//   "id": "dfareporting.inventoryItems.list",
35313	//   "parameterOrder": [
35314	//     "profileId",
35315	//     "projectId"
35316	//   ],
35317	//   "parameters": {
35318	//     "ids": {
35319	//       "description": "Select only inventory items with these IDs.",
35320	//       "format": "int64",
35321	//       "location": "query",
35322	//       "repeated": true,
35323	//       "type": "string"
35324	//     },
35325	//     "inPlan": {
35326	//       "description": "Select only inventory items that are in plan.",
35327	//       "location": "query",
35328	//       "type": "boolean"
35329	//     },
35330	//     "maxResults": {
35331	//       "default": "1000",
35332	//       "description": "Maximum number of results to return.",
35333	//       "format": "int32",
35334	//       "location": "query",
35335	//       "maximum": "1000",
35336	//       "minimum": "0",
35337	//       "type": "integer"
35338	//     },
35339	//     "orderId": {
35340	//       "description": "Select only inventory items that belong to specified orders.",
35341	//       "format": "int64",
35342	//       "location": "query",
35343	//       "repeated": true,
35344	//       "type": "string"
35345	//     },
35346	//     "pageToken": {
35347	//       "description": "Value of the nextPageToken from the previous result page.",
35348	//       "location": "query",
35349	//       "type": "string"
35350	//     },
35351	//     "profileId": {
35352	//       "description": "User profile ID associated with this request.",
35353	//       "format": "int64",
35354	//       "location": "path",
35355	//       "required": true,
35356	//       "type": "string"
35357	//     },
35358	//     "projectId": {
35359	//       "description": "Project ID for order documents.",
35360	//       "format": "int64",
35361	//       "location": "path",
35362	//       "required": true,
35363	//       "type": "string"
35364	//     },
35365	//     "siteId": {
35366	//       "description": "Select only inventory items that are associated with these sites.",
35367	//       "format": "int64",
35368	//       "location": "query",
35369	//       "repeated": true,
35370	//       "type": "string"
35371	//     },
35372	//     "sortField": {
35373	//       "default": "ID",
35374	//       "description": "Field by which to sort the list.",
35375	//       "enum": [
35376	//         "ID",
35377	//         "NAME"
35378	//       ],
35379	//       "enumDescriptions": [
35380	//         "",
35381	//         ""
35382	//       ],
35383	//       "location": "query",
35384	//       "type": "string"
35385	//     },
35386	//     "sortOrder": {
35387	//       "default": "ASCENDING",
35388	//       "description": "Order of sorted results.",
35389	//       "enum": [
35390	//         "ASCENDING",
35391	//         "DESCENDING"
35392	//       ],
35393	//       "enumDescriptions": [
35394	//         "",
35395	//         ""
35396	//       ],
35397	//       "location": "query",
35398	//       "type": "string"
35399	//     },
35400	//     "type": {
35401	//       "description": "Select only inventory items with this type.",
35402	//       "enum": [
35403	//         "PLANNING_PLACEMENT_TYPE_CREDIT",
35404	//         "PLANNING_PLACEMENT_TYPE_REGULAR"
35405	//       ],
35406	//       "enumDescriptions": [
35407	//         "",
35408	//         ""
35409	//       ],
35410	//       "location": "query",
35411	//       "type": "string"
35412	//     }
35413	//   },
35414	//   "path": "userprofiles/{profileId}/projects/{projectId}/inventoryItems",
35415	//   "response": {
35416	//     "$ref": "InventoryItemsListResponse"
35417	//   },
35418	//   "scopes": [
35419	//     "https://www.googleapis.com/auth/dfatrafficking"
35420	//   ]
35421	// }
35422
35423}
35424
35425// Pages invokes f for each page of results.
35426// A non-nil error returned from f will halt the iteration.
35427// The provided context supersedes any context provided to the Context method.
35428func (c *InventoryItemsListCall) Pages(ctx context.Context, f func(*InventoryItemsListResponse) error) error {
35429	c.ctx_ = ctx
35430	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
35431	for {
35432		x, err := c.Do()
35433		if err != nil {
35434			return err
35435		}
35436		if err := f(x); err != nil {
35437			return err
35438		}
35439		if x.NextPageToken == "" {
35440			return nil
35441		}
35442		c.PageToken(x.NextPageToken)
35443	}
35444}
35445
35446// method id "dfareporting.languages.list":
35447
35448type LanguagesListCall struct {
35449	s            *Service
35450	profileId    int64
35451	urlParams_   gensupport.URLParams
35452	ifNoneMatch_ string
35453	ctx_         context.Context
35454	header_      http.Header
35455}
35456
35457// List: Retrieves a list of languages.
35458func (r *LanguagesService) List(profileId int64) *LanguagesListCall {
35459	c := &LanguagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35460	c.profileId = profileId
35461	return c
35462}
35463
35464// Fields allows partial responses to be retrieved. See
35465// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35466// for more information.
35467func (c *LanguagesListCall) Fields(s ...googleapi.Field) *LanguagesListCall {
35468	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35469	return c
35470}
35471
35472// IfNoneMatch sets the optional parameter which makes the operation
35473// fail if the object's ETag matches the given value. This is useful for
35474// getting updates only after the object has changed since the last
35475// request. Use googleapi.IsNotModified to check whether the response
35476// error from Do is the result of In-None-Match.
35477func (c *LanguagesListCall) IfNoneMatch(entityTag string) *LanguagesListCall {
35478	c.ifNoneMatch_ = entityTag
35479	return c
35480}
35481
35482// Context sets the context to be used in this call's Do method. Any
35483// pending HTTP request will be aborted if the provided context is
35484// canceled.
35485func (c *LanguagesListCall) Context(ctx context.Context) *LanguagesListCall {
35486	c.ctx_ = ctx
35487	return c
35488}
35489
35490// Header returns an http.Header that can be modified by the caller to
35491// add HTTP headers to the request.
35492func (c *LanguagesListCall) Header() http.Header {
35493	if c.header_ == nil {
35494		c.header_ = make(http.Header)
35495	}
35496	return c.header_
35497}
35498
35499func (c *LanguagesListCall) doRequest(alt string) (*http.Response, error) {
35500	reqHeaders := make(http.Header)
35501	for k, v := range c.header_ {
35502		reqHeaders[k] = v
35503	}
35504	reqHeaders.Set("User-Agent", c.s.userAgent())
35505	if c.ifNoneMatch_ != "" {
35506		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35507	}
35508	var body io.Reader = nil
35509	c.urlParams_.Set("alt", alt)
35510	c.urlParams_.Set("prettyPrint", "false")
35511	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/languages")
35512	urls += "?" + c.urlParams_.Encode()
35513	req, err := http.NewRequest("GET", urls, body)
35514	if err != nil {
35515		return nil, err
35516	}
35517	req.Header = reqHeaders
35518	googleapi.Expand(req.URL, map[string]string{
35519		"profileId": strconv.FormatInt(c.profileId, 10),
35520	})
35521	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35522}
35523
35524// Do executes the "dfareporting.languages.list" call.
35525// Exactly one of *LanguagesListResponse or error will be non-nil. Any
35526// non-2xx status code is an error. Response headers are in either
35527// *LanguagesListResponse.ServerResponse.Header or (if a response was
35528// returned at all) in error.(*googleapi.Error).Header. Use
35529// googleapi.IsNotModified to check whether the returned error was
35530// because http.StatusNotModified was returned.
35531func (c *LanguagesListCall) Do(opts ...googleapi.CallOption) (*LanguagesListResponse, error) {
35532	gensupport.SetOptions(c.urlParams_, opts...)
35533	res, err := c.doRequest("json")
35534	if res != nil && res.StatusCode == http.StatusNotModified {
35535		if res.Body != nil {
35536			res.Body.Close()
35537		}
35538		return nil, &googleapi.Error{
35539			Code:   res.StatusCode,
35540			Header: res.Header,
35541		}
35542	}
35543	if err != nil {
35544		return nil, err
35545	}
35546	defer googleapi.CloseBody(res)
35547	if err := googleapi.CheckResponse(res); err != nil {
35548		return nil, err
35549	}
35550	ret := &LanguagesListResponse{
35551		ServerResponse: googleapi.ServerResponse{
35552			Header:         res.Header,
35553			HTTPStatusCode: res.StatusCode,
35554		},
35555	}
35556	target := &ret
35557	if err := gensupport.DecodeResponse(target, res); err != nil {
35558		return nil, err
35559	}
35560	return ret, nil
35561	// {
35562	//   "description": "Retrieves a list of languages.",
35563	//   "httpMethod": "GET",
35564	//   "id": "dfareporting.languages.list",
35565	//   "parameterOrder": [
35566	//     "profileId"
35567	//   ],
35568	//   "parameters": {
35569	//     "profileId": {
35570	//       "description": "User profile ID associated with this request.",
35571	//       "format": "int64",
35572	//       "location": "path",
35573	//       "required": true,
35574	//       "type": "string"
35575	//     }
35576	//   },
35577	//   "path": "userprofiles/{profileId}/languages",
35578	//   "response": {
35579	//     "$ref": "LanguagesListResponse"
35580	//   },
35581	//   "scopes": [
35582	//     "https://www.googleapis.com/auth/dfatrafficking"
35583	//   ]
35584	// }
35585
35586}
35587
35588// method id "dfareporting.metros.list":
35589
35590type MetrosListCall struct {
35591	s            *Service
35592	profileId    int64
35593	urlParams_   gensupport.URLParams
35594	ifNoneMatch_ string
35595	ctx_         context.Context
35596	header_      http.Header
35597}
35598
35599// List: Retrieves a list of metros.
35600func (r *MetrosService) List(profileId int64) *MetrosListCall {
35601	c := &MetrosListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35602	c.profileId = profileId
35603	return c
35604}
35605
35606// Fields allows partial responses to be retrieved. See
35607// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35608// for more information.
35609func (c *MetrosListCall) Fields(s ...googleapi.Field) *MetrosListCall {
35610	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35611	return c
35612}
35613
35614// IfNoneMatch sets the optional parameter which makes the operation
35615// fail if the object's ETag matches the given value. This is useful for
35616// getting updates only after the object has changed since the last
35617// request. Use googleapi.IsNotModified to check whether the response
35618// error from Do is the result of In-None-Match.
35619func (c *MetrosListCall) IfNoneMatch(entityTag string) *MetrosListCall {
35620	c.ifNoneMatch_ = entityTag
35621	return c
35622}
35623
35624// Context sets the context to be used in this call's Do method. Any
35625// pending HTTP request will be aborted if the provided context is
35626// canceled.
35627func (c *MetrosListCall) Context(ctx context.Context) *MetrosListCall {
35628	c.ctx_ = ctx
35629	return c
35630}
35631
35632// Header returns an http.Header that can be modified by the caller to
35633// add HTTP headers to the request.
35634func (c *MetrosListCall) Header() http.Header {
35635	if c.header_ == nil {
35636		c.header_ = make(http.Header)
35637	}
35638	return c.header_
35639}
35640
35641func (c *MetrosListCall) doRequest(alt string) (*http.Response, error) {
35642	reqHeaders := make(http.Header)
35643	for k, v := range c.header_ {
35644		reqHeaders[k] = v
35645	}
35646	reqHeaders.Set("User-Agent", c.s.userAgent())
35647	if c.ifNoneMatch_ != "" {
35648		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35649	}
35650	var body io.Reader = nil
35651	c.urlParams_.Set("alt", alt)
35652	c.urlParams_.Set("prettyPrint", "false")
35653	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/metros")
35654	urls += "?" + c.urlParams_.Encode()
35655	req, err := http.NewRequest("GET", urls, body)
35656	if err != nil {
35657		return nil, err
35658	}
35659	req.Header = reqHeaders
35660	googleapi.Expand(req.URL, map[string]string{
35661		"profileId": strconv.FormatInt(c.profileId, 10),
35662	})
35663	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35664}
35665
35666// Do executes the "dfareporting.metros.list" call.
35667// Exactly one of *MetrosListResponse or error will be non-nil. Any
35668// non-2xx status code is an error. Response headers are in either
35669// *MetrosListResponse.ServerResponse.Header or (if a response was
35670// returned at all) in error.(*googleapi.Error).Header. Use
35671// googleapi.IsNotModified to check whether the returned error was
35672// because http.StatusNotModified was returned.
35673func (c *MetrosListCall) Do(opts ...googleapi.CallOption) (*MetrosListResponse, error) {
35674	gensupport.SetOptions(c.urlParams_, opts...)
35675	res, err := c.doRequest("json")
35676	if res != nil && res.StatusCode == http.StatusNotModified {
35677		if res.Body != nil {
35678			res.Body.Close()
35679		}
35680		return nil, &googleapi.Error{
35681			Code:   res.StatusCode,
35682			Header: res.Header,
35683		}
35684	}
35685	if err != nil {
35686		return nil, err
35687	}
35688	defer googleapi.CloseBody(res)
35689	if err := googleapi.CheckResponse(res); err != nil {
35690		return nil, err
35691	}
35692	ret := &MetrosListResponse{
35693		ServerResponse: googleapi.ServerResponse{
35694			Header:         res.Header,
35695			HTTPStatusCode: res.StatusCode,
35696		},
35697	}
35698	target := &ret
35699	if err := gensupport.DecodeResponse(target, res); err != nil {
35700		return nil, err
35701	}
35702	return ret, nil
35703	// {
35704	//   "description": "Retrieves a list of metros.",
35705	//   "httpMethod": "GET",
35706	//   "id": "dfareporting.metros.list",
35707	//   "parameterOrder": [
35708	//     "profileId"
35709	//   ],
35710	//   "parameters": {
35711	//     "profileId": {
35712	//       "description": "User profile ID associated with this request.",
35713	//       "format": "int64",
35714	//       "location": "path",
35715	//       "required": true,
35716	//       "type": "string"
35717	//     }
35718	//   },
35719	//   "path": "userprofiles/{profileId}/metros",
35720	//   "response": {
35721	//     "$ref": "MetrosListResponse"
35722	//   },
35723	//   "scopes": [
35724	//     "https://www.googleapis.com/auth/dfatrafficking"
35725	//   ]
35726	// }
35727
35728}
35729
35730// method id "dfareporting.mobileApps.get":
35731
35732type MobileAppsGetCall struct {
35733	s            *Service
35734	profileId    int64
35735	id           string
35736	urlParams_   gensupport.URLParams
35737	ifNoneMatch_ string
35738	ctx_         context.Context
35739	header_      http.Header
35740}
35741
35742// Get: Gets one mobile app by ID.
35743func (r *MobileAppsService) Get(profileId int64, id string) *MobileAppsGetCall {
35744	c := &MobileAppsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35745	c.profileId = profileId
35746	c.id = id
35747	return c
35748}
35749
35750// Fields allows partial responses to be retrieved. See
35751// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35752// for more information.
35753func (c *MobileAppsGetCall) Fields(s ...googleapi.Field) *MobileAppsGetCall {
35754	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35755	return c
35756}
35757
35758// IfNoneMatch sets the optional parameter which makes the operation
35759// fail if the object's ETag matches the given value. This is useful for
35760// getting updates only after the object has changed since the last
35761// request. Use googleapi.IsNotModified to check whether the response
35762// error from Do is the result of In-None-Match.
35763func (c *MobileAppsGetCall) IfNoneMatch(entityTag string) *MobileAppsGetCall {
35764	c.ifNoneMatch_ = entityTag
35765	return c
35766}
35767
35768// Context sets the context to be used in this call's Do method. Any
35769// pending HTTP request will be aborted if the provided context is
35770// canceled.
35771func (c *MobileAppsGetCall) Context(ctx context.Context) *MobileAppsGetCall {
35772	c.ctx_ = ctx
35773	return c
35774}
35775
35776// Header returns an http.Header that can be modified by the caller to
35777// add HTTP headers to the request.
35778func (c *MobileAppsGetCall) Header() http.Header {
35779	if c.header_ == nil {
35780		c.header_ = make(http.Header)
35781	}
35782	return c.header_
35783}
35784
35785func (c *MobileAppsGetCall) doRequest(alt string) (*http.Response, error) {
35786	reqHeaders := make(http.Header)
35787	for k, v := range c.header_ {
35788		reqHeaders[k] = v
35789	}
35790	reqHeaders.Set("User-Agent", c.s.userAgent())
35791	if c.ifNoneMatch_ != "" {
35792		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35793	}
35794	var body io.Reader = nil
35795	c.urlParams_.Set("alt", alt)
35796	c.urlParams_.Set("prettyPrint", "false")
35797	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileApps/{id}")
35798	urls += "?" + c.urlParams_.Encode()
35799	req, err := http.NewRequest("GET", urls, body)
35800	if err != nil {
35801		return nil, err
35802	}
35803	req.Header = reqHeaders
35804	googleapi.Expand(req.URL, map[string]string{
35805		"profileId": strconv.FormatInt(c.profileId, 10),
35806		"id":        c.id,
35807	})
35808	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35809}
35810
35811// Do executes the "dfareporting.mobileApps.get" call.
35812// Exactly one of *MobileApp or error will be non-nil. Any non-2xx
35813// status code is an error. Response headers are in either
35814// *MobileApp.ServerResponse.Header or (if a response was returned at
35815// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
35816// to check whether the returned error was because
35817// http.StatusNotModified was returned.
35818func (c *MobileAppsGetCall) Do(opts ...googleapi.CallOption) (*MobileApp, error) {
35819	gensupport.SetOptions(c.urlParams_, opts...)
35820	res, err := c.doRequest("json")
35821	if res != nil && res.StatusCode == http.StatusNotModified {
35822		if res.Body != nil {
35823			res.Body.Close()
35824		}
35825		return nil, &googleapi.Error{
35826			Code:   res.StatusCode,
35827			Header: res.Header,
35828		}
35829	}
35830	if err != nil {
35831		return nil, err
35832	}
35833	defer googleapi.CloseBody(res)
35834	if err := googleapi.CheckResponse(res); err != nil {
35835		return nil, err
35836	}
35837	ret := &MobileApp{
35838		ServerResponse: googleapi.ServerResponse{
35839			Header:         res.Header,
35840			HTTPStatusCode: res.StatusCode,
35841		},
35842	}
35843	target := &ret
35844	if err := gensupport.DecodeResponse(target, res); err != nil {
35845		return nil, err
35846	}
35847	return ret, nil
35848	// {
35849	//   "description": "Gets one mobile app by ID.",
35850	//   "httpMethod": "GET",
35851	//   "id": "dfareporting.mobileApps.get",
35852	//   "parameterOrder": [
35853	//     "profileId",
35854	//     "id"
35855	//   ],
35856	//   "parameters": {
35857	//     "id": {
35858	//       "description": "Mobile app ID.",
35859	//       "location": "path",
35860	//       "required": true,
35861	//       "type": "string"
35862	//     },
35863	//     "profileId": {
35864	//       "description": "User profile ID associated with this request.",
35865	//       "format": "int64",
35866	//       "location": "path",
35867	//       "required": true,
35868	//       "type": "string"
35869	//     }
35870	//   },
35871	//   "path": "userprofiles/{profileId}/mobileApps/{id}",
35872	//   "response": {
35873	//     "$ref": "MobileApp"
35874	//   },
35875	//   "scopes": [
35876	//     "https://www.googleapis.com/auth/dfatrafficking"
35877	//   ]
35878	// }
35879
35880}
35881
35882// method id "dfareporting.mobileApps.list":
35883
35884type MobileAppsListCall struct {
35885	s            *Service
35886	profileId    int64
35887	urlParams_   gensupport.URLParams
35888	ifNoneMatch_ string
35889	ctx_         context.Context
35890	header_      http.Header
35891}
35892
35893// List: Retrieves list of available mobile apps.
35894func (r *MobileAppsService) List(profileId int64) *MobileAppsListCall {
35895	c := &MobileAppsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35896	c.profileId = profileId
35897	return c
35898}
35899
35900// Directories sets the optional parameter "directories": Select only
35901// apps from these directories.
35902//
35903// Possible values:
35904//   "APPLE_APP_STORE"
35905//   "GOOGLE_PLAY_STORE"
35906//   "UNKNOWN"
35907func (c *MobileAppsListCall) Directories(directories ...string) *MobileAppsListCall {
35908	c.urlParams_.SetMulti("directories", append([]string{}, directories...))
35909	return c
35910}
35911
35912// Ids sets the optional parameter "ids": Select only apps with these
35913// IDs.
35914func (c *MobileAppsListCall) Ids(ids ...string) *MobileAppsListCall {
35915	c.urlParams_.SetMulti("ids", append([]string{}, ids...))
35916	return c
35917}
35918
35919// MaxResults sets the optional parameter "maxResults": Maximum number
35920// of results to return.
35921func (c *MobileAppsListCall) MaxResults(maxResults int64) *MobileAppsListCall {
35922	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
35923	return c
35924}
35925
35926// PageToken sets the optional parameter "pageToken": Value of the
35927// nextPageToken from the previous result page.
35928func (c *MobileAppsListCall) PageToken(pageToken string) *MobileAppsListCall {
35929	c.urlParams_.Set("pageToken", pageToken)
35930	return c
35931}
35932
35933// SearchString sets the optional parameter "searchString": Allows
35934// searching for objects by name or ID. Wildcards (*) are allowed. For
35935// example, "app*2015" will return objects with names like "app Jan
35936// 2018", "app Jan 2018", or simply "app 2018". Most of the searches
35937// also add wildcards implicitly at the start and the end of the search
35938// string. For example, a search string of "app" will match objects with
35939// name "my app", "app 2018", or simply "app".
35940func (c *MobileAppsListCall) SearchString(searchString string) *MobileAppsListCall {
35941	c.urlParams_.Set("searchString", searchString)
35942	return c
35943}
35944
35945// Fields allows partial responses to be retrieved. See
35946// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35947// for more information.
35948func (c *MobileAppsListCall) Fields(s ...googleapi.Field) *MobileAppsListCall {
35949	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35950	return c
35951}
35952
35953// IfNoneMatch sets the optional parameter which makes the operation
35954// fail if the object's ETag matches the given value. This is useful for
35955// getting updates only after the object has changed since the last
35956// request. Use googleapi.IsNotModified to check whether the response
35957// error from Do is the result of In-None-Match.
35958func (c *MobileAppsListCall) IfNoneMatch(entityTag string) *MobileAppsListCall {
35959	c.ifNoneMatch_ = entityTag
35960	return c
35961}
35962
35963// Context sets the context to be used in this call's Do method. Any
35964// pending HTTP request will be aborted if the provided context is
35965// canceled.
35966func (c *MobileAppsListCall) Context(ctx context.Context) *MobileAppsListCall {
35967	c.ctx_ = ctx
35968	return c
35969}
35970
35971// Header returns an http.Header that can be modified by the caller to
35972// add HTTP headers to the request.
35973func (c *MobileAppsListCall) Header() http.Header {
35974	if c.header_ == nil {
35975		c.header_ = make(http.Header)
35976	}
35977	return c.header_
35978}
35979
35980func (c *MobileAppsListCall) doRequest(alt string) (*http.Response, error) {
35981	reqHeaders := make(http.Header)
35982	for k, v := range c.header_ {
35983		reqHeaders[k] = v
35984	}
35985	reqHeaders.Set("User-Agent", c.s.userAgent())
35986	if c.ifNoneMatch_ != "" {
35987		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35988	}
35989	var body io.Reader = nil
35990	c.urlParams_.Set("alt", alt)
35991	c.urlParams_.Set("prettyPrint", "false")
35992	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileApps")
35993	urls += "?" + c.urlParams_.Encode()
35994	req, err := http.NewRequest("GET", urls, body)
35995	if err != nil {
35996		return nil, err
35997	}
35998	req.Header = reqHeaders
35999	googleapi.Expand(req.URL, map[string]string{
36000		"profileId": strconv.FormatInt(c.profileId, 10),
36001	})
36002	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36003}
36004
36005// Do executes the "dfareporting.mobileApps.list" call.
36006// Exactly one of *MobileAppsListResponse or error will be non-nil. Any
36007// non-2xx status code is an error. Response headers are in either
36008// *MobileAppsListResponse.ServerResponse.Header or (if a response was
36009// returned at all) in error.(*googleapi.Error).Header. Use
36010// googleapi.IsNotModified to check whether the returned error was
36011// because http.StatusNotModified was returned.
36012func (c *MobileAppsListCall) Do(opts ...googleapi.CallOption) (*MobileAppsListResponse, error) {
36013	gensupport.SetOptions(c.urlParams_, opts...)
36014	res, err := c.doRequest("json")
36015	if res != nil && res.StatusCode == http.StatusNotModified {
36016		if res.Body != nil {
36017			res.Body.Close()
36018		}
36019		return nil, &googleapi.Error{
36020			Code:   res.StatusCode,
36021			Header: res.Header,
36022		}
36023	}
36024	if err != nil {
36025		return nil, err
36026	}
36027	defer googleapi.CloseBody(res)
36028	if err := googleapi.CheckResponse(res); err != nil {
36029		return nil, err
36030	}
36031	ret := &MobileAppsListResponse{
36032		ServerResponse: googleapi.ServerResponse{
36033			Header:         res.Header,
36034			HTTPStatusCode: res.StatusCode,
36035		},
36036	}
36037	target := &ret
36038	if err := gensupport.DecodeResponse(target, res); err != nil {
36039		return nil, err
36040	}
36041	return ret, nil
36042	// {
36043	//   "description": "Retrieves list of available mobile apps.",
36044	//   "httpMethod": "GET",
36045	//   "id": "dfareporting.mobileApps.list",
36046	//   "parameterOrder": [
36047	//     "profileId"
36048	//   ],
36049	//   "parameters": {
36050	//     "directories": {
36051	//       "description": "Select only apps from these directories.",
36052	//       "enum": [
36053	//         "APPLE_APP_STORE",
36054	//         "GOOGLE_PLAY_STORE",
36055	//         "UNKNOWN"
36056	//       ],
36057	//       "enumDescriptions": [
36058	//         "",
36059	//         "",
36060	//         ""
36061	//       ],
36062	//       "location": "query",
36063	//       "repeated": true,
36064	//       "type": "string"
36065	//     },
36066	//     "ids": {
36067	//       "description": "Select only apps with these IDs.",
36068	//       "location": "query",
36069	//       "repeated": true,
36070	//       "type": "string"
36071	//     },
36072	//     "maxResults": {
36073	//       "default": "1000",
36074	//       "description": "Maximum number of results to return.",
36075	//       "format": "int32",
36076	//       "location": "query",
36077	//       "maximum": "1000",
36078	//       "minimum": "0",
36079	//       "type": "integer"
36080	//     },
36081	//     "pageToken": {
36082	//       "description": "Value of the nextPageToken from the previous result page.",
36083	//       "location": "query",
36084	//       "type": "string"
36085	//     },
36086	//     "profileId": {
36087	//       "description": "User profile ID associated with this request.",
36088	//       "format": "int64",
36089	//       "location": "path",
36090	//       "required": true,
36091	//       "type": "string"
36092	//     },
36093	//     "searchString": {
36094	//       "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\".",
36095	//       "location": "query",
36096	//       "type": "string"
36097	//     }
36098	//   },
36099	//   "path": "userprofiles/{profileId}/mobileApps",
36100	//   "response": {
36101	//     "$ref": "MobileAppsListResponse"
36102	//   },
36103	//   "scopes": [
36104	//     "https://www.googleapis.com/auth/dfatrafficking"
36105	//   ]
36106	// }
36107
36108}
36109
36110// Pages invokes f for each page of results.
36111// A non-nil error returned from f will halt the iteration.
36112// The provided context supersedes any context provided to the Context method.
36113func (c *MobileAppsListCall) Pages(ctx context.Context, f func(*MobileAppsListResponse) error) error {
36114	c.ctx_ = ctx
36115	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
36116	for {
36117		x, err := c.Do()
36118		if err != nil {
36119			return err
36120		}
36121		if err := f(x); err != nil {
36122			return err
36123		}
36124		if x.NextPageToken == "" {
36125			return nil
36126		}
36127		c.PageToken(x.NextPageToken)
36128	}
36129}
36130
36131// method id "dfareporting.mobileCarriers.get":
36132
36133type MobileCarriersGetCall struct {
36134	s            *Service
36135	profileId    int64
36136	id           int64
36137	urlParams_   gensupport.URLParams
36138	ifNoneMatch_ string
36139	ctx_         context.Context
36140	header_      http.Header
36141}
36142
36143// Get: Gets one mobile carrier by ID.
36144func (r *MobileCarriersService) Get(profileId int64, id int64) *MobileCarriersGetCall {
36145	c := &MobileCarriersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36146	c.profileId = profileId
36147	c.id = id
36148	return c
36149}
36150
36151// Fields allows partial responses to be retrieved. See
36152// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36153// for more information.
36154func (c *MobileCarriersGetCall) Fields(s ...googleapi.Field) *MobileCarriersGetCall {
36155	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36156	return c
36157}
36158
36159// IfNoneMatch sets the optional parameter which makes the operation
36160// fail if the object's ETag matches the given value. This is useful for
36161// getting updates only after the object has changed since the last
36162// request. Use googleapi.IsNotModified to check whether the response
36163// error from Do is the result of In-None-Match.
36164func (c *MobileCarriersGetCall) IfNoneMatch(entityTag string) *MobileCarriersGetCall {
36165	c.ifNoneMatch_ = entityTag
36166	return c
36167}
36168
36169// Context sets the context to be used in this call's Do method. Any
36170// pending HTTP request will be aborted if the provided context is
36171// canceled.
36172func (c *MobileCarriersGetCall) Context(ctx context.Context) *MobileCarriersGetCall {
36173	c.ctx_ = ctx
36174	return c
36175}
36176
36177// Header returns an http.Header that can be modified by the caller to
36178// add HTTP headers to the request.
36179func (c *MobileCarriersGetCall) Header() http.Header {
36180	if c.header_ == nil {
36181		c.header_ = make(http.Header)
36182	}
36183	return c.header_
36184}
36185
36186func (c *MobileCarriersGetCall) doRequest(alt string) (*http.Response, error) {
36187	reqHeaders := make(http.Header)
36188	for k, v := range c.header_ {
36189		reqHeaders[k] = v
36190	}
36191	reqHeaders.Set("User-Agent", c.s.userAgent())
36192	if c.ifNoneMatch_ != "" {
36193		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36194	}
36195	var body io.Reader = nil
36196	c.urlParams_.Set("alt", alt)
36197	c.urlParams_.Set("prettyPrint", "false")
36198	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileCarriers/{id}")
36199	urls += "?" + c.urlParams_.Encode()
36200	req, err := http.NewRequest("GET", urls, body)
36201	if err != nil {
36202		return nil, err
36203	}
36204	req.Header = reqHeaders
36205	googleapi.Expand(req.URL, map[string]string{
36206		"profileId": strconv.FormatInt(c.profileId, 10),
36207		"id":        strconv.FormatInt(c.id, 10),
36208	})
36209	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36210}
36211
36212// Do executes the "dfareporting.mobileCarriers.get" call.
36213// Exactly one of *MobileCarrier or error will be non-nil. Any non-2xx
36214// status code is an error. Response headers are in either
36215// *MobileCarrier.ServerResponse.Header or (if a response was returned
36216// at all) in error.(*googleapi.Error).Header. Use
36217// googleapi.IsNotModified to check whether the returned error was
36218// because http.StatusNotModified was returned.
36219func (c *MobileCarriersGetCall) Do(opts ...googleapi.CallOption) (*MobileCarrier, error) {
36220	gensupport.SetOptions(c.urlParams_, opts...)
36221	res, err := c.doRequest("json")
36222	if res != nil && res.StatusCode == http.StatusNotModified {
36223		if res.Body != nil {
36224			res.Body.Close()
36225		}
36226		return nil, &googleapi.Error{
36227			Code:   res.StatusCode,
36228			Header: res.Header,
36229		}
36230	}
36231	if err != nil {
36232		return nil, err
36233	}
36234	defer googleapi.CloseBody(res)
36235	if err := googleapi.CheckResponse(res); err != nil {
36236		return nil, err
36237	}
36238	ret := &MobileCarrier{
36239		ServerResponse: googleapi.ServerResponse{
36240			Header:         res.Header,
36241			HTTPStatusCode: res.StatusCode,
36242		},
36243	}
36244	target := &ret
36245	if err := gensupport.DecodeResponse(target, res); err != nil {
36246		return nil, err
36247	}
36248	return ret, nil
36249	// {
36250	//   "description": "Gets one mobile carrier by ID.",
36251	//   "httpMethod": "GET",
36252	//   "id": "dfareporting.mobileCarriers.get",
36253	//   "parameterOrder": [
36254	//     "profileId",
36255	//     "id"
36256	//   ],
36257	//   "parameters": {
36258	//     "id": {
36259	//       "description": "Mobile carrier ID.",
36260	//       "format": "int64",
36261	//       "location": "path",
36262	//       "required": true,
36263	//       "type": "string"
36264	//     },
36265	//     "profileId": {
36266	//       "description": "User profile ID associated with this request.",
36267	//       "format": "int64",
36268	//       "location": "path",
36269	//       "required": true,
36270	//       "type": "string"
36271	//     }
36272	//   },
36273	//   "path": "userprofiles/{profileId}/mobileCarriers/{id}",
36274	//   "response": {
36275	//     "$ref": "MobileCarrier"
36276	//   },
36277	//   "scopes": [
36278	//     "https://www.googleapis.com/auth/dfatrafficking"
36279	//   ]
36280	// }
36281
36282}
36283
36284// method id "dfareporting.mobileCarriers.list":
36285
36286type MobileCarriersListCall struct {
36287	s            *Service
36288	profileId    int64
36289	urlParams_   gensupport.URLParams
36290	ifNoneMatch_ string
36291	ctx_         context.Context
36292	header_      http.Header
36293}
36294
36295// List: Retrieves a list of mobile carriers.
36296func (r *MobileCarriersService) List(profileId int64) *MobileCarriersListCall {
36297	c := &MobileCarriersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36298	c.profileId = profileId
36299	return c
36300}
36301
36302// Fields allows partial responses to be retrieved. See
36303// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36304// for more information.
36305func (c *MobileCarriersListCall) Fields(s ...googleapi.Field) *MobileCarriersListCall {
36306	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36307	return c
36308}
36309
36310// IfNoneMatch sets the optional parameter which makes the operation
36311// fail if the object's ETag matches the given value. This is useful for
36312// getting updates only after the object has changed since the last
36313// request. Use googleapi.IsNotModified to check whether the response
36314// error from Do is the result of In-None-Match.
36315func (c *MobileCarriersListCall) IfNoneMatch(entityTag string) *MobileCarriersListCall {
36316	c.ifNoneMatch_ = entityTag
36317	return c
36318}
36319
36320// Context sets the context to be used in this call's Do method. Any
36321// pending HTTP request will be aborted if the provided context is
36322// canceled.
36323func (c *MobileCarriersListCall) Context(ctx context.Context) *MobileCarriersListCall {
36324	c.ctx_ = ctx
36325	return c
36326}
36327
36328// Header returns an http.Header that can be modified by the caller to
36329// add HTTP headers to the request.
36330func (c *MobileCarriersListCall) Header() http.Header {
36331	if c.header_ == nil {
36332		c.header_ = make(http.Header)
36333	}
36334	return c.header_
36335}
36336
36337func (c *MobileCarriersListCall) doRequest(alt string) (*http.Response, error) {
36338	reqHeaders := make(http.Header)
36339	for k, v := range c.header_ {
36340		reqHeaders[k] = v
36341	}
36342	reqHeaders.Set("User-Agent", c.s.userAgent())
36343	if c.ifNoneMatch_ != "" {
36344		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36345	}
36346	var body io.Reader = nil
36347	c.urlParams_.Set("alt", alt)
36348	c.urlParams_.Set("prettyPrint", "false")
36349	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileCarriers")
36350	urls += "?" + c.urlParams_.Encode()
36351	req, err := http.NewRequest("GET", urls, body)
36352	if err != nil {
36353		return nil, err
36354	}
36355	req.Header = reqHeaders
36356	googleapi.Expand(req.URL, map[string]string{
36357		"profileId": strconv.FormatInt(c.profileId, 10),
36358	})
36359	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36360}
36361
36362// Do executes the "dfareporting.mobileCarriers.list" call.
36363// Exactly one of *MobileCarriersListResponse or error will be non-nil.
36364// Any non-2xx status code is an error. Response headers are in either
36365// *MobileCarriersListResponse.ServerResponse.Header or (if a response
36366// was returned at all) in error.(*googleapi.Error).Header. Use
36367// googleapi.IsNotModified to check whether the returned error was
36368// because http.StatusNotModified was returned.
36369func (c *MobileCarriersListCall) Do(opts ...googleapi.CallOption) (*MobileCarriersListResponse, error) {
36370	gensupport.SetOptions(c.urlParams_, opts...)
36371	res, err := c.doRequest("json")
36372	if res != nil && res.StatusCode == http.StatusNotModified {
36373		if res.Body != nil {
36374			res.Body.Close()
36375		}
36376		return nil, &googleapi.Error{
36377			Code:   res.StatusCode,
36378			Header: res.Header,
36379		}
36380	}
36381	if err != nil {
36382		return nil, err
36383	}
36384	defer googleapi.CloseBody(res)
36385	if err := googleapi.CheckResponse(res); err != nil {
36386		return nil, err
36387	}
36388	ret := &MobileCarriersListResponse{
36389		ServerResponse: googleapi.ServerResponse{
36390			Header:         res.Header,
36391			HTTPStatusCode: res.StatusCode,
36392		},
36393	}
36394	target := &ret
36395	if err := gensupport.DecodeResponse(target, res); err != nil {
36396		return nil, err
36397	}
36398	return ret, nil
36399	// {
36400	//   "description": "Retrieves a list of mobile carriers.",
36401	//   "httpMethod": "GET",
36402	//   "id": "dfareporting.mobileCarriers.list",
36403	//   "parameterOrder": [
36404	//     "profileId"
36405	//   ],
36406	//   "parameters": {
36407	//     "profileId": {
36408	//       "description": "User profile ID associated with this request.",
36409	//       "format": "int64",
36410	//       "location": "path",
36411	//       "required": true,
36412	//       "type": "string"
36413	//     }
36414	//   },
36415	//   "path": "userprofiles/{profileId}/mobileCarriers",
36416	//   "response": {
36417	//     "$ref": "MobileCarriersListResponse"
36418	//   },
36419	//   "scopes": [
36420	//     "https://www.googleapis.com/auth/dfatrafficking"
36421	//   ]
36422	// }
36423
36424}
36425
36426// method id "dfareporting.operatingSystemVersions.get":
36427
36428type OperatingSystemVersionsGetCall struct {
36429	s            *Service
36430	profileId    int64
36431	id           int64
36432	urlParams_   gensupport.URLParams
36433	ifNoneMatch_ string
36434	ctx_         context.Context
36435	header_      http.Header
36436}
36437
36438// Get: Gets one operating system version by ID.
36439func (r *OperatingSystemVersionsService) Get(profileId int64, id int64) *OperatingSystemVersionsGetCall {
36440	c := &OperatingSystemVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36441	c.profileId = profileId
36442	c.id = id
36443	return c
36444}
36445
36446// Fields allows partial responses to be retrieved. See
36447// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36448// for more information.
36449func (c *OperatingSystemVersionsGetCall) Fields(s ...googleapi.Field) *OperatingSystemVersionsGetCall {
36450	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36451	return c
36452}
36453
36454// IfNoneMatch sets the optional parameter which makes the operation
36455// fail if the object's ETag matches the given value. This is useful for
36456// getting updates only after the object has changed since the last
36457// request. Use googleapi.IsNotModified to check whether the response
36458// error from Do is the result of In-None-Match.
36459func (c *OperatingSystemVersionsGetCall) IfNoneMatch(entityTag string) *OperatingSystemVersionsGetCall {
36460	c.ifNoneMatch_ = entityTag
36461	return c
36462}
36463
36464// Context sets the context to be used in this call's Do method. Any
36465// pending HTTP request will be aborted if the provided context is
36466// canceled.
36467func (c *OperatingSystemVersionsGetCall) Context(ctx context.Context) *OperatingSystemVersionsGetCall {
36468	c.ctx_ = ctx
36469	return c
36470}
36471
36472// Header returns an http.Header that can be modified by the caller to
36473// add HTTP headers to the request.
36474func (c *OperatingSystemVersionsGetCall) Header() http.Header {
36475	if c.header_ == nil {
36476		c.header_ = make(http.Header)
36477	}
36478	return c.header_
36479}
36480
36481func (c *OperatingSystemVersionsGetCall) doRequest(alt string) (*http.Response, error) {
36482	reqHeaders := make(http.Header)
36483	for k, v := range c.header_ {
36484		reqHeaders[k] = v
36485	}
36486	reqHeaders.Set("User-Agent", c.s.userAgent())
36487	if c.ifNoneMatch_ != "" {
36488		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36489	}
36490	var body io.Reader = nil
36491	c.urlParams_.Set("alt", alt)
36492	c.urlParams_.Set("prettyPrint", "false")
36493	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystemVersions/{id}")
36494	urls += "?" + c.urlParams_.Encode()
36495	req, err := http.NewRequest("GET", urls, body)
36496	if err != nil {
36497		return nil, err
36498	}
36499	req.Header = reqHeaders
36500	googleapi.Expand(req.URL, map[string]string{
36501		"profileId": strconv.FormatInt(c.profileId, 10),
36502		"id":        strconv.FormatInt(c.id, 10),
36503	})
36504	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36505}
36506
36507// Do executes the "dfareporting.operatingSystemVersions.get" call.
36508// Exactly one of *OperatingSystemVersion or error will be non-nil. Any
36509// non-2xx status code is an error. Response headers are in either
36510// *OperatingSystemVersion.ServerResponse.Header or (if a response was
36511// returned at all) in error.(*googleapi.Error).Header. Use
36512// googleapi.IsNotModified to check whether the returned error was
36513// because http.StatusNotModified was returned.
36514func (c *OperatingSystemVersionsGetCall) Do(opts ...googleapi.CallOption) (*OperatingSystemVersion, error) {
36515	gensupport.SetOptions(c.urlParams_, opts...)
36516	res, err := c.doRequest("json")
36517	if res != nil && res.StatusCode == http.StatusNotModified {
36518		if res.Body != nil {
36519			res.Body.Close()
36520		}
36521		return nil, &googleapi.Error{
36522			Code:   res.StatusCode,
36523			Header: res.Header,
36524		}
36525	}
36526	if err != nil {
36527		return nil, err
36528	}
36529	defer googleapi.CloseBody(res)
36530	if err := googleapi.CheckResponse(res); err != nil {
36531		return nil, err
36532	}
36533	ret := &OperatingSystemVersion{
36534		ServerResponse: googleapi.ServerResponse{
36535			Header:         res.Header,
36536			HTTPStatusCode: res.StatusCode,
36537		},
36538	}
36539	target := &ret
36540	if err := gensupport.DecodeResponse(target, res); err != nil {
36541		return nil, err
36542	}
36543	return ret, nil
36544	// {
36545	//   "description": "Gets one operating system version by ID.",
36546	//   "httpMethod": "GET",
36547	//   "id": "dfareporting.operatingSystemVersions.get",
36548	//   "parameterOrder": [
36549	//     "profileId",
36550	//     "id"
36551	//   ],
36552	//   "parameters": {
36553	//     "id": {
36554	//       "description": "Operating system version ID.",
36555	//       "format": "int64",
36556	//       "location": "path",
36557	//       "required": true,
36558	//       "type": "string"
36559	//     },
36560	//     "profileId": {
36561	//       "description": "User profile ID associated with this request.",
36562	//       "format": "int64",
36563	//       "location": "path",
36564	//       "required": true,
36565	//       "type": "string"
36566	//     }
36567	//   },
36568	//   "path": "userprofiles/{profileId}/operatingSystemVersions/{id}",
36569	//   "response": {
36570	//     "$ref": "OperatingSystemVersion"
36571	//   },
36572	//   "scopes": [
36573	//     "https://www.googleapis.com/auth/dfatrafficking"
36574	//   ]
36575	// }
36576
36577}
36578
36579// method id "dfareporting.operatingSystemVersions.list":
36580
36581type OperatingSystemVersionsListCall struct {
36582	s            *Service
36583	profileId    int64
36584	urlParams_   gensupport.URLParams
36585	ifNoneMatch_ string
36586	ctx_         context.Context
36587	header_      http.Header
36588}
36589
36590// List: Retrieves a list of operating system versions.
36591func (r *OperatingSystemVersionsService) List(profileId int64) *OperatingSystemVersionsListCall {
36592	c := &OperatingSystemVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36593	c.profileId = profileId
36594	return c
36595}
36596
36597// Fields allows partial responses to be retrieved. See
36598// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36599// for more information.
36600func (c *OperatingSystemVersionsListCall) Fields(s ...googleapi.Field) *OperatingSystemVersionsListCall {
36601	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36602	return c
36603}
36604
36605// IfNoneMatch sets the optional parameter which makes the operation
36606// fail if the object's ETag matches the given value. This is useful for
36607// getting updates only after the object has changed since the last
36608// request. Use googleapi.IsNotModified to check whether the response
36609// error from Do is the result of In-None-Match.
36610func (c *OperatingSystemVersionsListCall) IfNoneMatch(entityTag string) *OperatingSystemVersionsListCall {
36611	c.ifNoneMatch_ = entityTag
36612	return c
36613}
36614
36615// Context sets the context to be used in this call's Do method. Any
36616// pending HTTP request will be aborted if the provided context is
36617// canceled.
36618func (c *OperatingSystemVersionsListCall) Context(ctx context.Context) *OperatingSystemVersionsListCall {
36619	c.ctx_ = ctx
36620	return c
36621}
36622
36623// Header returns an http.Header that can be modified by the caller to
36624// add HTTP headers to the request.
36625func (c *OperatingSystemVersionsListCall) Header() http.Header {
36626	if c.header_ == nil {
36627		c.header_ = make(http.Header)
36628	}
36629	return c.header_
36630}
36631
36632func (c *OperatingSystemVersionsListCall) doRequest(alt string) (*http.Response, error) {
36633	reqHeaders := make(http.Header)
36634	for k, v := range c.header_ {
36635		reqHeaders[k] = v
36636	}
36637	reqHeaders.Set("User-Agent", c.s.userAgent())
36638	if c.ifNoneMatch_ != "" {
36639		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36640	}
36641	var body io.Reader = nil
36642	c.urlParams_.Set("alt", alt)
36643	c.urlParams_.Set("prettyPrint", "false")
36644	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystemVersions")
36645	urls += "?" + c.urlParams_.Encode()
36646	req, err := http.NewRequest("GET", urls, body)
36647	if err != nil {
36648		return nil, err
36649	}
36650	req.Header = reqHeaders
36651	googleapi.Expand(req.URL, map[string]string{
36652		"profileId": strconv.FormatInt(c.profileId, 10),
36653	})
36654	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36655}
36656
36657// Do executes the "dfareporting.operatingSystemVersions.list" call.
36658// Exactly one of *OperatingSystemVersionsListResponse or error will be
36659// non-nil. Any non-2xx status code is an error. Response headers are in
36660// either *OperatingSystemVersionsListResponse.ServerResponse.Header or
36661// (if a response was returned at all) in
36662// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
36663// whether the returned error was because http.StatusNotModified was
36664// returned.
36665func (c *OperatingSystemVersionsListCall) Do(opts ...googleapi.CallOption) (*OperatingSystemVersionsListResponse, error) {
36666	gensupport.SetOptions(c.urlParams_, opts...)
36667	res, err := c.doRequest("json")
36668	if res != nil && res.StatusCode == http.StatusNotModified {
36669		if res.Body != nil {
36670			res.Body.Close()
36671		}
36672		return nil, &googleapi.Error{
36673			Code:   res.StatusCode,
36674			Header: res.Header,
36675		}
36676	}
36677	if err != nil {
36678		return nil, err
36679	}
36680	defer googleapi.CloseBody(res)
36681	if err := googleapi.CheckResponse(res); err != nil {
36682		return nil, err
36683	}
36684	ret := &OperatingSystemVersionsListResponse{
36685		ServerResponse: googleapi.ServerResponse{
36686			Header:         res.Header,
36687			HTTPStatusCode: res.StatusCode,
36688		},
36689	}
36690	target := &ret
36691	if err := gensupport.DecodeResponse(target, res); err != nil {
36692		return nil, err
36693	}
36694	return ret, nil
36695	// {
36696	//   "description": "Retrieves a list of operating system versions.",
36697	//   "httpMethod": "GET",
36698	//   "id": "dfareporting.operatingSystemVersions.list",
36699	//   "parameterOrder": [
36700	//     "profileId"
36701	//   ],
36702	//   "parameters": {
36703	//     "profileId": {
36704	//       "description": "User profile ID associated with this request.",
36705	//       "format": "int64",
36706	//       "location": "path",
36707	//       "required": true,
36708	//       "type": "string"
36709	//     }
36710	//   },
36711	//   "path": "userprofiles/{profileId}/operatingSystemVersions",
36712	//   "response": {
36713	//     "$ref": "OperatingSystemVersionsListResponse"
36714	//   },
36715	//   "scopes": [
36716	//     "https://www.googleapis.com/auth/dfatrafficking"
36717	//   ]
36718	// }
36719
36720}
36721
36722// method id "dfareporting.operatingSystems.get":
36723
36724type OperatingSystemsGetCall struct {
36725	s            *Service
36726	profileId    int64
36727	dartId       int64
36728	urlParams_   gensupport.URLParams
36729	ifNoneMatch_ string
36730	ctx_         context.Context
36731	header_      http.Header
36732}
36733
36734// Get: Gets one operating system by DART ID.
36735func (r *OperatingSystemsService) Get(profileId int64, dartId int64) *OperatingSystemsGetCall {
36736	c := &OperatingSystemsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36737	c.profileId = profileId
36738	c.dartId = dartId
36739	return c
36740}
36741
36742// Fields allows partial responses to be retrieved. See
36743// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36744// for more information.
36745func (c *OperatingSystemsGetCall) Fields(s ...googleapi.Field) *OperatingSystemsGetCall {
36746	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36747	return c
36748}
36749
36750// IfNoneMatch sets the optional parameter which makes the operation
36751// fail if the object's ETag matches the given value. This is useful for
36752// getting updates only after the object has changed since the last
36753// request. Use googleapi.IsNotModified to check whether the response
36754// error from Do is the result of In-None-Match.
36755func (c *OperatingSystemsGetCall) IfNoneMatch(entityTag string) *OperatingSystemsGetCall {
36756	c.ifNoneMatch_ = entityTag
36757	return c
36758}
36759
36760// Context sets the context to be used in this call's Do method. Any
36761// pending HTTP request will be aborted if the provided context is
36762// canceled.
36763func (c *OperatingSystemsGetCall) Context(ctx context.Context) *OperatingSystemsGetCall {
36764	c.ctx_ = ctx
36765	return c
36766}
36767
36768// Header returns an http.Header that can be modified by the caller to
36769// add HTTP headers to the request.
36770func (c *OperatingSystemsGetCall) Header() http.Header {
36771	if c.header_ == nil {
36772		c.header_ = make(http.Header)
36773	}
36774	return c.header_
36775}
36776
36777func (c *OperatingSystemsGetCall) doRequest(alt string) (*http.Response, error) {
36778	reqHeaders := make(http.Header)
36779	for k, v := range c.header_ {
36780		reqHeaders[k] = v
36781	}
36782	reqHeaders.Set("User-Agent", c.s.userAgent())
36783	if c.ifNoneMatch_ != "" {
36784		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36785	}
36786	var body io.Reader = nil
36787	c.urlParams_.Set("alt", alt)
36788	c.urlParams_.Set("prettyPrint", "false")
36789	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystems/{dartId}")
36790	urls += "?" + c.urlParams_.Encode()
36791	req, err := http.NewRequest("GET", urls, body)
36792	if err != nil {
36793		return nil, err
36794	}
36795	req.Header = reqHeaders
36796	googleapi.Expand(req.URL, map[string]string{
36797		"profileId": strconv.FormatInt(c.profileId, 10),
36798		"dartId":    strconv.FormatInt(c.dartId, 10),
36799	})
36800	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36801}
36802
36803// Do executes the "dfareporting.operatingSystems.get" call.
36804// Exactly one of *OperatingSystem or error will be non-nil. Any non-2xx
36805// status code is an error. Response headers are in either
36806// *OperatingSystem.ServerResponse.Header or (if a response was returned
36807// at all) in error.(*googleapi.Error).Header. Use
36808// googleapi.IsNotModified to check whether the returned error was
36809// because http.StatusNotModified was returned.
36810func (c *OperatingSystemsGetCall) Do(opts ...googleapi.CallOption) (*OperatingSystem, error) {
36811	gensupport.SetOptions(c.urlParams_, opts...)
36812	res, err := c.doRequest("json")
36813	if res != nil && res.StatusCode == http.StatusNotModified {
36814		if res.Body != nil {
36815			res.Body.Close()
36816		}
36817		return nil, &googleapi.Error{
36818			Code:   res.StatusCode,
36819			Header: res.Header,
36820		}
36821	}
36822	if err != nil {
36823		return nil, err
36824	}
36825	defer googleapi.CloseBody(res)
36826	if err := googleapi.CheckResponse(res); err != nil {
36827		return nil, err
36828	}
36829	ret := &OperatingSystem{
36830		ServerResponse: googleapi.ServerResponse{
36831			Header:         res.Header,
36832			HTTPStatusCode: res.StatusCode,
36833		},
36834	}
36835	target := &ret
36836	if err := gensupport.DecodeResponse(target, res); err != nil {
36837		return nil, err
36838	}
36839	return ret, nil
36840	// {
36841	//   "description": "Gets one operating system by DART ID.",
36842	//   "httpMethod": "GET",
36843	//   "id": "dfareporting.operatingSystems.get",
36844	//   "parameterOrder": [
36845	//     "profileId",
36846	//     "dartId"
36847	//   ],
36848	//   "parameters": {
36849	//     "dartId": {
36850	//       "description": "Operating system DART ID.",
36851	//       "format": "int64",
36852	//       "location": "path",
36853	//       "required": true,
36854	//       "type": "string"
36855	//     },
36856	//     "profileId": {
36857	//       "description": "User profile ID associated with this request.",
36858	//       "format": "int64",
36859	//       "location": "path",
36860	//       "required": true,
36861	//       "type": "string"
36862	//     }
36863	//   },
36864	//   "path": "userprofiles/{profileId}/operatingSystems/{dartId}",
36865	//   "response": {
36866	//     "$ref": "OperatingSystem"
36867	//   },
36868	//   "scopes": [
36869	//     "https://www.googleapis.com/auth/dfatrafficking"
36870	//   ]
36871	// }
36872
36873}
36874
36875// method id "dfareporting.operatingSystems.list":
36876
36877type OperatingSystemsListCall struct {
36878	s            *Service
36879	profileId    int64
36880	urlParams_   gensupport.URLParams
36881	ifNoneMatch_ string
36882	ctx_         context.Context
36883	header_      http.Header
36884}
36885
36886// List: Retrieves a list of operating systems.
36887func (r *OperatingSystemsService) List(profileId int64) *OperatingSystemsListCall {
36888	c := &OperatingSystemsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36889	c.profileId = profileId
36890	return c
36891}
36892
36893// Fields allows partial responses to be retrieved. See
36894// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36895// for more information.
36896func (c *OperatingSystemsListCall) Fields(s ...googleapi.Field) *OperatingSystemsListCall {
36897	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36898	return c
36899}
36900
36901// IfNoneMatch sets the optional parameter which makes the operation
36902// fail if the object's ETag matches the given value. This is useful for
36903// getting updates only after the object has changed since the last
36904// request. Use googleapi.IsNotModified to check whether the response
36905// error from Do is the result of In-None-Match.
36906func (c *OperatingSystemsListCall) IfNoneMatch(entityTag string) *OperatingSystemsListCall {
36907	c.ifNoneMatch_ = entityTag
36908	return c
36909}
36910
36911// Context sets the context to be used in this call's Do method. Any
36912// pending HTTP request will be aborted if the provided context is
36913// canceled.
36914func (c *OperatingSystemsListCall) Context(ctx context.Context) *OperatingSystemsListCall {
36915	c.ctx_ = ctx
36916	return c
36917}
36918
36919// Header returns an http.Header that can be modified by the caller to
36920// add HTTP headers to the request.
36921func (c *OperatingSystemsListCall) Header() http.Header {
36922	if c.header_ == nil {
36923		c.header_ = make(http.Header)
36924	}
36925	return c.header_
36926}
36927
36928func (c *OperatingSystemsListCall) doRequest(alt string) (*http.Response, error) {
36929	reqHeaders := make(http.Header)
36930	for k, v := range c.header_ {
36931		reqHeaders[k] = v
36932	}
36933	reqHeaders.Set("User-Agent", c.s.userAgent())
36934	if c.ifNoneMatch_ != "" {
36935		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36936	}
36937	var body io.Reader = nil
36938	c.urlParams_.Set("alt", alt)
36939	c.urlParams_.Set("prettyPrint", "false")
36940	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystems")
36941	urls += "?" + c.urlParams_.Encode()
36942	req, err := http.NewRequest("GET", urls, body)
36943	if err != nil {
36944		return nil, err
36945	}
36946	req.Header = reqHeaders
36947	googleapi.Expand(req.URL, map[string]string{
36948		"profileId": strconv.FormatInt(c.profileId, 10),
36949	})
36950	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36951}
36952
36953// Do executes the "dfareporting.operatingSystems.list" call.
36954// Exactly one of *OperatingSystemsListResponse or error will be
36955// non-nil. Any non-2xx status code is an error. Response headers are in
36956// either *OperatingSystemsListResponse.ServerResponse.Header or (if a
36957// response was returned at all) in error.(*googleapi.Error).Header. Use
36958// googleapi.IsNotModified to check whether the returned error was
36959// because http.StatusNotModified was returned.
36960func (c *OperatingSystemsListCall) Do(opts ...googleapi.CallOption) (*OperatingSystemsListResponse, error) {
36961	gensupport.SetOptions(c.urlParams_, opts...)
36962	res, err := c.doRequest("json")
36963	if res != nil && res.StatusCode == http.StatusNotModified {
36964		if res.Body != nil {
36965			res.Body.Close()
36966		}
36967		return nil, &googleapi.Error{
36968			Code:   res.StatusCode,
36969			Header: res.Header,
36970		}
36971	}
36972	if err != nil {
36973		return nil, err
36974	}
36975	defer googleapi.CloseBody(res)
36976	if err := googleapi.CheckResponse(res); err != nil {
36977		return nil, err
36978	}
36979	ret := &OperatingSystemsListResponse{
36980		ServerResponse: googleapi.ServerResponse{
36981			Header:         res.Header,
36982			HTTPStatusCode: res.StatusCode,
36983		},
36984	}
36985	target := &ret
36986	if err := gensupport.DecodeResponse(target, res); err != nil {
36987		return nil, err
36988	}
36989	return ret, nil
36990	// {
36991	//   "description": "Retrieves a list of operating systems.",
36992	//   "httpMethod": "GET",
36993	//   "id": "dfareporting.operatingSystems.list",
36994	//   "parameterOrder": [
36995	//     "profileId"
36996	//   ],
36997	//   "parameters": {
36998	//     "profileId": {
36999	//       "description": "User profile ID associated with this request.",
37000	//       "format": "int64",
37001	//       "location": "path",
37002	//       "required": true,
37003	//       "type": "string"
37004	//     }
37005	//   },
37006	//   "path": "userprofiles/{profileId}/operatingSystems",
37007	//   "response": {
37008	//     "$ref": "OperatingSystemsListResponse"
37009	//   },
37010	//   "scopes": [
37011	//     "https://www.googleapis.com/auth/dfatrafficking"
37012	//   ]
37013	// }
37014
37015}
37016
37017// method id "dfareporting.orderDocuments.get":
37018
37019type OrderDocumentsGetCall struct {
37020	s            *Service
37021	profileId    int64
37022	projectId    int64
37023	id           int64
37024	urlParams_   gensupport.URLParams
37025	ifNoneMatch_ string
37026	ctx_         context.Context
37027	header_      http.Header
37028}
37029
37030// Get: Gets one order document by ID.
37031func (r *OrderDocumentsService) Get(profileId int64, projectId int64, id int64) *OrderDocumentsGetCall {
37032	c := &OrderDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37033	c.profileId = profileId
37034	c.projectId = projectId
37035	c.id = id
37036	return c
37037}
37038
37039// Fields allows partial responses to be retrieved. See
37040// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37041// for more information.
37042func (c *OrderDocumentsGetCall) Fields(s ...googleapi.Field) *OrderDocumentsGetCall {
37043	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37044	return c
37045}
37046
37047// IfNoneMatch sets the optional parameter which makes the operation
37048// fail if the object's ETag matches the given value. This is useful for
37049// getting updates only after the object has changed since the last
37050// request. Use googleapi.IsNotModified to check whether the response
37051// error from Do is the result of In-None-Match.
37052func (c *OrderDocumentsGetCall) IfNoneMatch(entityTag string) *OrderDocumentsGetCall {
37053	c.ifNoneMatch_ = entityTag
37054	return c
37055}
37056
37057// Context sets the context to be used in this call's Do method. Any
37058// pending HTTP request will be aborted if the provided context is
37059// canceled.
37060func (c *OrderDocumentsGetCall) Context(ctx context.Context) *OrderDocumentsGetCall {
37061	c.ctx_ = ctx
37062	return c
37063}
37064
37065// Header returns an http.Header that can be modified by the caller to
37066// add HTTP headers to the request.
37067func (c *OrderDocumentsGetCall) Header() http.Header {
37068	if c.header_ == nil {
37069		c.header_ = make(http.Header)
37070	}
37071	return c.header_
37072}
37073
37074func (c *OrderDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
37075	reqHeaders := make(http.Header)
37076	for k, v := range c.header_ {
37077		reqHeaders[k] = v
37078	}
37079	reqHeaders.Set("User-Agent", c.s.userAgent())
37080	if c.ifNoneMatch_ != "" {
37081		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37082	}
37083	var body io.Reader = nil
37084	c.urlParams_.Set("alt", alt)
37085	c.urlParams_.Set("prettyPrint", "false")
37086	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orderDocuments/{id}")
37087	urls += "?" + c.urlParams_.Encode()
37088	req, err := http.NewRequest("GET", urls, body)
37089	if err != nil {
37090		return nil, err
37091	}
37092	req.Header = reqHeaders
37093	googleapi.Expand(req.URL, map[string]string{
37094		"profileId": strconv.FormatInt(c.profileId, 10),
37095		"projectId": strconv.FormatInt(c.projectId, 10),
37096		"id":        strconv.FormatInt(c.id, 10),
37097	})
37098	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37099}
37100
37101// Do executes the "dfareporting.orderDocuments.get" call.
37102// Exactly one of *OrderDocument or error will be non-nil. Any non-2xx
37103// status code is an error. Response headers are in either
37104// *OrderDocument.ServerResponse.Header or (if a response was returned
37105// at all) in error.(*googleapi.Error).Header. Use
37106// googleapi.IsNotModified to check whether the returned error was
37107// because http.StatusNotModified was returned.
37108func (c *OrderDocumentsGetCall) Do(opts ...googleapi.CallOption) (*OrderDocument, error) {
37109	gensupport.SetOptions(c.urlParams_, opts...)
37110	res, err := c.doRequest("json")
37111	if res != nil && res.StatusCode == http.StatusNotModified {
37112		if res.Body != nil {
37113			res.Body.Close()
37114		}
37115		return nil, &googleapi.Error{
37116			Code:   res.StatusCode,
37117			Header: res.Header,
37118		}
37119	}
37120	if err != nil {
37121		return nil, err
37122	}
37123	defer googleapi.CloseBody(res)
37124	if err := googleapi.CheckResponse(res); err != nil {
37125		return nil, err
37126	}
37127	ret := &OrderDocument{
37128		ServerResponse: googleapi.ServerResponse{
37129			Header:         res.Header,
37130			HTTPStatusCode: res.StatusCode,
37131		},
37132	}
37133	target := &ret
37134	if err := gensupport.DecodeResponse(target, res); err != nil {
37135		return nil, err
37136	}
37137	return ret, nil
37138	// {
37139	//   "description": "Gets one order document by ID.",
37140	//   "httpMethod": "GET",
37141	//   "id": "dfareporting.orderDocuments.get",
37142	//   "parameterOrder": [
37143	//     "profileId",
37144	//     "projectId",
37145	//     "id"
37146	//   ],
37147	//   "parameters": {
37148	//     "id": {
37149	//       "description": "Order document ID.",
37150	//       "format": "int64",
37151	//       "location": "path",
37152	//       "required": true,
37153	//       "type": "string"
37154	//     },
37155	//     "profileId": {
37156	//       "description": "User profile ID associated with this request.",
37157	//       "format": "int64",
37158	//       "location": "path",
37159	//       "required": true,
37160	//       "type": "string"
37161	//     },
37162	//     "projectId": {
37163	//       "description": "Project ID for order documents.",
37164	//       "format": "int64",
37165	//       "location": "path",
37166	//       "required": true,
37167	//       "type": "string"
37168	//     }
37169	//   },
37170	//   "path": "userprofiles/{profileId}/projects/{projectId}/orderDocuments/{id}",
37171	//   "response": {
37172	//     "$ref": "OrderDocument"
37173	//   },
37174	//   "scopes": [
37175	//     "https://www.googleapis.com/auth/dfatrafficking"
37176	//   ]
37177	// }
37178
37179}
37180
37181// method id "dfareporting.orderDocuments.list":
37182
37183type OrderDocumentsListCall struct {
37184	s            *Service
37185	profileId    int64
37186	projectId    int64
37187	urlParams_   gensupport.URLParams
37188	ifNoneMatch_ string
37189	ctx_         context.Context
37190	header_      http.Header
37191}
37192
37193// List: Retrieves a list of order documents, possibly filtered. This
37194// method supports paging.
37195func (r *OrderDocumentsService) List(profileId int64, projectId int64) *OrderDocumentsListCall {
37196	c := &OrderDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37197	c.profileId = profileId
37198	c.projectId = projectId
37199	return c
37200}
37201
37202// Approved sets the optional parameter "approved": Select only order
37203// documents that have been approved by at least one user.
37204func (c *OrderDocumentsListCall) Approved(approved bool) *OrderDocumentsListCall {
37205	c.urlParams_.Set("approved", fmt.Sprint(approved))
37206	return c
37207}
37208
37209// Ids sets the optional parameter "ids": Select only order documents
37210// with these IDs.
37211func (c *OrderDocumentsListCall) Ids(ids ...int64) *OrderDocumentsListCall {
37212	var ids_ []string
37213	for _, v := range ids {
37214		ids_ = append(ids_, fmt.Sprint(v))
37215	}
37216	c.urlParams_.SetMulti("ids", ids_)
37217	return c
37218}
37219
37220// MaxResults sets the optional parameter "maxResults": Maximum number
37221// of results to return.
37222func (c *OrderDocumentsListCall) MaxResults(maxResults int64) *OrderDocumentsListCall {
37223	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
37224	return c
37225}
37226
37227// OrderId sets the optional parameter "orderId": Select only order
37228// documents for specified orders.
37229func (c *OrderDocumentsListCall) OrderId(orderId ...int64) *OrderDocumentsListCall {
37230	var orderId_ []string
37231	for _, v := range orderId {
37232		orderId_ = append(orderId_, fmt.Sprint(v))
37233	}
37234	c.urlParams_.SetMulti("orderId", orderId_)
37235	return c
37236}
37237
37238// PageToken sets the optional parameter "pageToken": Value of the
37239// nextPageToken from the previous result page.
37240func (c *OrderDocumentsListCall) PageToken(pageToken string) *OrderDocumentsListCall {
37241	c.urlParams_.Set("pageToken", pageToken)
37242	return c
37243}
37244
37245// SearchString sets the optional parameter "searchString": Allows
37246// searching for order documents by name or ID. Wildcards (*) are
37247// allowed. For example, "orderdocument*2015" will return order
37248// documents with names like "orderdocument June 2015", "orderdocument
37249// April 2015", or simply "orderdocument 2015". Most of the searches
37250// also add wildcards implicitly at the start and the end of the search
37251// string. For example, a search string of "orderdocument" will match
37252// order documents with name "my orderdocument", "orderdocument 2015",
37253// or simply "orderdocument".
37254func (c *OrderDocumentsListCall) SearchString(searchString string) *OrderDocumentsListCall {
37255	c.urlParams_.Set("searchString", searchString)
37256	return c
37257}
37258
37259// SiteId sets the optional parameter "siteId": Select only order
37260// documents that are associated with these sites.
37261func (c *OrderDocumentsListCall) SiteId(siteId ...int64) *OrderDocumentsListCall {
37262	var siteId_ []string
37263	for _, v := range siteId {
37264		siteId_ = append(siteId_, fmt.Sprint(v))
37265	}
37266	c.urlParams_.SetMulti("siteId", siteId_)
37267	return c
37268}
37269
37270// SortField sets the optional parameter "sortField": Field by which to
37271// sort the list.
37272//
37273// Possible values:
37274//   "ID" (default)
37275//   "NAME"
37276func (c *OrderDocumentsListCall) SortField(sortField string) *OrderDocumentsListCall {
37277	c.urlParams_.Set("sortField", sortField)
37278	return c
37279}
37280
37281// SortOrder sets the optional parameter "sortOrder": Order of sorted
37282// results.
37283//
37284// Possible values:
37285//   "ASCENDING" (default)
37286//   "DESCENDING"
37287func (c *OrderDocumentsListCall) SortOrder(sortOrder string) *OrderDocumentsListCall {
37288	c.urlParams_.Set("sortOrder", sortOrder)
37289	return c
37290}
37291
37292// Fields allows partial responses to be retrieved. See
37293// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37294// for more information.
37295func (c *OrderDocumentsListCall) Fields(s ...googleapi.Field) *OrderDocumentsListCall {
37296	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37297	return c
37298}
37299
37300// IfNoneMatch sets the optional parameter which makes the operation
37301// fail if the object's ETag matches the given value. This is useful for
37302// getting updates only after the object has changed since the last
37303// request. Use googleapi.IsNotModified to check whether the response
37304// error from Do is the result of In-None-Match.
37305func (c *OrderDocumentsListCall) IfNoneMatch(entityTag string) *OrderDocumentsListCall {
37306	c.ifNoneMatch_ = entityTag
37307	return c
37308}
37309
37310// Context sets the context to be used in this call's Do method. Any
37311// pending HTTP request will be aborted if the provided context is
37312// canceled.
37313func (c *OrderDocumentsListCall) Context(ctx context.Context) *OrderDocumentsListCall {
37314	c.ctx_ = ctx
37315	return c
37316}
37317
37318// Header returns an http.Header that can be modified by the caller to
37319// add HTTP headers to the request.
37320func (c *OrderDocumentsListCall) Header() http.Header {
37321	if c.header_ == nil {
37322		c.header_ = make(http.Header)
37323	}
37324	return c.header_
37325}
37326
37327func (c *OrderDocumentsListCall) doRequest(alt string) (*http.Response, error) {
37328	reqHeaders := make(http.Header)
37329	for k, v := range c.header_ {
37330		reqHeaders[k] = v
37331	}
37332	reqHeaders.Set("User-Agent", c.s.userAgent())
37333	if c.ifNoneMatch_ != "" {
37334		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37335	}
37336	var body io.Reader = nil
37337	c.urlParams_.Set("alt", alt)
37338	c.urlParams_.Set("prettyPrint", "false")
37339	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orderDocuments")
37340	urls += "?" + c.urlParams_.Encode()
37341	req, err := http.NewRequest("GET", urls, body)
37342	if err != nil {
37343		return nil, err
37344	}
37345	req.Header = reqHeaders
37346	googleapi.Expand(req.URL, map[string]string{
37347		"profileId": strconv.FormatInt(c.profileId, 10),
37348		"projectId": strconv.FormatInt(c.projectId, 10),
37349	})
37350	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37351}
37352
37353// Do executes the "dfareporting.orderDocuments.list" call.
37354// Exactly one of *OrderDocumentsListResponse or error will be non-nil.
37355// Any non-2xx status code is an error. Response headers are in either
37356// *OrderDocumentsListResponse.ServerResponse.Header or (if a response
37357// was returned at all) in error.(*googleapi.Error).Header. Use
37358// googleapi.IsNotModified to check whether the returned error was
37359// because http.StatusNotModified was returned.
37360func (c *OrderDocumentsListCall) Do(opts ...googleapi.CallOption) (*OrderDocumentsListResponse, error) {
37361	gensupport.SetOptions(c.urlParams_, opts...)
37362	res, err := c.doRequest("json")
37363	if res != nil && res.StatusCode == http.StatusNotModified {
37364		if res.Body != nil {
37365			res.Body.Close()
37366		}
37367		return nil, &googleapi.Error{
37368			Code:   res.StatusCode,
37369			Header: res.Header,
37370		}
37371	}
37372	if err != nil {
37373		return nil, err
37374	}
37375	defer googleapi.CloseBody(res)
37376	if err := googleapi.CheckResponse(res); err != nil {
37377		return nil, err
37378	}
37379	ret := &OrderDocumentsListResponse{
37380		ServerResponse: googleapi.ServerResponse{
37381			Header:         res.Header,
37382			HTTPStatusCode: res.StatusCode,
37383		},
37384	}
37385	target := &ret
37386	if err := gensupport.DecodeResponse(target, res); err != nil {
37387		return nil, err
37388	}
37389	return ret, nil
37390	// {
37391	//   "description": "Retrieves a list of order documents, possibly filtered. This method supports paging.",
37392	//   "httpMethod": "GET",
37393	//   "id": "dfareporting.orderDocuments.list",
37394	//   "parameterOrder": [
37395	//     "profileId",
37396	//     "projectId"
37397	//   ],
37398	//   "parameters": {
37399	//     "approved": {
37400	//       "description": "Select only order documents that have been approved by at least one user.",
37401	//       "location": "query",
37402	//       "type": "boolean"
37403	//     },
37404	//     "ids": {
37405	//       "description": "Select only order documents with these IDs.",
37406	//       "format": "int64",
37407	//       "location": "query",
37408	//       "repeated": true,
37409	//       "type": "string"
37410	//     },
37411	//     "maxResults": {
37412	//       "default": "1000",
37413	//       "description": "Maximum number of results to return.",
37414	//       "format": "int32",
37415	//       "location": "query",
37416	//       "maximum": "1000",
37417	//       "minimum": "0",
37418	//       "type": "integer"
37419	//     },
37420	//     "orderId": {
37421	//       "description": "Select only order documents for specified orders.",
37422	//       "format": "int64",
37423	//       "location": "query",
37424	//       "repeated": true,
37425	//       "type": "string"
37426	//     },
37427	//     "pageToken": {
37428	//       "description": "Value of the nextPageToken from the previous result page.",
37429	//       "location": "query",
37430	//       "type": "string"
37431	//     },
37432	//     "profileId": {
37433	//       "description": "User profile ID associated with this request.",
37434	//       "format": "int64",
37435	//       "location": "path",
37436	//       "required": true,
37437	//       "type": "string"
37438	//     },
37439	//     "projectId": {
37440	//       "description": "Project ID for order documents.",
37441	//       "format": "int64",
37442	//       "location": "path",
37443	//       "required": true,
37444	//       "type": "string"
37445	//     },
37446	//     "searchString": {
37447	//       "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\".",
37448	//       "location": "query",
37449	//       "type": "string"
37450	//     },
37451	//     "siteId": {
37452	//       "description": "Select only order documents that are associated with these sites.",
37453	//       "format": "int64",
37454	//       "location": "query",
37455	//       "repeated": true,
37456	//       "type": "string"
37457	//     },
37458	//     "sortField": {
37459	//       "default": "ID",
37460	//       "description": "Field by which to sort the list.",
37461	//       "enum": [
37462	//         "ID",
37463	//         "NAME"
37464	//       ],
37465	//       "enumDescriptions": [
37466	//         "",
37467	//         ""
37468	//       ],
37469	//       "location": "query",
37470	//       "type": "string"
37471	//     },
37472	//     "sortOrder": {
37473	//       "default": "ASCENDING",
37474	//       "description": "Order of sorted results.",
37475	//       "enum": [
37476	//         "ASCENDING",
37477	//         "DESCENDING"
37478	//       ],
37479	//       "enumDescriptions": [
37480	//         "",
37481	//         ""
37482	//       ],
37483	//       "location": "query",
37484	//       "type": "string"
37485	//     }
37486	//   },
37487	//   "path": "userprofiles/{profileId}/projects/{projectId}/orderDocuments",
37488	//   "response": {
37489	//     "$ref": "OrderDocumentsListResponse"
37490	//   },
37491	//   "scopes": [
37492	//     "https://www.googleapis.com/auth/dfatrafficking"
37493	//   ]
37494	// }
37495
37496}
37497
37498// Pages invokes f for each page of results.
37499// A non-nil error returned from f will halt the iteration.
37500// The provided context supersedes any context provided to the Context method.
37501func (c *OrderDocumentsListCall) Pages(ctx context.Context, f func(*OrderDocumentsListResponse) error) error {
37502	c.ctx_ = ctx
37503	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
37504	for {
37505		x, err := c.Do()
37506		if err != nil {
37507			return err
37508		}
37509		if err := f(x); err != nil {
37510			return err
37511		}
37512		if x.NextPageToken == "" {
37513			return nil
37514		}
37515		c.PageToken(x.NextPageToken)
37516	}
37517}
37518
37519// method id "dfareporting.orders.get":
37520
37521type OrdersGetCall struct {
37522	s            *Service
37523	profileId    int64
37524	projectId    int64
37525	id           int64
37526	urlParams_   gensupport.URLParams
37527	ifNoneMatch_ string
37528	ctx_         context.Context
37529	header_      http.Header
37530}
37531
37532// Get: Gets one order by ID.
37533func (r *OrdersService) Get(profileId int64, projectId int64, id int64) *OrdersGetCall {
37534	c := &OrdersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37535	c.profileId = profileId
37536	c.projectId = projectId
37537	c.id = id
37538	return c
37539}
37540
37541// Fields allows partial responses to be retrieved. See
37542// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37543// for more information.
37544func (c *OrdersGetCall) Fields(s ...googleapi.Field) *OrdersGetCall {
37545	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37546	return c
37547}
37548
37549// IfNoneMatch sets the optional parameter which makes the operation
37550// fail if the object's ETag matches the given value. This is useful for
37551// getting updates only after the object has changed since the last
37552// request. Use googleapi.IsNotModified to check whether the response
37553// error from Do is the result of In-None-Match.
37554func (c *OrdersGetCall) IfNoneMatch(entityTag string) *OrdersGetCall {
37555	c.ifNoneMatch_ = entityTag
37556	return c
37557}
37558
37559// Context sets the context to be used in this call's Do method. Any
37560// pending HTTP request will be aborted if the provided context is
37561// canceled.
37562func (c *OrdersGetCall) Context(ctx context.Context) *OrdersGetCall {
37563	c.ctx_ = ctx
37564	return c
37565}
37566
37567// Header returns an http.Header that can be modified by the caller to
37568// add HTTP headers to the request.
37569func (c *OrdersGetCall) Header() http.Header {
37570	if c.header_ == nil {
37571		c.header_ = make(http.Header)
37572	}
37573	return c.header_
37574}
37575
37576func (c *OrdersGetCall) doRequest(alt string) (*http.Response, error) {
37577	reqHeaders := make(http.Header)
37578	for k, v := range c.header_ {
37579		reqHeaders[k] = v
37580	}
37581	reqHeaders.Set("User-Agent", c.s.userAgent())
37582	if c.ifNoneMatch_ != "" {
37583		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37584	}
37585	var body io.Reader = nil
37586	c.urlParams_.Set("alt", alt)
37587	c.urlParams_.Set("prettyPrint", "false")
37588	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orders/{id}")
37589	urls += "?" + c.urlParams_.Encode()
37590	req, err := http.NewRequest("GET", urls, body)
37591	if err != nil {
37592		return nil, err
37593	}
37594	req.Header = reqHeaders
37595	googleapi.Expand(req.URL, map[string]string{
37596		"profileId": strconv.FormatInt(c.profileId, 10),
37597		"projectId": strconv.FormatInt(c.projectId, 10),
37598		"id":        strconv.FormatInt(c.id, 10),
37599	})
37600	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37601}
37602
37603// Do executes the "dfareporting.orders.get" call.
37604// Exactly one of *Order or error will be non-nil. Any non-2xx status
37605// code is an error. Response headers are in either
37606// *Order.ServerResponse.Header or (if a response was returned at all)
37607// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
37608// check whether the returned error was because http.StatusNotModified
37609// was returned.
37610func (c *OrdersGetCall) Do(opts ...googleapi.CallOption) (*Order, error) {
37611	gensupport.SetOptions(c.urlParams_, opts...)
37612	res, err := c.doRequest("json")
37613	if res != nil && res.StatusCode == http.StatusNotModified {
37614		if res.Body != nil {
37615			res.Body.Close()
37616		}
37617		return nil, &googleapi.Error{
37618			Code:   res.StatusCode,
37619			Header: res.Header,
37620		}
37621	}
37622	if err != nil {
37623		return nil, err
37624	}
37625	defer googleapi.CloseBody(res)
37626	if err := googleapi.CheckResponse(res); err != nil {
37627		return nil, err
37628	}
37629	ret := &Order{
37630		ServerResponse: googleapi.ServerResponse{
37631			Header:         res.Header,
37632			HTTPStatusCode: res.StatusCode,
37633		},
37634	}
37635	target := &ret
37636	if err := gensupport.DecodeResponse(target, res); err != nil {
37637		return nil, err
37638	}
37639	return ret, nil
37640	// {
37641	//   "description": "Gets one order by ID.",
37642	//   "httpMethod": "GET",
37643	//   "id": "dfareporting.orders.get",
37644	//   "parameterOrder": [
37645	//     "profileId",
37646	//     "projectId",
37647	//     "id"
37648	//   ],
37649	//   "parameters": {
37650	//     "id": {
37651	//       "description": "Order ID.",
37652	//       "format": "int64",
37653	//       "location": "path",
37654	//       "required": true,
37655	//       "type": "string"
37656	//     },
37657	//     "profileId": {
37658	//       "description": "User profile ID associated with this request.",
37659	//       "format": "int64",
37660	//       "location": "path",
37661	//       "required": true,
37662	//       "type": "string"
37663	//     },
37664	//     "projectId": {
37665	//       "description": "Project ID for orders.",
37666	//       "format": "int64",
37667	//       "location": "path",
37668	//       "required": true,
37669	//       "type": "string"
37670	//     }
37671	//   },
37672	//   "path": "userprofiles/{profileId}/projects/{projectId}/orders/{id}",
37673	//   "response": {
37674	//     "$ref": "Order"
37675	//   },
37676	//   "scopes": [
37677	//     "https://www.googleapis.com/auth/dfatrafficking"
37678	//   ]
37679	// }
37680
37681}
37682
37683// method id "dfareporting.orders.list":
37684
37685type OrdersListCall struct {
37686	s            *Service
37687	profileId    int64
37688	projectId    int64
37689	urlParams_   gensupport.URLParams
37690	ifNoneMatch_ string
37691	ctx_         context.Context
37692	header_      http.Header
37693}
37694
37695// List: Retrieves a list of orders, possibly filtered. This method
37696// supports paging.
37697func (r *OrdersService) List(profileId int64, projectId int64) *OrdersListCall {
37698	c := &OrdersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37699	c.profileId = profileId
37700	c.projectId = projectId
37701	return c
37702}
37703
37704// Ids sets the optional parameter "ids": Select only orders with these
37705// IDs.
37706func (c *OrdersListCall) Ids(ids ...int64) *OrdersListCall {
37707	var ids_ []string
37708	for _, v := range ids {
37709		ids_ = append(ids_, fmt.Sprint(v))
37710	}
37711	c.urlParams_.SetMulti("ids", ids_)
37712	return c
37713}
37714
37715// MaxResults sets the optional parameter "maxResults": Maximum number
37716// of results to return.
37717func (c *OrdersListCall) MaxResults(maxResults int64) *OrdersListCall {
37718	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
37719	return c
37720}
37721
37722// PageToken sets the optional parameter "pageToken": Value of the
37723// nextPageToken from the previous result page.
37724func (c *OrdersListCall) PageToken(pageToken string) *OrdersListCall {
37725	c.urlParams_.Set("pageToken", pageToken)
37726	return c
37727}
37728
37729// SearchString sets the optional parameter "searchString": Allows
37730// searching for orders by name or ID. Wildcards (*) are allowed. For
37731// example, "order*2015" will return orders with names like "order June
37732// 2015", "order April 2015", or simply "order 2015". Most of the
37733// searches also add wildcards implicitly at the start and the end of
37734// the search string. For example, a search string of "order" will match
37735// orders with name "my order", "order 2015", or simply "order".
37736func (c *OrdersListCall) SearchString(searchString string) *OrdersListCall {
37737	c.urlParams_.Set("searchString", searchString)
37738	return c
37739}
37740
37741// SiteId sets the optional parameter "siteId": Select only orders that
37742// are associated with these site IDs.
37743func (c *OrdersListCall) SiteId(siteId ...int64) *OrdersListCall {
37744	var siteId_ []string
37745	for _, v := range siteId {
37746		siteId_ = append(siteId_, fmt.Sprint(v))
37747	}
37748	c.urlParams_.SetMulti("siteId", siteId_)
37749	return c
37750}
37751
37752// SortField sets the optional parameter "sortField": Field by which to
37753// sort the list.
37754//
37755// Possible values:
37756//   "ID" (default)
37757//   "NAME"
37758func (c *OrdersListCall) SortField(sortField string) *OrdersListCall {
37759	c.urlParams_.Set("sortField", sortField)
37760	return c
37761}
37762
37763// SortOrder sets the optional parameter "sortOrder": Order of sorted
37764// results.
37765//
37766// Possible values:
37767//   "ASCENDING" (default)
37768//   "DESCENDING"
37769func (c *OrdersListCall) SortOrder(sortOrder string) *OrdersListCall {
37770	c.urlParams_.Set("sortOrder", sortOrder)
37771	return c
37772}
37773
37774// Fields allows partial responses to be retrieved. See
37775// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37776// for more information.
37777func (c *OrdersListCall) Fields(s ...googleapi.Field) *OrdersListCall {
37778	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37779	return c
37780}
37781
37782// IfNoneMatch sets the optional parameter which makes the operation
37783// fail if the object's ETag matches the given value. This is useful for
37784// getting updates only after the object has changed since the last
37785// request. Use googleapi.IsNotModified to check whether the response
37786// error from Do is the result of In-None-Match.
37787func (c *OrdersListCall) IfNoneMatch(entityTag string) *OrdersListCall {
37788	c.ifNoneMatch_ = entityTag
37789	return c
37790}
37791
37792// Context sets the context to be used in this call's Do method. Any
37793// pending HTTP request will be aborted if the provided context is
37794// canceled.
37795func (c *OrdersListCall) Context(ctx context.Context) *OrdersListCall {
37796	c.ctx_ = ctx
37797	return c
37798}
37799
37800// Header returns an http.Header that can be modified by the caller to
37801// add HTTP headers to the request.
37802func (c *OrdersListCall) Header() http.Header {
37803	if c.header_ == nil {
37804		c.header_ = make(http.Header)
37805	}
37806	return c.header_
37807}
37808
37809func (c *OrdersListCall) doRequest(alt string) (*http.Response, error) {
37810	reqHeaders := make(http.Header)
37811	for k, v := range c.header_ {
37812		reqHeaders[k] = v
37813	}
37814	reqHeaders.Set("User-Agent", c.s.userAgent())
37815	if c.ifNoneMatch_ != "" {
37816		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37817	}
37818	var body io.Reader = nil
37819	c.urlParams_.Set("alt", alt)
37820	c.urlParams_.Set("prettyPrint", "false")
37821	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orders")
37822	urls += "?" + c.urlParams_.Encode()
37823	req, err := http.NewRequest("GET", urls, body)
37824	if err != nil {
37825		return nil, err
37826	}
37827	req.Header = reqHeaders
37828	googleapi.Expand(req.URL, map[string]string{
37829		"profileId": strconv.FormatInt(c.profileId, 10),
37830		"projectId": strconv.FormatInt(c.projectId, 10),
37831	})
37832	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37833}
37834
37835// Do executes the "dfareporting.orders.list" call.
37836// Exactly one of *OrdersListResponse or error will be non-nil. Any
37837// non-2xx status code is an error. Response headers are in either
37838// *OrdersListResponse.ServerResponse.Header or (if a response was
37839// returned at all) in error.(*googleapi.Error).Header. Use
37840// googleapi.IsNotModified to check whether the returned error was
37841// because http.StatusNotModified was returned.
37842func (c *OrdersListCall) Do(opts ...googleapi.CallOption) (*OrdersListResponse, error) {
37843	gensupport.SetOptions(c.urlParams_, opts...)
37844	res, err := c.doRequest("json")
37845	if res != nil && res.StatusCode == http.StatusNotModified {
37846		if res.Body != nil {
37847			res.Body.Close()
37848		}
37849		return nil, &googleapi.Error{
37850			Code:   res.StatusCode,
37851			Header: res.Header,
37852		}
37853	}
37854	if err != nil {
37855		return nil, err
37856	}
37857	defer googleapi.CloseBody(res)
37858	if err := googleapi.CheckResponse(res); err != nil {
37859		return nil, err
37860	}
37861	ret := &OrdersListResponse{
37862		ServerResponse: googleapi.ServerResponse{
37863			Header:         res.Header,
37864			HTTPStatusCode: res.StatusCode,
37865		},
37866	}
37867	target := &ret
37868	if err := gensupport.DecodeResponse(target, res); err != nil {
37869		return nil, err
37870	}
37871	return ret, nil
37872	// {
37873	//   "description": "Retrieves a list of orders, possibly filtered. This method supports paging.",
37874	//   "httpMethod": "GET",
37875	//   "id": "dfareporting.orders.list",
37876	//   "parameterOrder": [
37877	//     "profileId",
37878	//     "projectId"
37879	//   ],
37880	//   "parameters": {
37881	//     "ids": {
37882	//       "description": "Select only orders with these IDs.",
37883	//       "format": "int64",
37884	//       "location": "query",
37885	//       "repeated": true,
37886	//       "type": "string"
37887	//     },
37888	//     "maxResults": {
37889	//       "default": "1000",
37890	//       "description": "Maximum number of results to return.",
37891	//       "format": "int32",
37892	//       "location": "query",
37893	//       "maximum": "1000",
37894	//       "minimum": "0",
37895	//       "type": "integer"
37896	//     },
37897	//     "pageToken": {
37898	//       "description": "Value of the nextPageToken from the previous result page.",
37899	//       "location": "query",
37900	//       "type": "string"
37901	//     },
37902	//     "profileId": {
37903	//       "description": "User profile ID associated with this request.",
37904	//       "format": "int64",
37905	//       "location": "path",
37906	//       "required": true,
37907	//       "type": "string"
37908	//     },
37909	//     "projectId": {
37910	//       "description": "Project ID for orders.",
37911	//       "format": "int64",
37912	//       "location": "path",
37913	//       "required": true,
37914	//       "type": "string"
37915	//     },
37916	//     "searchString": {
37917	//       "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\".",
37918	//       "location": "query",
37919	//       "type": "string"
37920	//     },
37921	//     "siteId": {
37922	//       "description": "Select only orders that are associated with these site IDs.",
37923	//       "format": "int64",
37924	//       "location": "query",
37925	//       "repeated": true,
37926	//       "type": "string"
37927	//     },
37928	//     "sortField": {
37929	//       "default": "ID",
37930	//       "description": "Field by which to sort the list.",
37931	//       "enum": [
37932	//         "ID",
37933	//         "NAME"
37934	//       ],
37935	//       "enumDescriptions": [
37936	//         "",
37937	//         ""
37938	//       ],
37939	//       "location": "query",
37940	//       "type": "string"
37941	//     },
37942	//     "sortOrder": {
37943	//       "default": "ASCENDING",
37944	//       "description": "Order of sorted results.",
37945	//       "enum": [
37946	//         "ASCENDING",
37947	//         "DESCENDING"
37948	//       ],
37949	//       "enumDescriptions": [
37950	//         "",
37951	//         ""
37952	//       ],
37953	//       "location": "query",
37954	//       "type": "string"
37955	//     }
37956	//   },
37957	//   "path": "userprofiles/{profileId}/projects/{projectId}/orders",
37958	//   "response": {
37959	//     "$ref": "OrdersListResponse"
37960	//   },
37961	//   "scopes": [
37962	//     "https://www.googleapis.com/auth/dfatrafficking"
37963	//   ]
37964	// }
37965
37966}
37967
37968// Pages invokes f for each page of results.
37969// A non-nil error returned from f will halt the iteration.
37970// The provided context supersedes any context provided to the Context method.
37971func (c *OrdersListCall) Pages(ctx context.Context, f func(*OrdersListResponse) error) error {
37972	c.ctx_ = ctx
37973	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
37974	for {
37975		x, err := c.Do()
37976		if err != nil {
37977			return err
37978		}
37979		if err := f(x); err != nil {
37980			return err
37981		}
37982		if x.NextPageToken == "" {
37983			return nil
37984		}
37985		c.PageToken(x.NextPageToken)
37986	}
37987}
37988
37989// method id "dfareporting.placementGroups.get":
37990
37991type PlacementGroupsGetCall struct {
37992	s            *Service
37993	profileId    int64
37994	id           int64
37995	urlParams_   gensupport.URLParams
37996	ifNoneMatch_ string
37997	ctx_         context.Context
37998	header_      http.Header
37999}
38000
38001// Get: Gets one placement group by ID.
38002func (r *PlacementGroupsService) Get(profileId int64, id int64) *PlacementGroupsGetCall {
38003	c := &PlacementGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38004	c.profileId = profileId
38005	c.id = id
38006	return c
38007}
38008
38009// Fields allows partial responses to be retrieved. See
38010// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38011// for more information.
38012func (c *PlacementGroupsGetCall) Fields(s ...googleapi.Field) *PlacementGroupsGetCall {
38013	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38014	return c
38015}
38016
38017// IfNoneMatch sets the optional parameter which makes the operation
38018// fail if the object's ETag matches the given value. This is useful for
38019// getting updates only after the object has changed since the last
38020// request. Use googleapi.IsNotModified to check whether the response
38021// error from Do is the result of In-None-Match.
38022func (c *PlacementGroupsGetCall) IfNoneMatch(entityTag string) *PlacementGroupsGetCall {
38023	c.ifNoneMatch_ = entityTag
38024	return c
38025}
38026
38027// Context sets the context to be used in this call's Do method. Any
38028// pending HTTP request will be aborted if the provided context is
38029// canceled.
38030func (c *PlacementGroupsGetCall) Context(ctx context.Context) *PlacementGroupsGetCall {
38031	c.ctx_ = ctx
38032	return c
38033}
38034
38035// Header returns an http.Header that can be modified by the caller to
38036// add HTTP headers to the request.
38037func (c *PlacementGroupsGetCall) Header() http.Header {
38038	if c.header_ == nil {
38039		c.header_ = make(http.Header)
38040	}
38041	return c.header_
38042}
38043
38044func (c *PlacementGroupsGetCall) doRequest(alt string) (*http.Response, error) {
38045	reqHeaders := make(http.Header)
38046	for k, v := range c.header_ {
38047		reqHeaders[k] = v
38048	}
38049	reqHeaders.Set("User-Agent", c.s.userAgent())
38050	if c.ifNoneMatch_ != "" {
38051		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38052	}
38053	var body io.Reader = nil
38054	c.urlParams_.Set("alt", alt)
38055	c.urlParams_.Set("prettyPrint", "false")
38056	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups/{id}")
38057	urls += "?" + c.urlParams_.Encode()
38058	req, err := http.NewRequest("GET", urls, body)
38059	if err != nil {
38060		return nil, err
38061	}
38062	req.Header = reqHeaders
38063	googleapi.Expand(req.URL, map[string]string{
38064		"profileId": strconv.FormatInt(c.profileId, 10),
38065		"id":        strconv.FormatInt(c.id, 10),
38066	})
38067	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38068}
38069
38070// Do executes the "dfareporting.placementGroups.get" call.
38071// Exactly one of *PlacementGroup or error will be non-nil. Any non-2xx
38072// status code is an error. Response headers are in either
38073// *PlacementGroup.ServerResponse.Header or (if a response was returned
38074// at all) in error.(*googleapi.Error).Header. Use
38075// googleapi.IsNotModified to check whether the returned error was
38076// because http.StatusNotModified was returned.
38077func (c *PlacementGroupsGetCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
38078	gensupport.SetOptions(c.urlParams_, opts...)
38079	res, err := c.doRequest("json")
38080	if res != nil && res.StatusCode == http.StatusNotModified {
38081		if res.Body != nil {
38082			res.Body.Close()
38083		}
38084		return nil, &googleapi.Error{
38085			Code:   res.StatusCode,
38086			Header: res.Header,
38087		}
38088	}
38089	if err != nil {
38090		return nil, err
38091	}
38092	defer googleapi.CloseBody(res)
38093	if err := googleapi.CheckResponse(res); err != nil {
38094		return nil, err
38095	}
38096	ret := &PlacementGroup{
38097		ServerResponse: googleapi.ServerResponse{
38098			Header:         res.Header,
38099			HTTPStatusCode: res.StatusCode,
38100		},
38101	}
38102	target := &ret
38103	if err := gensupport.DecodeResponse(target, res); err != nil {
38104		return nil, err
38105	}
38106	return ret, nil
38107	// {
38108	//   "description": "Gets one placement group by ID.",
38109	//   "httpMethod": "GET",
38110	//   "id": "dfareporting.placementGroups.get",
38111	//   "parameterOrder": [
38112	//     "profileId",
38113	//     "id"
38114	//   ],
38115	//   "parameters": {
38116	//     "id": {
38117	//       "description": "Placement group ID.",
38118	//       "format": "int64",
38119	//       "location": "path",
38120	//       "required": true,
38121	//       "type": "string"
38122	//     },
38123	//     "profileId": {
38124	//       "description": "User profile ID associated with this request.",
38125	//       "format": "int64",
38126	//       "location": "path",
38127	//       "required": true,
38128	//       "type": "string"
38129	//     }
38130	//   },
38131	//   "path": "userprofiles/{profileId}/placementGroups/{id}",
38132	//   "response": {
38133	//     "$ref": "PlacementGroup"
38134	//   },
38135	//   "scopes": [
38136	//     "https://www.googleapis.com/auth/dfatrafficking"
38137	//   ]
38138	// }
38139
38140}
38141
38142// method id "dfareporting.placementGroups.insert":
38143
38144type PlacementGroupsInsertCall struct {
38145	s              *Service
38146	profileId      int64
38147	placementgroup *PlacementGroup
38148	urlParams_     gensupport.URLParams
38149	ctx_           context.Context
38150	header_        http.Header
38151}
38152
38153// Insert: Inserts a new placement group.
38154func (r *PlacementGroupsService) Insert(profileId int64, placementgroup *PlacementGroup) *PlacementGroupsInsertCall {
38155	c := &PlacementGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38156	c.profileId = profileId
38157	c.placementgroup = placementgroup
38158	return c
38159}
38160
38161// Fields allows partial responses to be retrieved. See
38162// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38163// for more information.
38164func (c *PlacementGroupsInsertCall) Fields(s ...googleapi.Field) *PlacementGroupsInsertCall {
38165	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38166	return c
38167}
38168
38169// Context sets the context to be used in this call's Do method. Any
38170// pending HTTP request will be aborted if the provided context is
38171// canceled.
38172func (c *PlacementGroupsInsertCall) Context(ctx context.Context) *PlacementGroupsInsertCall {
38173	c.ctx_ = ctx
38174	return c
38175}
38176
38177// Header returns an http.Header that can be modified by the caller to
38178// add HTTP headers to the request.
38179func (c *PlacementGroupsInsertCall) Header() http.Header {
38180	if c.header_ == nil {
38181		c.header_ = make(http.Header)
38182	}
38183	return c.header_
38184}
38185
38186func (c *PlacementGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
38187	reqHeaders := make(http.Header)
38188	for k, v := range c.header_ {
38189		reqHeaders[k] = v
38190	}
38191	reqHeaders.Set("User-Agent", c.s.userAgent())
38192	var body io.Reader = nil
38193	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
38194	if err != nil {
38195		return nil, err
38196	}
38197	reqHeaders.Set("Content-Type", "application/json")
38198	c.urlParams_.Set("alt", alt)
38199	c.urlParams_.Set("prettyPrint", "false")
38200	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
38201	urls += "?" + c.urlParams_.Encode()
38202	req, err := http.NewRequest("POST", urls, body)
38203	if err != nil {
38204		return nil, err
38205	}
38206	req.Header = reqHeaders
38207	googleapi.Expand(req.URL, map[string]string{
38208		"profileId": strconv.FormatInt(c.profileId, 10),
38209	})
38210	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38211}
38212
38213// Do executes the "dfareporting.placementGroups.insert" call.
38214// Exactly one of *PlacementGroup or error will be non-nil. Any non-2xx
38215// status code is an error. Response headers are in either
38216// *PlacementGroup.ServerResponse.Header or (if a response was returned
38217// at all) in error.(*googleapi.Error).Header. Use
38218// googleapi.IsNotModified to check whether the returned error was
38219// because http.StatusNotModified was returned.
38220func (c *PlacementGroupsInsertCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
38221	gensupport.SetOptions(c.urlParams_, opts...)
38222	res, err := c.doRequest("json")
38223	if res != nil && res.StatusCode == http.StatusNotModified {
38224		if res.Body != nil {
38225			res.Body.Close()
38226		}
38227		return nil, &googleapi.Error{
38228			Code:   res.StatusCode,
38229			Header: res.Header,
38230		}
38231	}
38232	if err != nil {
38233		return nil, err
38234	}
38235	defer googleapi.CloseBody(res)
38236	if err := googleapi.CheckResponse(res); err != nil {
38237		return nil, err
38238	}
38239	ret := &PlacementGroup{
38240		ServerResponse: googleapi.ServerResponse{
38241			Header:         res.Header,
38242			HTTPStatusCode: res.StatusCode,
38243		},
38244	}
38245	target := &ret
38246	if err := gensupport.DecodeResponse(target, res); err != nil {
38247		return nil, err
38248	}
38249	return ret, nil
38250	// {
38251	//   "description": "Inserts a new placement group.",
38252	//   "httpMethod": "POST",
38253	//   "id": "dfareporting.placementGroups.insert",
38254	//   "parameterOrder": [
38255	//     "profileId"
38256	//   ],
38257	//   "parameters": {
38258	//     "profileId": {
38259	//       "description": "User profile ID associated with this request.",
38260	//       "format": "int64",
38261	//       "location": "path",
38262	//       "required": true,
38263	//       "type": "string"
38264	//     }
38265	//   },
38266	//   "path": "userprofiles/{profileId}/placementGroups",
38267	//   "request": {
38268	//     "$ref": "PlacementGroup"
38269	//   },
38270	//   "response": {
38271	//     "$ref": "PlacementGroup"
38272	//   },
38273	//   "scopes": [
38274	//     "https://www.googleapis.com/auth/dfatrafficking"
38275	//   ]
38276	// }
38277
38278}
38279
38280// method id "dfareporting.placementGroups.list":
38281
38282type PlacementGroupsListCall struct {
38283	s            *Service
38284	profileId    int64
38285	urlParams_   gensupport.URLParams
38286	ifNoneMatch_ string
38287	ctx_         context.Context
38288	header_      http.Header
38289}
38290
38291// List: Retrieves a list of placement groups, possibly filtered. This
38292// method supports paging.
38293func (r *PlacementGroupsService) List(profileId int64) *PlacementGroupsListCall {
38294	c := &PlacementGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38295	c.profileId = profileId
38296	return c
38297}
38298
38299// AdvertiserIds sets the optional parameter "advertiserIds": Select
38300// only placement groups that belong to these advertisers.
38301func (c *PlacementGroupsListCall) AdvertiserIds(advertiserIds ...int64) *PlacementGroupsListCall {
38302	var advertiserIds_ []string
38303	for _, v := range advertiserIds {
38304		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
38305	}
38306	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
38307	return c
38308}
38309
38310// Archived sets the optional parameter "archived": Select only archived
38311// placements. Don't set this field to select both archived and
38312// non-archived placements.
38313func (c *PlacementGroupsListCall) Archived(archived bool) *PlacementGroupsListCall {
38314	c.urlParams_.Set("archived", fmt.Sprint(archived))
38315	return c
38316}
38317
38318// CampaignIds sets the optional parameter "campaignIds": Select only
38319// placement groups that belong to these campaigns.
38320func (c *PlacementGroupsListCall) CampaignIds(campaignIds ...int64) *PlacementGroupsListCall {
38321	var campaignIds_ []string
38322	for _, v := range campaignIds {
38323		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
38324	}
38325	c.urlParams_.SetMulti("campaignIds", campaignIds_)
38326	return c
38327}
38328
38329// ContentCategoryIds sets the optional parameter "contentCategoryIds":
38330// Select only placement groups that are associated with these content
38331// categories.
38332func (c *PlacementGroupsListCall) ContentCategoryIds(contentCategoryIds ...int64) *PlacementGroupsListCall {
38333	var contentCategoryIds_ []string
38334	for _, v := range contentCategoryIds {
38335		contentCategoryIds_ = append(contentCategoryIds_, fmt.Sprint(v))
38336	}
38337	c.urlParams_.SetMulti("contentCategoryIds", contentCategoryIds_)
38338	return c
38339}
38340
38341// DirectorySiteIds sets the optional parameter "directorySiteIds":
38342// Select only placement groups that are associated with these directory
38343// sites.
38344func (c *PlacementGroupsListCall) DirectorySiteIds(directorySiteIds ...int64) *PlacementGroupsListCall {
38345	var directorySiteIds_ []string
38346	for _, v := range directorySiteIds {
38347		directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
38348	}
38349	c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
38350	return c
38351}
38352
38353// Ids sets the optional parameter "ids": Select only placement groups
38354// with these IDs.
38355func (c *PlacementGroupsListCall) Ids(ids ...int64) *PlacementGroupsListCall {
38356	var ids_ []string
38357	for _, v := range ids {
38358		ids_ = append(ids_, fmt.Sprint(v))
38359	}
38360	c.urlParams_.SetMulti("ids", ids_)
38361	return c
38362}
38363
38364// MaxEndDate sets the optional parameter "maxEndDate": Select only
38365// placements or placement groups whose end date is on or before the
38366// specified maxEndDate. The date should be formatted as "yyyy-MM-dd".
38367func (c *PlacementGroupsListCall) MaxEndDate(maxEndDate string) *PlacementGroupsListCall {
38368	c.urlParams_.Set("maxEndDate", maxEndDate)
38369	return c
38370}
38371
38372// MaxResults sets the optional parameter "maxResults": Maximum number
38373// of results to return.
38374func (c *PlacementGroupsListCall) MaxResults(maxResults int64) *PlacementGroupsListCall {
38375	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
38376	return c
38377}
38378
38379// MaxStartDate sets the optional parameter "maxStartDate": Select only
38380// placements or placement groups whose start date is on or before the
38381// specified maxStartDate. The date should be formatted as "yyyy-MM-dd".
38382func (c *PlacementGroupsListCall) MaxStartDate(maxStartDate string) *PlacementGroupsListCall {
38383	c.urlParams_.Set("maxStartDate", maxStartDate)
38384	return c
38385}
38386
38387// MinEndDate sets the optional parameter "minEndDate": Select only
38388// placements or placement groups whose end date is on or after the
38389// specified minEndDate. The date should be formatted as "yyyy-MM-dd".
38390func (c *PlacementGroupsListCall) MinEndDate(minEndDate string) *PlacementGroupsListCall {
38391	c.urlParams_.Set("minEndDate", minEndDate)
38392	return c
38393}
38394
38395// MinStartDate sets the optional parameter "minStartDate": Select only
38396// placements or placement groups whose start date is on or after the
38397// specified minStartDate. The date should be formatted as "yyyy-MM-dd".
38398func (c *PlacementGroupsListCall) MinStartDate(minStartDate string) *PlacementGroupsListCall {
38399	c.urlParams_.Set("minStartDate", minStartDate)
38400	return c
38401}
38402
38403// PageToken sets the optional parameter "pageToken": Value of the
38404// nextPageToken from the previous result page.
38405func (c *PlacementGroupsListCall) PageToken(pageToken string) *PlacementGroupsListCall {
38406	c.urlParams_.Set("pageToken", pageToken)
38407	return c
38408}
38409
38410// PlacementGroupType sets the optional parameter "placementGroupType":
38411// Select only placement groups belonging with this group type. A
38412// package is a simple group of placements that acts as a single pricing
38413// point for a group of tags. A roadblock is a group of placements that
38414// not only acts as a single pricing point but also assumes that all the
38415// tags in it will be served at the same time. A roadblock requires one
38416// of its assigned placements to be marked as primary for reporting.
38417//
38418// Possible values:
38419//   "PLACEMENT_PACKAGE"
38420//   "PLACEMENT_ROADBLOCK"
38421func (c *PlacementGroupsListCall) PlacementGroupType(placementGroupType string) *PlacementGroupsListCall {
38422	c.urlParams_.Set("placementGroupType", placementGroupType)
38423	return c
38424}
38425
38426// PlacementStrategyIds sets the optional parameter
38427// "placementStrategyIds": Select only placement groups that are
38428// associated with these placement strategies.
38429func (c *PlacementGroupsListCall) PlacementStrategyIds(placementStrategyIds ...int64) *PlacementGroupsListCall {
38430	var placementStrategyIds_ []string
38431	for _, v := range placementStrategyIds {
38432		placementStrategyIds_ = append(placementStrategyIds_, fmt.Sprint(v))
38433	}
38434	c.urlParams_.SetMulti("placementStrategyIds", placementStrategyIds_)
38435	return c
38436}
38437
38438// PricingTypes sets the optional parameter "pricingTypes": Select only
38439// placement groups with these pricing types.
38440//
38441// Possible values:
38442//   "PRICING_TYPE_CPA"
38443//   "PRICING_TYPE_CPC"
38444//   "PRICING_TYPE_CPM"
38445//   "PRICING_TYPE_CPM_ACTIVEVIEW"
38446//   "PRICING_TYPE_FLAT_RATE_CLICKS"
38447//   "PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
38448func (c *PlacementGroupsListCall) PricingTypes(pricingTypes ...string) *PlacementGroupsListCall {
38449	c.urlParams_.SetMulti("pricingTypes", append([]string{}, pricingTypes...))
38450	return c
38451}
38452
38453// SearchString sets the optional parameter "searchString": Allows
38454// searching for placement groups by name or ID. Wildcards (*) are
38455// allowed. For example, "placement*2015" will return placement groups
38456// with names like "placement group June 2015", "placement group May
38457// 2015", or simply "placements 2015". Most of the searches also add
38458// wildcards implicitly at the start and the end of the search string.
38459// For example, a search string of "placementgroup" will match placement
38460// groups with name "my placementgroup", "placementgroup 2015", or
38461// simply "placementgroup".
38462func (c *PlacementGroupsListCall) SearchString(searchString string) *PlacementGroupsListCall {
38463	c.urlParams_.Set("searchString", searchString)
38464	return c
38465}
38466
38467// SiteIds sets the optional parameter "siteIds": Select only placement
38468// groups that are associated with these sites.
38469func (c *PlacementGroupsListCall) SiteIds(siteIds ...int64) *PlacementGroupsListCall {
38470	var siteIds_ []string
38471	for _, v := range siteIds {
38472		siteIds_ = append(siteIds_, fmt.Sprint(v))
38473	}
38474	c.urlParams_.SetMulti("siteIds", siteIds_)
38475	return c
38476}
38477
38478// SortField sets the optional parameter "sortField": Field by which to
38479// sort the list.
38480//
38481// Possible values:
38482//   "ID" (default)
38483//   "NAME"
38484func (c *PlacementGroupsListCall) SortField(sortField string) *PlacementGroupsListCall {
38485	c.urlParams_.Set("sortField", sortField)
38486	return c
38487}
38488
38489// SortOrder sets the optional parameter "sortOrder": Order of sorted
38490// results.
38491//
38492// Possible values:
38493//   "ASCENDING" (default)
38494//   "DESCENDING"
38495func (c *PlacementGroupsListCall) SortOrder(sortOrder string) *PlacementGroupsListCall {
38496	c.urlParams_.Set("sortOrder", sortOrder)
38497	return c
38498}
38499
38500// Fields allows partial responses to be retrieved. See
38501// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38502// for more information.
38503func (c *PlacementGroupsListCall) Fields(s ...googleapi.Field) *PlacementGroupsListCall {
38504	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38505	return c
38506}
38507
38508// IfNoneMatch sets the optional parameter which makes the operation
38509// fail if the object's ETag matches the given value. This is useful for
38510// getting updates only after the object has changed since the last
38511// request. Use googleapi.IsNotModified to check whether the response
38512// error from Do is the result of In-None-Match.
38513func (c *PlacementGroupsListCall) IfNoneMatch(entityTag string) *PlacementGroupsListCall {
38514	c.ifNoneMatch_ = entityTag
38515	return c
38516}
38517
38518// Context sets the context to be used in this call's Do method. Any
38519// pending HTTP request will be aborted if the provided context is
38520// canceled.
38521func (c *PlacementGroupsListCall) Context(ctx context.Context) *PlacementGroupsListCall {
38522	c.ctx_ = ctx
38523	return c
38524}
38525
38526// Header returns an http.Header that can be modified by the caller to
38527// add HTTP headers to the request.
38528func (c *PlacementGroupsListCall) Header() http.Header {
38529	if c.header_ == nil {
38530		c.header_ = make(http.Header)
38531	}
38532	return c.header_
38533}
38534
38535func (c *PlacementGroupsListCall) doRequest(alt string) (*http.Response, error) {
38536	reqHeaders := make(http.Header)
38537	for k, v := range c.header_ {
38538		reqHeaders[k] = v
38539	}
38540	reqHeaders.Set("User-Agent", c.s.userAgent())
38541	if c.ifNoneMatch_ != "" {
38542		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38543	}
38544	var body io.Reader = nil
38545	c.urlParams_.Set("alt", alt)
38546	c.urlParams_.Set("prettyPrint", "false")
38547	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
38548	urls += "?" + c.urlParams_.Encode()
38549	req, err := http.NewRequest("GET", urls, body)
38550	if err != nil {
38551		return nil, err
38552	}
38553	req.Header = reqHeaders
38554	googleapi.Expand(req.URL, map[string]string{
38555		"profileId": strconv.FormatInt(c.profileId, 10),
38556	})
38557	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38558}
38559
38560// Do executes the "dfareporting.placementGroups.list" call.
38561// Exactly one of *PlacementGroupsListResponse or error will be non-nil.
38562// Any non-2xx status code is an error. Response headers are in either
38563// *PlacementGroupsListResponse.ServerResponse.Header or (if a response
38564// was returned at all) in error.(*googleapi.Error).Header. Use
38565// googleapi.IsNotModified to check whether the returned error was
38566// because http.StatusNotModified was returned.
38567func (c *PlacementGroupsListCall) Do(opts ...googleapi.CallOption) (*PlacementGroupsListResponse, error) {
38568	gensupport.SetOptions(c.urlParams_, opts...)
38569	res, err := c.doRequest("json")
38570	if res != nil && res.StatusCode == http.StatusNotModified {
38571		if res.Body != nil {
38572			res.Body.Close()
38573		}
38574		return nil, &googleapi.Error{
38575			Code:   res.StatusCode,
38576			Header: res.Header,
38577		}
38578	}
38579	if err != nil {
38580		return nil, err
38581	}
38582	defer googleapi.CloseBody(res)
38583	if err := googleapi.CheckResponse(res); err != nil {
38584		return nil, err
38585	}
38586	ret := &PlacementGroupsListResponse{
38587		ServerResponse: googleapi.ServerResponse{
38588			Header:         res.Header,
38589			HTTPStatusCode: res.StatusCode,
38590		},
38591	}
38592	target := &ret
38593	if err := gensupport.DecodeResponse(target, res); err != nil {
38594		return nil, err
38595	}
38596	return ret, nil
38597	// {
38598	//   "description": "Retrieves a list of placement groups, possibly filtered. This method supports paging.",
38599	//   "httpMethod": "GET",
38600	//   "id": "dfareporting.placementGroups.list",
38601	//   "parameterOrder": [
38602	//     "profileId"
38603	//   ],
38604	//   "parameters": {
38605	//     "advertiserIds": {
38606	//       "description": "Select only placement groups that belong to these advertisers.",
38607	//       "format": "int64",
38608	//       "location": "query",
38609	//       "repeated": true,
38610	//       "type": "string"
38611	//     },
38612	//     "archived": {
38613	//       "description": "Select only archived placements. Don't set this field to select both archived and non-archived placements.",
38614	//       "location": "query",
38615	//       "type": "boolean"
38616	//     },
38617	//     "campaignIds": {
38618	//       "description": "Select only placement groups that belong to these campaigns.",
38619	//       "format": "int64",
38620	//       "location": "query",
38621	//       "repeated": true,
38622	//       "type": "string"
38623	//     },
38624	//     "contentCategoryIds": {
38625	//       "description": "Select only placement groups that are associated with these content categories.",
38626	//       "format": "int64",
38627	//       "location": "query",
38628	//       "repeated": true,
38629	//       "type": "string"
38630	//     },
38631	//     "directorySiteIds": {
38632	//       "description": "Select only placement groups that are associated with these directory sites.",
38633	//       "format": "int64",
38634	//       "location": "query",
38635	//       "repeated": true,
38636	//       "type": "string"
38637	//     },
38638	//     "ids": {
38639	//       "description": "Select only placement groups with these IDs.",
38640	//       "format": "int64",
38641	//       "location": "query",
38642	//       "repeated": true,
38643	//       "type": "string"
38644	//     },
38645	//     "maxEndDate": {
38646	//       "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\".",
38647	//       "location": "query",
38648	//       "type": "string"
38649	//     },
38650	//     "maxResults": {
38651	//       "default": "800",
38652	//       "description": "Maximum number of results to return.",
38653	//       "format": "int32",
38654	//       "location": "query",
38655	//       "maximum": "800",
38656	//       "minimum": "0",
38657	//       "type": "integer"
38658	//     },
38659	//     "maxStartDate": {
38660	//       "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\".",
38661	//       "location": "query",
38662	//       "type": "string"
38663	//     },
38664	//     "minEndDate": {
38665	//       "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\".",
38666	//       "location": "query",
38667	//       "type": "string"
38668	//     },
38669	//     "minStartDate": {
38670	//       "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\".",
38671	//       "location": "query",
38672	//       "type": "string"
38673	//     },
38674	//     "pageToken": {
38675	//       "description": "Value of the nextPageToken from the previous result page.",
38676	//       "location": "query",
38677	//       "type": "string"
38678	//     },
38679	//     "placementGroupType": {
38680	//       "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.",
38681	//       "enum": [
38682	//         "PLACEMENT_PACKAGE",
38683	//         "PLACEMENT_ROADBLOCK"
38684	//       ],
38685	//       "enumDescriptions": [
38686	//         "",
38687	//         ""
38688	//       ],
38689	//       "location": "query",
38690	//       "type": "string"
38691	//     },
38692	//     "placementStrategyIds": {
38693	//       "description": "Select only placement groups that are associated with these placement strategies.",
38694	//       "format": "int64",
38695	//       "location": "query",
38696	//       "repeated": true,
38697	//       "type": "string"
38698	//     },
38699	//     "pricingTypes": {
38700	//       "description": "Select only placement groups with these pricing types.",
38701	//       "enum": [
38702	//         "PRICING_TYPE_CPA",
38703	//         "PRICING_TYPE_CPC",
38704	//         "PRICING_TYPE_CPM",
38705	//         "PRICING_TYPE_CPM_ACTIVEVIEW",
38706	//         "PRICING_TYPE_FLAT_RATE_CLICKS",
38707	//         "PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
38708	//       ],
38709	//       "enumDescriptions": [
38710	//         "",
38711	//         "",
38712	//         "",
38713	//         "",
38714	//         "",
38715	//         ""
38716	//       ],
38717	//       "location": "query",
38718	//       "repeated": true,
38719	//       "type": "string"
38720	//     },
38721	//     "profileId": {
38722	//       "description": "User profile ID associated with this request.",
38723	//       "format": "int64",
38724	//       "location": "path",
38725	//       "required": true,
38726	//       "type": "string"
38727	//     },
38728	//     "searchString": {
38729	//       "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\".",
38730	//       "location": "query",
38731	//       "type": "string"
38732	//     },
38733	//     "siteIds": {
38734	//       "description": "Select only placement groups that are associated with these sites.",
38735	//       "format": "int64",
38736	//       "location": "query",
38737	//       "repeated": true,
38738	//       "type": "string"
38739	//     },
38740	//     "sortField": {
38741	//       "default": "ID",
38742	//       "description": "Field by which to sort the list.",
38743	//       "enum": [
38744	//         "ID",
38745	//         "NAME"
38746	//       ],
38747	//       "enumDescriptions": [
38748	//         "",
38749	//         ""
38750	//       ],
38751	//       "location": "query",
38752	//       "type": "string"
38753	//     },
38754	//     "sortOrder": {
38755	//       "default": "ASCENDING",
38756	//       "description": "Order of sorted results.",
38757	//       "enum": [
38758	//         "ASCENDING",
38759	//         "DESCENDING"
38760	//       ],
38761	//       "enumDescriptions": [
38762	//         "",
38763	//         ""
38764	//       ],
38765	//       "location": "query",
38766	//       "type": "string"
38767	//     }
38768	//   },
38769	//   "path": "userprofiles/{profileId}/placementGroups",
38770	//   "response": {
38771	//     "$ref": "PlacementGroupsListResponse"
38772	//   },
38773	//   "scopes": [
38774	//     "https://www.googleapis.com/auth/dfatrafficking"
38775	//   ]
38776	// }
38777
38778}
38779
38780// Pages invokes f for each page of results.
38781// A non-nil error returned from f will halt the iteration.
38782// The provided context supersedes any context provided to the Context method.
38783func (c *PlacementGroupsListCall) Pages(ctx context.Context, f func(*PlacementGroupsListResponse) error) error {
38784	c.ctx_ = ctx
38785	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
38786	for {
38787		x, err := c.Do()
38788		if err != nil {
38789			return err
38790		}
38791		if err := f(x); err != nil {
38792			return err
38793		}
38794		if x.NextPageToken == "" {
38795			return nil
38796		}
38797		c.PageToken(x.NextPageToken)
38798	}
38799}
38800
38801// method id "dfareporting.placementGroups.patch":
38802
38803type PlacementGroupsPatchCall struct {
38804	s              *Service
38805	profileId      int64
38806	placementgroup *PlacementGroup
38807	urlParams_     gensupport.URLParams
38808	ctx_           context.Context
38809	header_        http.Header
38810}
38811
38812// Patch: Updates an existing placement group. This method supports
38813// patch semantics.
38814func (r *PlacementGroupsService) Patch(profileId int64, id int64, placementgroup *PlacementGroup) *PlacementGroupsPatchCall {
38815	c := &PlacementGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38816	c.profileId = profileId
38817	c.urlParams_.Set("id", fmt.Sprint(id))
38818	c.placementgroup = placementgroup
38819	return c
38820}
38821
38822// Fields allows partial responses to be retrieved. See
38823// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38824// for more information.
38825func (c *PlacementGroupsPatchCall) Fields(s ...googleapi.Field) *PlacementGroupsPatchCall {
38826	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38827	return c
38828}
38829
38830// Context sets the context to be used in this call's Do method. Any
38831// pending HTTP request will be aborted if the provided context is
38832// canceled.
38833func (c *PlacementGroupsPatchCall) Context(ctx context.Context) *PlacementGroupsPatchCall {
38834	c.ctx_ = ctx
38835	return c
38836}
38837
38838// Header returns an http.Header that can be modified by the caller to
38839// add HTTP headers to the request.
38840func (c *PlacementGroupsPatchCall) Header() http.Header {
38841	if c.header_ == nil {
38842		c.header_ = make(http.Header)
38843	}
38844	return c.header_
38845}
38846
38847func (c *PlacementGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
38848	reqHeaders := make(http.Header)
38849	for k, v := range c.header_ {
38850		reqHeaders[k] = v
38851	}
38852	reqHeaders.Set("User-Agent", c.s.userAgent())
38853	var body io.Reader = nil
38854	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
38855	if err != nil {
38856		return nil, err
38857	}
38858	reqHeaders.Set("Content-Type", "application/json")
38859	c.urlParams_.Set("alt", alt)
38860	c.urlParams_.Set("prettyPrint", "false")
38861	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
38862	urls += "?" + c.urlParams_.Encode()
38863	req, err := http.NewRequest("PATCH", urls, body)
38864	if err != nil {
38865		return nil, err
38866	}
38867	req.Header = reqHeaders
38868	googleapi.Expand(req.URL, map[string]string{
38869		"profileId": strconv.FormatInt(c.profileId, 10),
38870	})
38871	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38872}
38873
38874// Do executes the "dfareporting.placementGroups.patch" call.
38875// Exactly one of *PlacementGroup or error will be non-nil. Any non-2xx
38876// status code is an error. Response headers are in either
38877// *PlacementGroup.ServerResponse.Header or (if a response was returned
38878// at all) in error.(*googleapi.Error).Header. Use
38879// googleapi.IsNotModified to check whether the returned error was
38880// because http.StatusNotModified was returned.
38881func (c *PlacementGroupsPatchCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
38882	gensupport.SetOptions(c.urlParams_, opts...)
38883	res, err := c.doRequest("json")
38884	if res != nil && res.StatusCode == http.StatusNotModified {
38885		if res.Body != nil {
38886			res.Body.Close()
38887		}
38888		return nil, &googleapi.Error{
38889			Code:   res.StatusCode,
38890			Header: res.Header,
38891		}
38892	}
38893	if err != nil {
38894		return nil, err
38895	}
38896	defer googleapi.CloseBody(res)
38897	if err := googleapi.CheckResponse(res); err != nil {
38898		return nil, err
38899	}
38900	ret := &PlacementGroup{
38901		ServerResponse: googleapi.ServerResponse{
38902			Header:         res.Header,
38903			HTTPStatusCode: res.StatusCode,
38904		},
38905	}
38906	target := &ret
38907	if err := gensupport.DecodeResponse(target, res); err != nil {
38908		return nil, err
38909	}
38910	return ret, nil
38911	// {
38912	//   "description": "Updates an existing placement group. This method supports patch semantics.",
38913	//   "httpMethod": "PATCH",
38914	//   "id": "dfareporting.placementGroups.patch",
38915	//   "parameterOrder": [
38916	//     "profileId",
38917	//     "id"
38918	//   ],
38919	//   "parameters": {
38920	//     "id": {
38921	//       "description": "Placement group ID.",
38922	//       "format": "int64",
38923	//       "location": "query",
38924	//       "required": true,
38925	//       "type": "string"
38926	//     },
38927	//     "profileId": {
38928	//       "description": "User profile ID associated with this request.",
38929	//       "format": "int64",
38930	//       "location": "path",
38931	//       "required": true,
38932	//       "type": "string"
38933	//     }
38934	//   },
38935	//   "path": "userprofiles/{profileId}/placementGroups",
38936	//   "request": {
38937	//     "$ref": "PlacementGroup"
38938	//   },
38939	//   "response": {
38940	//     "$ref": "PlacementGroup"
38941	//   },
38942	//   "scopes": [
38943	//     "https://www.googleapis.com/auth/dfatrafficking"
38944	//   ]
38945	// }
38946
38947}
38948
38949// method id "dfareporting.placementGroups.update":
38950
38951type PlacementGroupsUpdateCall struct {
38952	s              *Service
38953	profileId      int64
38954	placementgroup *PlacementGroup
38955	urlParams_     gensupport.URLParams
38956	ctx_           context.Context
38957	header_        http.Header
38958}
38959
38960// Update: Updates an existing placement group.
38961func (r *PlacementGroupsService) Update(profileId int64, placementgroup *PlacementGroup) *PlacementGroupsUpdateCall {
38962	c := &PlacementGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38963	c.profileId = profileId
38964	c.placementgroup = placementgroup
38965	return c
38966}
38967
38968// Fields allows partial responses to be retrieved. See
38969// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38970// for more information.
38971func (c *PlacementGroupsUpdateCall) Fields(s ...googleapi.Field) *PlacementGroupsUpdateCall {
38972	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38973	return c
38974}
38975
38976// Context sets the context to be used in this call's Do method. Any
38977// pending HTTP request will be aborted if the provided context is
38978// canceled.
38979func (c *PlacementGroupsUpdateCall) Context(ctx context.Context) *PlacementGroupsUpdateCall {
38980	c.ctx_ = ctx
38981	return c
38982}
38983
38984// Header returns an http.Header that can be modified by the caller to
38985// add HTTP headers to the request.
38986func (c *PlacementGroupsUpdateCall) Header() http.Header {
38987	if c.header_ == nil {
38988		c.header_ = make(http.Header)
38989	}
38990	return c.header_
38991}
38992
38993func (c *PlacementGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
38994	reqHeaders := make(http.Header)
38995	for k, v := range c.header_ {
38996		reqHeaders[k] = v
38997	}
38998	reqHeaders.Set("User-Agent", c.s.userAgent())
38999	var body io.Reader = nil
39000	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
39001	if err != nil {
39002		return nil, err
39003	}
39004	reqHeaders.Set("Content-Type", "application/json")
39005	c.urlParams_.Set("alt", alt)
39006	c.urlParams_.Set("prettyPrint", "false")
39007	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
39008	urls += "?" + c.urlParams_.Encode()
39009	req, err := http.NewRequest("PUT", urls, body)
39010	if err != nil {
39011		return nil, err
39012	}
39013	req.Header = reqHeaders
39014	googleapi.Expand(req.URL, map[string]string{
39015		"profileId": strconv.FormatInt(c.profileId, 10),
39016	})
39017	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39018}
39019
39020// Do executes the "dfareporting.placementGroups.update" call.
39021// Exactly one of *PlacementGroup or error will be non-nil. Any non-2xx
39022// status code is an error. Response headers are in either
39023// *PlacementGroup.ServerResponse.Header or (if a response was returned
39024// at all) in error.(*googleapi.Error).Header. Use
39025// googleapi.IsNotModified to check whether the returned error was
39026// because http.StatusNotModified was returned.
39027func (c *PlacementGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
39028	gensupport.SetOptions(c.urlParams_, opts...)
39029	res, err := c.doRequest("json")
39030	if res != nil && res.StatusCode == http.StatusNotModified {
39031		if res.Body != nil {
39032			res.Body.Close()
39033		}
39034		return nil, &googleapi.Error{
39035			Code:   res.StatusCode,
39036			Header: res.Header,
39037		}
39038	}
39039	if err != nil {
39040		return nil, err
39041	}
39042	defer googleapi.CloseBody(res)
39043	if err := googleapi.CheckResponse(res); err != nil {
39044		return nil, err
39045	}
39046	ret := &PlacementGroup{
39047		ServerResponse: googleapi.ServerResponse{
39048			Header:         res.Header,
39049			HTTPStatusCode: res.StatusCode,
39050		},
39051	}
39052	target := &ret
39053	if err := gensupport.DecodeResponse(target, res); err != nil {
39054		return nil, err
39055	}
39056	return ret, nil
39057	// {
39058	//   "description": "Updates an existing placement group.",
39059	//   "httpMethod": "PUT",
39060	//   "id": "dfareporting.placementGroups.update",
39061	//   "parameterOrder": [
39062	//     "profileId"
39063	//   ],
39064	//   "parameters": {
39065	//     "profileId": {
39066	//       "description": "User profile ID associated with this request.",
39067	//       "format": "int64",
39068	//       "location": "path",
39069	//       "required": true,
39070	//       "type": "string"
39071	//     }
39072	//   },
39073	//   "path": "userprofiles/{profileId}/placementGroups",
39074	//   "request": {
39075	//     "$ref": "PlacementGroup"
39076	//   },
39077	//   "response": {
39078	//     "$ref": "PlacementGroup"
39079	//   },
39080	//   "scopes": [
39081	//     "https://www.googleapis.com/auth/dfatrafficking"
39082	//   ]
39083	// }
39084
39085}
39086
39087// method id "dfareporting.placementStrategies.delete":
39088
39089type PlacementStrategiesDeleteCall struct {
39090	s          *Service
39091	profileId  int64
39092	id         int64
39093	urlParams_ gensupport.URLParams
39094	ctx_       context.Context
39095	header_    http.Header
39096}
39097
39098// Delete: Deletes an existing placement strategy.
39099func (r *PlacementStrategiesService) Delete(profileId int64, id int64) *PlacementStrategiesDeleteCall {
39100	c := &PlacementStrategiesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39101	c.profileId = profileId
39102	c.id = id
39103	return c
39104}
39105
39106// Fields allows partial responses to be retrieved. See
39107// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39108// for more information.
39109func (c *PlacementStrategiesDeleteCall) Fields(s ...googleapi.Field) *PlacementStrategiesDeleteCall {
39110	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39111	return c
39112}
39113
39114// Context sets the context to be used in this call's Do method. Any
39115// pending HTTP request will be aborted if the provided context is
39116// canceled.
39117func (c *PlacementStrategiesDeleteCall) Context(ctx context.Context) *PlacementStrategiesDeleteCall {
39118	c.ctx_ = ctx
39119	return c
39120}
39121
39122// Header returns an http.Header that can be modified by the caller to
39123// add HTTP headers to the request.
39124func (c *PlacementStrategiesDeleteCall) Header() http.Header {
39125	if c.header_ == nil {
39126		c.header_ = make(http.Header)
39127	}
39128	return c.header_
39129}
39130
39131func (c *PlacementStrategiesDeleteCall) doRequest(alt string) (*http.Response, error) {
39132	reqHeaders := make(http.Header)
39133	for k, v := range c.header_ {
39134		reqHeaders[k] = v
39135	}
39136	reqHeaders.Set("User-Agent", c.s.userAgent())
39137	var body io.Reader = nil
39138	c.urlParams_.Set("alt", alt)
39139	c.urlParams_.Set("prettyPrint", "false")
39140	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies/{id}")
39141	urls += "?" + c.urlParams_.Encode()
39142	req, err := http.NewRequest("DELETE", urls, body)
39143	if err != nil {
39144		return nil, err
39145	}
39146	req.Header = reqHeaders
39147	googleapi.Expand(req.URL, map[string]string{
39148		"profileId": strconv.FormatInt(c.profileId, 10),
39149		"id":        strconv.FormatInt(c.id, 10),
39150	})
39151	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39152}
39153
39154// Do executes the "dfareporting.placementStrategies.delete" call.
39155func (c *PlacementStrategiesDeleteCall) Do(opts ...googleapi.CallOption) error {
39156	gensupport.SetOptions(c.urlParams_, opts...)
39157	res, err := c.doRequest("json")
39158	if err != nil {
39159		return err
39160	}
39161	defer googleapi.CloseBody(res)
39162	if err := googleapi.CheckResponse(res); err != nil {
39163		return err
39164	}
39165	return nil
39166	// {
39167	//   "description": "Deletes an existing placement strategy.",
39168	//   "httpMethod": "DELETE",
39169	//   "id": "dfareporting.placementStrategies.delete",
39170	//   "parameterOrder": [
39171	//     "profileId",
39172	//     "id"
39173	//   ],
39174	//   "parameters": {
39175	//     "id": {
39176	//       "description": "Placement strategy ID.",
39177	//       "format": "int64",
39178	//       "location": "path",
39179	//       "required": true,
39180	//       "type": "string"
39181	//     },
39182	//     "profileId": {
39183	//       "description": "User profile ID associated with this request.",
39184	//       "format": "int64",
39185	//       "location": "path",
39186	//       "required": true,
39187	//       "type": "string"
39188	//     }
39189	//   },
39190	//   "path": "userprofiles/{profileId}/placementStrategies/{id}",
39191	//   "scopes": [
39192	//     "https://www.googleapis.com/auth/dfatrafficking"
39193	//   ]
39194	// }
39195
39196}
39197
39198// method id "dfareporting.placementStrategies.get":
39199
39200type PlacementStrategiesGetCall struct {
39201	s            *Service
39202	profileId    int64
39203	id           int64
39204	urlParams_   gensupport.URLParams
39205	ifNoneMatch_ string
39206	ctx_         context.Context
39207	header_      http.Header
39208}
39209
39210// Get: Gets one placement strategy by ID.
39211func (r *PlacementStrategiesService) Get(profileId int64, id int64) *PlacementStrategiesGetCall {
39212	c := &PlacementStrategiesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39213	c.profileId = profileId
39214	c.id = id
39215	return c
39216}
39217
39218// Fields allows partial responses to be retrieved. See
39219// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39220// for more information.
39221func (c *PlacementStrategiesGetCall) Fields(s ...googleapi.Field) *PlacementStrategiesGetCall {
39222	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39223	return c
39224}
39225
39226// IfNoneMatch sets the optional parameter which makes the operation
39227// fail if the object's ETag matches the given value. This is useful for
39228// getting updates only after the object has changed since the last
39229// request. Use googleapi.IsNotModified to check whether the response
39230// error from Do is the result of In-None-Match.
39231func (c *PlacementStrategiesGetCall) IfNoneMatch(entityTag string) *PlacementStrategiesGetCall {
39232	c.ifNoneMatch_ = entityTag
39233	return c
39234}
39235
39236// Context sets the context to be used in this call's Do method. Any
39237// pending HTTP request will be aborted if the provided context is
39238// canceled.
39239func (c *PlacementStrategiesGetCall) Context(ctx context.Context) *PlacementStrategiesGetCall {
39240	c.ctx_ = ctx
39241	return c
39242}
39243
39244// Header returns an http.Header that can be modified by the caller to
39245// add HTTP headers to the request.
39246func (c *PlacementStrategiesGetCall) Header() http.Header {
39247	if c.header_ == nil {
39248		c.header_ = make(http.Header)
39249	}
39250	return c.header_
39251}
39252
39253func (c *PlacementStrategiesGetCall) doRequest(alt string) (*http.Response, error) {
39254	reqHeaders := make(http.Header)
39255	for k, v := range c.header_ {
39256		reqHeaders[k] = v
39257	}
39258	reqHeaders.Set("User-Agent", c.s.userAgent())
39259	if c.ifNoneMatch_ != "" {
39260		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39261	}
39262	var body io.Reader = nil
39263	c.urlParams_.Set("alt", alt)
39264	c.urlParams_.Set("prettyPrint", "false")
39265	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies/{id}")
39266	urls += "?" + c.urlParams_.Encode()
39267	req, err := http.NewRequest("GET", urls, body)
39268	if err != nil {
39269		return nil, err
39270	}
39271	req.Header = reqHeaders
39272	googleapi.Expand(req.URL, map[string]string{
39273		"profileId": strconv.FormatInt(c.profileId, 10),
39274		"id":        strconv.FormatInt(c.id, 10),
39275	})
39276	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39277}
39278
39279// Do executes the "dfareporting.placementStrategies.get" call.
39280// Exactly one of *PlacementStrategy or error will be non-nil. Any
39281// non-2xx status code is an error. Response headers are in either
39282// *PlacementStrategy.ServerResponse.Header or (if a response was
39283// returned at all) in error.(*googleapi.Error).Header. Use
39284// googleapi.IsNotModified to check whether the returned error was
39285// because http.StatusNotModified was returned.
39286func (c *PlacementStrategiesGetCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39287	gensupport.SetOptions(c.urlParams_, opts...)
39288	res, err := c.doRequest("json")
39289	if res != nil && res.StatusCode == http.StatusNotModified {
39290		if res.Body != nil {
39291			res.Body.Close()
39292		}
39293		return nil, &googleapi.Error{
39294			Code:   res.StatusCode,
39295			Header: res.Header,
39296		}
39297	}
39298	if err != nil {
39299		return nil, err
39300	}
39301	defer googleapi.CloseBody(res)
39302	if err := googleapi.CheckResponse(res); err != nil {
39303		return nil, err
39304	}
39305	ret := &PlacementStrategy{
39306		ServerResponse: googleapi.ServerResponse{
39307			Header:         res.Header,
39308			HTTPStatusCode: res.StatusCode,
39309		},
39310	}
39311	target := &ret
39312	if err := gensupport.DecodeResponse(target, res); err != nil {
39313		return nil, err
39314	}
39315	return ret, nil
39316	// {
39317	//   "description": "Gets one placement strategy by ID.",
39318	//   "httpMethod": "GET",
39319	//   "id": "dfareporting.placementStrategies.get",
39320	//   "parameterOrder": [
39321	//     "profileId",
39322	//     "id"
39323	//   ],
39324	//   "parameters": {
39325	//     "id": {
39326	//       "description": "Placement strategy ID.",
39327	//       "format": "int64",
39328	//       "location": "path",
39329	//       "required": true,
39330	//       "type": "string"
39331	//     },
39332	//     "profileId": {
39333	//       "description": "User profile ID associated with this request.",
39334	//       "format": "int64",
39335	//       "location": "path",
39336	//       "required": true,
39337	//       "type": "string"
39338	//     }
39339	//   },
39340	//   "path": "userprofiles/{profileId}/placementStrategies/{id}",
39341	//   "response": {
39342	//     "$ref": "PlacementStrategy"
39343	//   },
39344	//   "scopes": [
39345	//     "https://www.googleapis.com/auth/dfatrafficking"
39346	//   ]
39347	// }
39348
39349}
39350
39351// method id "dfareporting.placementStrategies.insert":
39352
39353type PlacementStrategiesInsertCall struct {
39354	s                 *Service
39355	profileId         int64
39356	placementstrategy *PlacementStrategy
39357	urlParams_        gensupport.URLParams
39358	ctx_              context.Context
39359	header_           http.Header
39360}
39361
39362// Insert: Inserts a new placement strategy.
39363func (r *PlacementStrategiesService) Insert(profileId int64, placementstrategy *PlacementStrategy) *PlacementStrategiesInsertCall {
39364	c := &PlacementStrategiesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39365	c.profileId = profileId
39366	c.placementstrategy = placementstrategy
39367	return c
39368}
39369
39370// Fields allows partial responses to be retrieved. See
39371// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39372// for more information.
39373func (c *PlacementStrategiesInsertCall) Fields(s ...googleapi.Field) *PlacementStrategiesInsertCall {
39374	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39375	return c
39376}
39377
39378// Context sets the context to be used in this call's Do method. Any
39379// pending HTTP request will be aborted if the provided context is
39380// canceled.
39381func (c *PlacementStrategiesInsertCall) Context(ctx context.Context) *PlacementStrategiesInsertCall {
39382	c.ctx_ = ctx
39383	return c
39384}
39385
39386// Header returns an http.Header that can be modified by the caller to
39387// add HTTP headers to the request.
39388func (c *PlacementStrategiesInsertCall) Header() http.Header {
39389	if c.header_ == nil {
39390		c.header_ = make(http.Header)
39391	}
39392	return c.header_
39393}
39394
39395func (c *PlacementStrategiesInsertCall) doRequest(alt string) (*http.Response, error) {
39396	reqHeaders := make(http.Header)
39397	for k, v := range c.header_ {
39398		reqHeaders[k] = v
39399	}
39400	reqHeaders.Set("User-Agent", c.s.userAgent())
39401	var body io.Reader = nil
39402	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
39403	if err != nil {
39404		return nil, err
39405	}
39406	reqHeaders.Set("Content-Type", "application/json")
39407	c.urlParams_.Set("alt", alt)
39408	c.urlParams_.Set("prettyPrint", "false")
39409	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39410	urls += "?" + c.urlParams_.Encode()
39411	req, err := http.NewRequest("POST", urls, body)
39412	if err != nil {
39413		return nil, err
39414	}
39415	req.Header = reqHeaders
39416	googleapi.Expand(req.URL, map[string]string{
39417		"profileId": strconv.FormatInt(c.profileId, 10),
39418	})
39419	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39420}
39421
39422// Do executes the "dfareporting.placementStrategies.insert" call.
39423// Exactly one of *PlacementStrategy or error will be non-nil. Any
39424// non-2xx status code is an error. Response headers are in either
39425// *PlacementStrategy.ServerResponse.Header or (if a response was
39426// returned at all) in error.(*googleapi.Error).Header. Use
39427// googleapi.IsNotModified to check whether the returned error was
39428// because http.StatusNotModified was returned.
39429func (c *PlacementStrategiesInsertCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39430	gensupport.SetOptions(c.urlParams_, opts...)
39431	res, err := c.doRequest("json")
39432	if res != nil && res.StatusCode == http.StatusNotModified {
39433		if res.Body != nil {
39434			res.Body.Close()
39435		}
39436		return nil, &googleapi.Error{
39437			Code:   res.StatusCode,
39438			Header: res.Header,
39439		}
39440	}
39441	if err != nil {
39442		return nil, err
39443	}
39444	defer googleapi.CloseBody(res)
39445	if err := googleapi.CheckResponse(res); err != nil {
39446		return nil, err
39447	}
39448	ret := &PlacementStrategy{
39449		ServerResponse: googleapi.ServerResponse{
39450			Header:         res.Header,
39451			HTTPStatusCode: res.StatusCode,
39452		},
39453	}
39454	target := &ret
39455	if err := gensupport.DecodeResponse(target, res); err != nil {
39456		return nil, err
39457	}
39458	return ret, nil
39459	// {
39460	//   "description": "Inserts a new placement strategy.",
39461	//   "httpMethod": "POST",
39462	//   "id": "dfareporting.placementStrategies.insert",
39463	//   "parameterOrder": [
39464	//     "profileId"
39465	//   ],
39466	//   "parameters": {
39467	//     "profileId": {
39468	//       "description": "User profile ID associated with this request.",
39469	//       "format": "int64",
39470	//       "location": "path",
39471	//       "required": true,
39472	//       "type": "string"
39473	//     }
39474	//   },
39475	//   "path": "userprofiles/{profileId}/placementStrategies",
39476	//   "request": {
39477	//     "$ref": "PlacementStrategy"
39478	//   },
39479	//   "response": {
39480	//     "$ref": "PlacementStrategy"
39481	//   },
39482	//   "scopes": [
39483	//     "https://www.googleapis.com/auth/dfatrafficking"
39484	//   ]
39485	// }
39486
39487}
39488
39489// method id "dfareporting.placementStrategies.list":
39490
39491type PlacementStrategiesListCall struct {
39492	s            *Service
39493	profileId    int64
39494	urlParams_   gensupport.URLParams
39495	ifNoneMatch_ string
39496	ctx_         context.Context
39497	header_      http.Header
39498}
39499
39500// List: Retrieves a list of placement strategies, possibly filtered.
39501// This method supports paging.
39502func (r *PlacementStrategiesService) List(profileId int64) *PlacementStrategiesListCall {
39503	c := &PlacementStrategiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39504	c.profileId = profileId
39505	return c
39506}
39507
39508// Ids sets the optional parameter "ids": Select only placement
39509// strategies with these IDs.
39510func (c *PlacementStrategiesListCall) Ids(ids ...int64) *PlacementStrategiesListCall {
39511	var ids_ []string
39512	for _, v := range ids {
39513		ids_ = append(ids_, fmt.Sprint(v))
39514	}
39515	c.urlParams_.SetMulti("ids", ids_)
39516	return c
39517}
39518
39519// MaxResults sets the optional parameter "maxResults": Maximum number
39520// of results to return.
39521func (c *PlacementStrategiesListCall) MaxResults(maxResults int64) *PlacementStrategiesListCall {
39522	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
39523	return c
39524}
39525
39526// PageToken sets the optional parameter "pageToken": Value of the
39527// nextPageToken from the previous result page.
39528func (c *PlacementStrategiesListCall) PageToken(pageToken string) *PlacementStrategiesListCall {
39529	c.urlParams_.Set("pageToken", pageToken)
39530	return c
39531}
39532
39533// SearchString sets the optional parameter "searchString": Allows
39534// searching for objects by name or ID. Wildcards (*) are allowed. For
39535// example, "placementstrategy*2015" will return objects with names like
39536// "placementstrategy June 2015", "placementstrategy April 2015", or
39537// simply "placementstrategy 2015". Most of the searches also add
39538// wildcards implicitly at the start and the end of the search string.
39539// For example, a search string of "placementstrategy" will match
39540// objects with name "my placementstrategy", "placementstrategy 2015",
39541// or simply "placementstrategy".
39542func (c *PlacementStrategiesListCall) SearchString(searchString string) *PlacementStrategiesListCall {
39543	c.urlParams_.Set("searchString", searchString)
39544	return c
39545}
39546
39547// SortField sets the optional parameter "sortField": Field by which to
39548// sort the list.
39549//
39550// Possible values:
39551//   "ID" (default)
39552//   "NAME"
39553func (c *PlacementStrategiesListCall) SortField(sortField string) *PlacementStrategiesListCall {
39554	c.urlParams_.Set("sortField", sortField)
39555	return c
39556}
39557
39558// SortOrder sets the optional parameter "sortOrder": Order of sorted
39559// results.
39560//
39561// Possible values:
39562//   "ASCENDING" (default)
39563//   "DESCENDING"
39564func (c *PlacementStrategiesListCall) SortOrder(sortOrder string) *PlacementStrategiesListCall {
39565	c.urlParams_.Set("sortOrder", sortOrder)
39566	return c
39567}
39568
39569// Fields allows partial responses to be retrieved. See
39570// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39571// for more information.
39572func (c *PlacementStrategiesListCall) Fields(s ...googleapi.Field) *PlacementStrategiesListCall {
39573	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39574	return c
39575}
39576
39577// IfNoneMatch sets the optional parameter which makes the operation
39578// fail if the object's ETag matches the given value. This is useful for
39579// getting updates only after the object has changed since the last
39580// request. Use googleapi.IsNotModified to check whether the response
39581// error from Do is the result of In-None-Match.
39582func (c *PlacementStrategiesListCall) IfNoneMatch(entityTag string) *PlacementStrategiesListCall {
39583	c.ifNoneMatch_ = entityTag
39584	return c
39585}
39586
39587// Context sets the context to be used in this call's Do method. Any
39588// pending HTTP request will be aborted if the provided context is
39589// canceled.
39590func (c *PlacementStrategiesListCall) Context(ctx context.Context) *PlacementStrategiesListCall {
39591	c.ctx_ = ctx
39592	return c
39593}
39594
39595// Header returns an http.Header that can be modified by the caller to
39596// add HTTP headers to the request.
39597func (c *PlacementStrategiesListCall) Header() http.Header {
39598	if c.header_ == nil {
39599		c.header_ = make(http.Header)
39600	}
39601	return c.header_
39602}
39603
39604func (c *PlacementStrategiesListCall) doRequest(alt string) (*http.Response, error) {
39605	reqHeaders := make(http.Header)
39606	for k, v := range c.header_ {
39607		reqHeaders[k] = v
39608	}
39609	reqHeaders.Set("User-Agent", c.s.userAgent())
39610	if c.ifNoneMatch_ != "" {
39611		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39612	}
39613	var body io.Reader = nil
39614	c.urlParams_.Set("alt", alt)
39615	c.urlParams_.Set("prettyPrint", "false")
39616	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39617	urls += "?" + c.urlParams_.Encode()
39618	req, err := http.NewRequest("GET", urls, body)
39619	if err != nil {
39620		return nil, err
39621	}
39622	req.Header = reqHeaders
39623	googleapi.Expand(req.URL, map[string]string{
39624		"profileId": strconv.FormatInt(c.profileId, 10),
39625	})
39626	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39627}
39628
39629// Do executes the "dfareporting.placementStrategies.list" call.
39630// Exactly one of *PlacementStrategiesListResponse or error will be
39631// non-nil. Any non-2xx status code is an error. Response headers are in
39632// either *PlacementStrategiesListResponse.ServerResponse.Header or (if
39633// a response was returned at all) in error.(*googleapi.Error).Header.
39634// Use googleapi.IsNotModified to check whether the returned error was
39635// because http.StatusNotModified was returned.
39636func (c *PlacementStrategiesListCall) Do(opts ...googleapi.CallOption) (*PlacementStrategiesListResponse, error) {
39637	gensupport.SetOptions(c.urlParams_, opts...)
39638	res, err := c.doRequest("json")
39639	if res != nil && res.StatusCode == http.StatusNotModified {
39640		if res.Body != nil {
39641			res.Body.Close()
39642		}
39643		return nil, &googleapi.Error{
39644			Code:   res.StatusCode,
39645			Header: res.Header,
39646		}
39647	}
39648	if err != nil {
39649		return nil, err
39650	}
39651	defer googleapi.CloseBody(res)
39652	if err := googleapi.CheckResponse(res); err != nil {
39653		return nil, err
39654	}
39655	ret := &PlacementStrategiesListResponse{
39656		ServerResponse: googleapi.ServerResponse{
39657			Header:         res.Header,
39658			HTTPStatusCode: res.StatusCode,
39659		},
39660	}
39661	target := &ret
39662	if err := gensupport.DecodeResponse(target, res); err != nil {
39663		return nil, err
39664	}
39665	return ret, nil
39666	// {
39667	//   "description": "Retrieves a list of placement strategies, possibly filtered. This method supports paging.",
39668	//   "httpMethod": "GET",
39669	//   "id": "dfareporting.placementStrategies.list",
39670	//   "parameterOrder": [
39671	//     "profileId"
39672	//   ],
39673	//   "parameters": {
39674	//     "ids": {
39675	//       "description": "Select only placement strategies with these IDs.",
39676	//       "format": "int64",
39677	//       "location": "query",
39678	//       "repeated": true,
39679	//       "type": "string"
39680	//     },
39681	//     "maxResults": {
39682	//       "default": "1000",
39683	//       "description": "Maximum number of results to return.",
39684	//       "format": "int32",
39685	//       "location": "query",
39686	//       "maximum": "1000",
39687	//       "minimum": "0",
39688	//       "type": "integer"
39689	//     },
39690	//     "pageToken": {
39691	//       "description": "Value of the nextPageToken from the previous result page.",
39692	//       "location": "query",
39693	//       "type": "string"
39694	//     },
39695	//     "profileId": {
39696	//       "description": "User profile ID associated with this request.",
39697	//       "format": "int64",
39698	//       "location": "path",
39699	//       "required": true,
39700	//       "type": "string"
39701	//     },
39702	//     "searchString": {
39703	//       "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\".",
39704	//       "location": "query",
39705	//       "type": "string"
39706	//     },
39707	//     "sortField": {
39708	//       "default": "ID",
39709	//       "description": "Field by which to sort the list.",
39710	//       "enum": [
39711	//         "ID",
39712	//         "NAME"
39713	//       ],
39714	//       "enumDescriptions": [
39715	//         "",
39716	//         ""
39717	//       ],
39718	//       "location": "query",
39719	//       "type": "string"
39720	//     },
39721	//     "sortOrder": {
39722	//       "default": "ASCENDING",
39723	//       "description": "Order of sorted results.",
39724	//       "enum": [
39725	//         "ASCENDING",
39726	//         "DESCENDING"
39727	//       ],
39728	//       "enumDescriptions": [
39729	//         "",
39730	//         ""
39731	//       ],
39732	//       "location": "query",
39733	//       "type": "string"
39734	//     }
39735	//   },
39736	//   "path": "userprofiles/{profileId}/placementStrategies",
39737	//   "response": {
39738	//     "$ref": "PlacementStrategiesListResponse"
39739	//   },
39740	//   "scopes": [
39741	//     "https://www.googleapis.com/auth/dfatrafficking"
39742	//   ]
39743	// }
39744
39745}
39746
39747// Pages invokes f for each page of results.
39748// A non-nil error returned from f will halt the iteration.
39749// The provided context supersedes any context provided to the Context method.
39750func (c *PlacementStrategiesListCall) Pages(ctx context.Context, f func(*PlacementStrategiesListResponse) error) error {
39751	c.ctx_ = ctx
39752	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
39753	for {
39754		x, err := c.Do()
39755		if err != nil {
39756			return err
39757		}
39758		if err := f(x); err != nil {
39759			return err
39760		}
39761		if x.NextPageToken == "" {
39762			return nil
39763		}
39764		c.PageToken(x.NextPageToken)
39765	}
39766}
39767
39768// method id "dfareporting.placementStrategies.patch":
39769
39770type PlacementStrategiesPatchCall struct {
39771	s                 *Service
39772	profileId         int64
39773	placementstrategy *PlacementStrategy
39774	urlParams_        gensupport.URLParams
39775	ctx_              context.Context
39776	header_           http.Header
39777}
39778
39779// Patch: Updates an existing placement strategy. This method supports
39780// patch semantics.
39781func (r *PlacementStrategiesService) Patch(profileId int64, id int64, placementstrategy *PlacementStrategy) *PlacementStrategiesPatchCall {
39782	c := &PlacementStrategiesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39783	c.profileId = profileId
39784	c.urlParams_.Set("id", fmt.Sprint(id))
39785	c.placementstrategy = placementstrategy
39786	return c
39787}
39788
39789// Fields allows partial responses to be retrieved. See
39790// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39791// for more information.
39792func (c *PlacementStrategiesPatchCall) Fields(s ...googleapi.Field) *PlacementStrategiesPatchCall {
39793	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39794	return c
39795}
39796
39797// Context sets the context to be used in this call's Do method. Any
39798// pending HTTP request will be aborted if the provided context is
39799// canceled.
39800func (c *PlacementStrategiesPatchCall) Context(ctx context.Context) *PlacementStrategiesPatchCall {
39801	c.ctx_ = ctx
39802	return c
39803}
39804
39805// Header returns an http.Header that can be modified by the caller to
39806// add HTTP headers to the request.
39807func (c *PlacementStrategiesPatchCall) Header() http.Header {
39808	if c.header_ == nil {
39809		c.header_ = make(http.Header)
39810	}
39811	return c.header_
39812}
39813
39814func (c *PlacementStrategiesPatchCall) doRequest(alt string) (*http.Response, error) {
39815	reqHeaders := make(http.Header)
39816	for k, v := range c.header_ {
39817		reqHeaders[k] = v
39818	}
39819	reqHeaders.Set("User-Agent", c.s.userAgent())
39820	var body io.Reader = nil
39821	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
39822	if err != nil {
39823		return nil, err
39824	}
39825	reqHeaders.Set("Content-Type", "application/json")
39826	c.urlParams_.Set("alt", alt)
39827	c.urlParams_.Set("prettyPrint", "false")
39828	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39829	urls += "?" + c.urlParams_.Encode()
39830	req, err := http.NewRequest("PATCH", urls, body)
39831	if err != nil {
39832		return nil, err
39833	}
39834	req.Header = reqHeaders
39835	googleapi.Expand(req.URL, map[string]string{
39836		"profileId": strconv.FormatInt(c.profileId, 10),
39837	})
39838	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39839}
39840
39841// Do executes the "dfareporting.placementStrategies.patch" call.
39842// Exactly one of *PlacementStrategy or error will be non-nil. Any
39843// non-2xx status code is an error. Response headers are in either
39844// *PlacementStrategy.ServerResponse.Header or (if a response was
39845// returned at all) in error.(*googleapi.Error).Header. Use
39846// googleapi.IsNotModified to check whether the returned error was
39847// because http.StatusNotModified was returned.
39848func (c *PlacementStrategiesPatchCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39849	gensupport.SetOptions(c.urlParams_, opts...)
39850	res, err := c.doRequest("json")
39851	if res != nil && res.StatusCode == http.StatusNotModified {
39852		if res.Body != nil {
39853			res.Body.Close()
39854		}
39855		return nil, &googleapi.Error{
39856			Code:   res.StatusCode,
39857			Header: res.Header,
39858		}
39859	}
39860	if err != nil {
39861		return nil, err
39862	}
39863	defer googleapi.CloseBody(res)
39864	if err := googleapi.CheckResponse(res); err != nil {
39865		return nil, err
39866	}
39867	ret := &PlacementStrategy{
39868		ServerResponse: googleapi.ServerResponse{
39869			Header:         res.Header,
39870			HTTPStatusCode: res.StatusCode,
39871		},
39872	}
39873	target := &ret
39874	if err := gensupport.DecodeResponse(target, res); err != nil {
39875		return nil, err
39876	}
39877	return ret, nil
39878	// {
39879	//   "description": "Updates an existing placement strategy. This method supports patch semantics.",
39880	//   "httpMethod": "PATCH",
39881	//   "id": "dfareporting.placementStrategies.patch",
39882	//   "parameterOrder": [
39883	//     "profileId",
39884	//     "id"
39885	//   ],
39886	//   "parameters": {
39887	//     "id": {
39888	//       "description": "Placement strategy ID.",
39889	//       "format": "int64",
39890	//       "location": "query",
39891	//       "required": true,
39892	//       "type": "string"
39893	//     },
39894	//     "profileId": {
39895	//       "description": "User profile ID associated with this request.",
39896	//       "format": "int64",
39897	//       "location": "path",
39898	//       "required": true,
39899	//       "type": "string"
39900	//     }
39901	//   },
39902	//   "path": "userprofiles/{profileId}/placementStrategies",
39903	//   "request": {
39904	//     "$ref": "PlacementStrategy"
39905	//   },
39906	//   "response": {
39907	//     "$ref": "PlacementStrategy"
39908	//   },
39909	//   "scopes": [
39910	//     "https://www.googleapis.com/auth/dfatrafficking"
39911	//   ]
39912	// }
39913
39914}
39915
39916// method id "dfareporting.placementStrategies.update":
39917
39918type PlacementStrategiesUpdateCall struct {
39919	s                 *Service
39920	profileId         int64
39921	placementstrategy *PlacementStrategy
39922	urlParams_        gensupport.URLParams
39923	ctx_              context.Context
39924	header_           http.Header
39925}
39926
39927// Update: Updates an existing placement strategy.
39928func (r *PlacementStrategiesService) Update(profileId int64, placementstrategy *PlacementStrategy) *PlacementStrategiesUpdateCall {
39929	c := &PlacementStrategiesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39930	c.profileId = profileId
39931	c.placementstrategy = placementstrategy
39932	return c
39933}
39934
39935// Fields allows partial responses to be retrieved. See
39936// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39937// for more information.
39938func (c *PlacementStrategiesUpdateCall) Fields(s ...googleapi.Field) *PlacementStrategiesUpdateCall {
39939	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39940	return c
39941}
39942
39943// Context sets the context to be used in this call's Do method. Any
39944// pending HTTP request will be aborted if the provided context is
39945// canceled.
39946func (c *PlacementStrategiesUpdateCall) Context(ctx context.Context) *PlacementStrategiesUpdateCall {
39947	c.ctx_ = ctx
39948	return c
39949}
39950
39951// Header returns an http.Header that can be modified by the caller to
39952// add HTTP headers to the request.
39953func (c *PlacementStrategiesUpdateCall) Header() http.Header {
39954	if c.header_ == nil {
39955		c.header_ = make(http.Header)
39956	}
39957	return c.header_
39958}
39959
39960func (c *PlacementStrategiesUpdateCall) doRequest(alt string) (*http.Response, error) {
39961	reqHeaders := make(http.Header)
39962	for k, v := range c.header_ {
39963		reqHeaders[k] = v
39964	}
39965	reqHeaders.Set("User-Agent", c.s.userAgent())
39966	var body io.Reader = nil
39967	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
39968	if err != nil {
39969		return nil, err
39970	}
39971	reqHeaders.Set("Content-Type", "application/json")
39972	c.urlParams_.Set("alt", alt)
39973	c.urlParams_.Set("prettyPrint", "false")
39974	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39975	urls += "?" + c.urlParams_.Encode()
39976	req, err := http.NewRequest("PUT", urls, body)
39977	if err != nil {
39978		return nil, err
39979	}
39980	req.Header = reqHeaders
39981	googleapi.Expand(req.URL, map[string]string{
39982		"profileId": strconv.FormatInt(c.profileId, 10),
39983	})
39984	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39985}
39986
39987// Do executes the "dfareporting.placementStrategies.update" call.
39988// Exactly one of *PlacementStrategy or error will be non-nil. Any
39989// non-2xx status code is an error. Response headers are in either
39990// *PlacementStrategy.ServerResponse.Header or (if a response was
39991// returned at all) in error.(*googleapi.Error).Header. Use
39992// googleapi.IsNotModified to check whether the returned error was
39993// because http.StatusNotModified was returned.
39994func (c *PlacementStrategiesUpdateCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39995	gensupport.SetOptions(c.urlParams_, opts...)
39996	res, err := c.doRequest("json")
39997	if res != nil && res.StatusCode == http.StatusNotModified {
39998		if res.Body != nil {
39999			res.Body.Close()
40000		}
40001		return nil, &googleapi.Error{
40002			Code:   res.StatusCode,
40003			Header: res.Header,
40004		}
40005	}
40006	if err != nil {
40007		return nil, err
40008	}
40009	defer googleapi.CloseBody(res)
40010	if err := googleapi.CheckResponse(res); err != nil {
40011		return nil, err
40012	}
40013	ret := &PlacementStrategy{
40014		ServerResponse: googleapi.ServerResponse{
40015			Header:         res.Header,
40016			HTTPStatusCode: res.StatusCode,
40017		},
40018	}
40019	target := &ret
40020	if err := gensupport.DecodeResponse(target, res); err != nil {
40021		return nil, err
40022	}
40023	return ret, nil
40024	// {
40025	//   "description": "Updates an existing placement strategy.",
40026	//   "httpMethod": "PUT",
40027	//   "id": "dfareporting.placementStrategies.update",
40028	//   "parameterOrder": [
40029	//     "profileId"
40030	//   ],
40031	//   "parameters": {
40032	//     "profileId": {
40033	//       "description": "User profile ID associated with this request.",
40034	//       "format": "int64",
40035	//       "location": "path",
40036	//       "required": true,
40037	//       "type": "string"
40038	//     }
40039	//   },
40040	//   "path": "userprofiles/{profileId}/placementStrategies",
40041	//   "request": {
40042	//     "$ref": "PlacementStrategy"
40043	//   },
40044	//   "response": {
40045	//     "$ref": "PlacementStrategy"
40046	//   },
40047	//   "scopes": [
40048	//     "https://www.googleapis.com/auth/dfatrafficking"
40049	//   ]
40050	// }
40051
40052}
40053
40054// method id "dfareporting.placements.generatetags":
40055
40056type PlacementsGeneratetagsCall struct {
40057	s          *Service
40058	profileId  int64
40059	urlParams_ gensupport.URLParams
40060	ctx_       context.Context
40061	header_    http.Header
40062}
40063
40064// Generatetags: Generates tags for a placement.
40065func (r *PlacementsService) Generatetags(profileId int64) *PlacementsGeneratetagsCall {
40066	c := &PlacementsGeneratetagsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40067	c.profileId = profileId
40068	return c
40069}
40070
40071// CampaignId sets the optional parameter "campaignId": Generate
40072// placements belonging to this campaign. This is a required field.
40073func (c *PlacementsGeneratetagsCall) CampaignId(campaignId int64) *PlacementsGeneratetagsCall {
40074	c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
40075	return c
40076}
40077
40078// PlacementIds sets the optional parameter "placementIds": Generate
40079// tags for these placements.
40080func (c *PlacementsGeneratetagsCall) PlacementIds(placementIds ...int64) *PlacementsGeneratetagsCall {
40081	var placementIds_ []string
40082	for _, v := range placementIds {
40083		placementIds_ = append(placementIds_, fmt.Sprint(v))
40084	}
40085	c.urlParams_.SetMulti("placementIds", placementIds_)
40086	return c
40087}
40088
40089// TagFormats sets the optional parameter "tagFormats": Tag formats to
40090// generate for these placements.
40091//
40092// Note: PLACEMENT_TAG_STANDARD can only be generated for 1x1
40093// placements.
40094//
40095// Possible values:
40096//   "PLACEMENT_TAG_CLICK_COMMANDS"
40097//   "PLACEMENT_TAG_IFRAME_ILAYER"
40098//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT"
40099//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY"
40100//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH"
40101//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3"
40102//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4"
40103//   "PLACEMENT_TAG_INTERNAL_REDIRECT"
40104//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT"
40105//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY"
40106//   "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT"
40107//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT"
40108//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY"
40109//   "PLACEMENT_TAG_JAVASCRIPT"
40110//   "PLACEMENT_TAG_JAVASCRIPT_LEGACY"
40111//   "PLACEMENT_TAG_STANDARD"
40112//   "PLACEMENT_TAG_TRACKING"
40113//   "PLACEMENT_TAG_TRACKING_IFRAME"
40114//   "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
40115func (c *PlacementsGeneratetagsCall) TagFormats(tagFormats ...string) *PlacementsGeneratetagsCall {
40116	c.urlParams_.SetMulti("tagFormats", append([]string{}, tagFormats...))
40117	return c
40118}
40119
40120// Fields allows partial responses to be retrieved. See
40121// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40122// for more information.
40123func (c *PlacementsGeneratetagsCall) Fields(s ...googleapi.Field) *PlacementsGeneratetagsCall {
40124	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40125	return c
40126}
40127
40128// Context sets the context to be used in this call's Do method. Any
40129// pending HTTP request will be aborted if the provided context is
40130// canceled.
40131func (c *PlacementsGeneratetagsCall) Context(ctx context.Context) *PlacementsGeneratetagsCall {
40132	c.ctx_ = ctx
40133	return c
40134}
40135
40136// Header returns an http.Header that can be modified by the caller to
40137// add HTTP headers to the request.
40138func (c *PlacementsGeneratetagsCall) Header() http.Header {
40139	if c.header_ == nil {
40140		c.header_ = make(http.Header)
40141	}
40142	return c.header_
40143}
40144
40145func (c *PlacementsGeneratetagsCall) doRequest(alt string) (*http.Response, error) {
40146	reqHeaders := make(http.Header)
40147	for k, v := range c.header_ {
40148		reqHeaders[k] = v
40149	}
40150	reqHeaders.Set("User-Agent", c.s.userAgent())
40151	var body io.Reader = nil
40152	c.urlParams_.Set("alt", alt)
40153	c.urlParams_.Set("prettyPrint", "false")
40154	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements/generatetags")
40155	urls += "?" + c.urlParams_.Encode()
40156	req, err := http.NewRequest("POST", urls, body)
40157	if err != nil {
40158		return nil, err
40159	}
40160	req.Header = reqHeaders
40161	googleapi.Expand(req.URL, map[string]string{
40162		"profileId": strconv.FormatInt(c.profileId, 10),
40163	})
40164	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40165}
40166
40167// Do executes the "dfareporting.placements.generatetags" call.
40168// Exactly one of *PlacementsGenerateTagsResponse or error will be
40169// non-nil. Any non-2xx status code is an error. Response headers are in
40170// either *PlacementsGenerateTagsResponse.ServerResponse.Header or (if a
40171// response was returned at all) in error.(*googleapi.Error).Header. Use
40172// googleapi.IsNotModified to check whether the returned error was
40173// because http.StatusNotModified was returned.
40174func (c *PlacementsGeneratetagsCall) Do(opts ...googleapi.CallOption) (*PlacementsGenerateTagsResponse, error) {
40175	gensupport.SetOptions(c.urlParams_, opts...)
40176	res, err := c.doRequest("json")
40177	if res != nil && res.StatusCode == http.StatusNotModified {
40178		if res.Body != nil {
40179			res.Body.Close()
40180		}
40181		return nil, &googleapi.Error{
40182			Code:   res.StatusCode,
40183			Header: res.Header,
40184		}
40185	}
40186	if err != nil {
40187		return nil, err
40188	}
40189	defer googleapi.CloseBody(res)
40190	if err := googleapi.CheckResponse(res); err != nil {
40191		return nil, err
40192	}
40193	ret := &PlacementsGenerateTagsResponse{
40194		ServerResponse: googleapi.ServerResponse{
40195			Header:         res.Header,
40196			HTTPStatusCode: res.StatusCode,
40197		},
40198	}
40199	target := &ret
40200	if err := gensupport.DecodeResponse(target, res); err != nil {
40201		return nil, err
40202	}
40203	return ret, nil
40204	// {
40205	//   "description": "Generates tags for a placement.",
40206	//   "httpMethod": "POST",
40207	//   "id": "dfareporting.placements.generatetags",
40208	//   "parameterOrder": [
40209	//     "profileId"
40210	//   ],
40211	//   "parameters": {
40212	//     "campaignId": {
40213	//       "description": "Generate placements belonging to this campaign. This is a required field.",
40214	//       "format": "int64",
40215	//       "location": "query",
40216	//       "type": "string"
40217	//     },
40218	//     "placementIds": {
40219	//       "description": "Generate tags for these placements.",
40220	//       "format": "int64",
40221	//       "location": "query",
40222	//       "repeated": true,
40223	//       "type": "string"
40224	//     },
40225	//     "profileId": {
40226	//       "description": "User profile ID associated with this request.",
40227	//       "format": "int64",
40228	//       "location": "path",
40229	//       "required": true,
40230	//       "type": "string"
40231	//     },
40232	//     "tagFormats": {
40233	//       "description": "Tag formats to generate for these placements.\n\nNote: PLACEMENT_TAG_STANDARD can only be generated for 1x1 placements.",
40234	//       "enum": [
40235	//         "PLACEMENT_TAG_CLICK_COMMANDS",
40236	//         "PLACEMENT_TAG_IFRAME_ILAYER",
40237	//         "PLACEMENT_TAG_IFRAME_JAVASCRIPT",
40238	//         "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY",
40239	//         "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH",
40240	//         "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3",
40241	//         "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4",
40242	//         "PLACEMENT_TAG_INTERNAL_REDIRECT",
40243	//         "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT",
40244	//         "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY",
40245	//         "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT",
40246	//         "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT",
40247	//         "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY",
40248	//         "PLACEMENT_TAG_JAVASCRIPT",
40249	//         "PLACEMENT_TAG_JAVASCRIPT_LEGACY",
40250	//         "PLACEMENT_TAG_STANDARD",
40251	//         "PLACEMENT_TAG_TRACKING",
40252	//         "PLACEMENT_TAG_TRACKING_IFRAME",
40253	//         "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
40254	//       ],
40255	//       "enumDescriptions": [
40256	//         "",
40257	//         "",
40258	//         "",
40259	//         "",
40260	//         "",
40261	//         "",
40262	//         "",
40263	//         "",
40264	//         "",
40265	//         "",
40266	//         "",
40267	//         "",
40268	//         "",
40269	//         "",
40270	//         "",
40271	//         "",
40272	//         "",
40273	//         "",
40274	//         ""
40275	//       ],
40276	//       "location": "query",
40277	//       "repeated": true,
40278	//       "type": "string"
40279	//     }
40280	//   },
40281	//   "path": "userprofiles/{profileId}/placements/generatetags",
40282	//   "response": {
40283	//     "$ref": "PlacementsGenerateTagsResponse"
40284	//   },
40285	//   "scopes": [
40286	//     "https://www.googleapis.com/auth/dfatrafficking"
40287	//   ]
40288	// }
40289
40290}
40291
40292// method id "dfareporting.placements.get":
40293
40294type PlacementsGetCall struct {
40295	s            *Service
40296	profileId    int64
40297	id           int64
40298	urlParams_   gensupport.URLParams
40299	ifNoneMatch_ string
40300	ctx_         context.Context
40301	header_      http.Header
40302}
40303
40304// Get: Gets one placement by ID.
40305func (r *PlacementsService) Get(profileId int64, id int64) *PlacementsGetCall {
40306	c := &PlacementsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40307	c.profileId = profileId
40308	c.id = id
40309	return c
40310}
40311
40312// Fields allows partial responses to be retrieved. See
40313// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40314// for more information.
40315func (c *PlacementsGetCall) Fields(s ...googleapi.Field) *PlacementsGetCall {
40316	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40317	return c
40318}
40319
40320// IfNoneMatch sets the optional parameter which makes the operation
40321// fail if the object's ETag matches the given value. This is useful for
40322// getting updates only after the object has changed since the last
40323// request. Use googleapi.IsNotModified to check whether the response
40324// error from Do is the result of In-None-Match.
40325func (c *PlacementsGetCall) IfNoneMatch(entityTag string) *PlacementsGetCall {
40326	c.ifNoneMatch_ = entityTag
40327	return c
40328}
40329
40330// Context sets the context to be used in this call's Do method. Any
40331// pending HTTP request will be aborted if the provided context is
40332// canceled.
40333func (c *PlacementsGetCall) Context(ctx context.Context) *PlacementsGetCall {
40334	c.ctx_ = ctx
40335	return c
40336}
40337
40338// Header returns an http.Header that can be modified by the caller to
40339// add HTTP headers to the request.
40340func (c *PlacementsGetCall) Header() http.Header {
40341	if c.header_ == nil {
40342		c.header_ = make(http.Header)
40343	}
40344	return c.header_
40345}
40346
40347func (c *PlacementsGetCall) doRequest(alt string) (*http.Response, error) {
40348	reqHeaders := make(http.Header)
40349	for k, v := range c.header_ {
40350		reqHeaders[k] = v
40351	}
40352	reqHeaders.Set("User-Agent", c.s.userAgent())
40353	if c.ifNoneMatch_ != "" {
40354		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40355	}
40356	var body io.Reader = nil
40357	c.urlParams_.Set("alt", alt)
40358	c.urlParams_.Set("prettyPrint", "false")
40359	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements/{id}")
40360	urls += "?" + c.urlParams_.Encode()
40361	req, err := http.NewRequest("GET", urls, body)
40362	if err != nil {
40363		return nil, err
40364	}
40365	req.Header = reqHeaders
40366	googleapi.Expand(req.URL, map[string]string{
40367		"profileId": strconv.FormatInt(c.profileId, 10),
40368		"id":        strconv.FormatInt(c.id, 10),
40369	})
40370	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40371}
40372
40373// Do executes the "dfareporting.placements.get" call.
40374// Exactly one of *Placement or error will be non-nil. Any non-2xx
40375// status code is an error. Response headers are in either
40376// *Placement.ServerResponse.Header or (if a response was returned at
40377// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
40378// to check whether the returned error was because
40379// http.StatusNotModified was returned.
40380func (c *PlacementsGetCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
40381	gensupport.SetOptions(c.urlParams_, opts...)
40382	res, err := c.doRequest("json")
40383	if res != nil && res.StatusCode == http.StatusNotModified {
40384		if res.Body != nil {
40385			res.Body.Close()
40386		}
40387		return nil, &googleapi.Error{
40388			Code:   res.StatusCode,
40389			Header: res.Header,
40390		}
40391	}
40392	if err != nil {
40393		return nil, err
40394	}
40395	defer googleapi.CloseBody(res)
40396	if err := googleapi.CheckResponse(res); err != nil {
40397		return nil, err
40398	}
40399	ret := &Placement{
40400		ServerResponse: googleapi.ServerResponse{
40401			Header:         res.Header,
40402			HTTPStatusCode: res.StatusCode,
40403		},
40404	}
40405	target := &ret
40406	if err := gensupport.DecodeResponse(target, res); err != nil {
40407		return nil, err
40408	}
40409	return ret, nil
40410	// {
40411	//   "description": "Gets one placement by ID.",
40412	//   "httpMethod": "GET",
40413	//   "id": "dfareporting.placements.get",
40414	//   "parameterOrder": [
40415	//     "profileId",
40416	//     "id"
40417	//   ],
40418	//   "parameters": {
40419	//     "id": {
40420	//       "description": "Placement ID.",
40421	//       "format": "int64",
40422	//       "location": "path",
40423	//       "required": true,
40424	//       "type": "string"
40425	//     },
40426	//     "profileId": {
40427	//       "description": "User profile ID associated with this request.",
40428	//       "format": "int64",
40429	//       "location": "path",
40430	//       "required": true,
40431	//       "type": "string"
40432	//     }
40433	//   },
40434	//   "path": "userprofiles/{profileId}/placements/{id}",
40435	//   "response": {
40436	//     "$ref": "Placement"
40437	//   },
40438	//   "scopes": [
40439	//     "https://www.googleapis.com/auth/dfatrafficking"
40440	//   ]
40441	// }
40442
40443}
40444
40445// method id "dfareporting.placements.insert":
40446
40447type PlacementsInsertCall struct {
40448	s          *Service
40449	profileId  int64
40450	placement  *Placement
40451	urlParams_ gensupport.URLParams
40452	ctx_       context.Context
40453	header_    http.Header
40454}
40455
40456// Insert: Inserts a new placement.
40457func (r *PlacementsService) Insert(profileId int64, placement *Placement) *PlacementsInsertCall {
40458	c := &PlacementsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40459	c.profileId = profileId
40460	c.placement = placement
40461	return c
40462}
40463
40464// Fields allows partial responses to be retrieved. See
40465// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40466// for more information.
40467func (c *PlacementsInsertCall) Fields(s ...googleapi.Field) *PlacementsInsertCall {
40468	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40469	return c
40470}
40471
40472// Context sets the context to be used in this call's Do method. Any
40473// pending HTTP request will be aborted if the provided context is
40474// canceled.
40475func (c *PlacementsInsertCall) Context(ctx context.Context) *PlacementsInsertCall {
40476	c.ctx_ = ctx
40477	return c
40478}
40479
40480// Header returns an http.Header that can be modified by the caller to
40481// add HTTP headers to the request.
40482func (c *PlacementsInsertCall) Header() http.Header {
40483	if c.header_ == nil {
40484		c.header_ = make(http.Header)
40485	}
40486	return c.header_
40487}
40488
40489func (c *PlacementsInsertCall) doRequest(alt string) (*http.Response, error) {
40490	reqHeaders := make(http.Header)
40491	for k, v := range c.header_ {
40492		reqHeaders[k] = v
40493	}
40494	reqHeaders.Set("User-Agent", c.s.userAgent())
40495	var body io.Reader = nil
40496	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
40497	if err != nil {
40498		return nil, err
40499	}
40500	reqHeaders.Set("Content-Type", "application/json")
40501	c.urlParams_.Set("alt", alt)
40502	c.urlParams_.Set("prettyPrint", "false")
40503	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
40504	urls += "?" + c.urlParams_.Encode()
40505	req, err := http.NewRequest("POST", urls, body)
40506	if err != nil {
40507		return nil, err
40508	}
40509	req.Header = reqHeaders
40510	googleapi.Expand(req.URL, map[string]string{
40511		"profileId": strconv.FormatInt(c.profileId, 10),
40512	})
40513	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40514}
40515
40516// Do executes the "dfareporting.placements.insert" call.
40517// Exactly one of *Placement or error will be non-nil. Any non-2xx
40518// status code is an error. Response headers are in either
40519// *Placement.ServerResponse.Header or (if a response was returned at
40520// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
40521// to check whether the returned error was because
40522// http.StatusNotModified was returned.
40523func (c *PlacementsInsertCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
40524	gensupport.SetOptions(c.urlParams_, opts...)
40525	res, err := c.doRequest("json")
40526	if res != nil && res.StatusCode == http.StatusNotModified {
40527		if res.Body != nil {
40528			res.Body.Close()
40529		}
40530		return nil, &googleapi.Error{
40531			Code:   res.StatusCode,
40532			Header: res.Header,
40533		}
40534	}
40535	if err != nil {
40536		return nil, err
40537	}
40538	defer googleapi.CloseBody(res)
40539	if err := googleapi.CheckResponse(res); err != nil {
40540		return nil, err
40541	}
40542	ret := &Placement{
40543		ServerResponse: googleapi.ServerResponse{
40544			Header:         res.Header,
40545			HTTPStatusCode: res.StatusCode,
40546		},
40547	}
40548	target := &ret
40549	if err := gensupport.DecodeResponse(target, res); err != nil {
40550		return nil, err
40551	}
40552	return ret, nil
40553	// {
40554	//   "description": "Inserts a new placement.",
40555	//   "httpMethod": "POST",
40556	//   "id": "dfareporting.placements.insert",
40557	//   "parameterOrder": [
40558	//     "profileId"
40559	//   ],
40560	//   "parameters": {
40561	//     "profileId": {
40562	//       "description": "User profile ID associated with this request.",
40563	//       "format": "int64",
40564	//       "location": "path",
40565	//       "required": true,
40566	//       "type": "string"
40567	//     }
40568	//   },
40569	//   "path": "userprofiles/{profileId}/placements",
40570	//   "request": {
40571	//     "$ref": "Placement"
40572	//   },
40573	//   "response": {
40574	//     "$ref": "Placement"
40575	//   },
40576	//   "scopes": [
40577	//     "https://www.googleapis.com/auth/dfatrafficking"
40578	//   ]
40579	// }
40580
40581}
40582
40583// method id "dfareporting.placements.list":
40584
40585type PlacementsListCall struct {
40586	s            *Service
40587	profileId    int64
40588	urlParams_   gensupport.URLParams
40589	ifNoneMatch_ string
40590	ctx_         context.Context
40591	header_      http.Header
40592}
40593
40594// List: Retrieves a list of placements, possibly filtered. This method
40595// supports paging.
40596func (r *PlacementsService) List(profileId int64) *PlacementsListCall {
40597	c := &PlacementsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40598	c.profileId = profileId
40599	return c
40600}
40601
40602// AdvertiserIds sets the optional parameter "advertiserIds": Select
40603// only placements that belong to these advertisers.
40604func (c *PlacementsListCall) AdvertiserIds(advertiserIds ...int64) *PlacementsListCall {
40605	var advertiserIds_ []string
40606	for _, v := range advertiserIds {
40607		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
40608	}
40609	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
40610	return c
40611}
40612
40613// Archived sets the optional parameter "archived": Select only archived
40614// placements. Don't set this field to select both archived and
40615// non-archived placements.
40616func (c *PlacementsListCall) Archived(archived bool) *PlacementsListCall {
40617	c.urlParams_.Set("archived", fmt.Sprint(archived))
40618	return c
40619}
40620
40621// CampaignIds sets the optional parameter "campaignIds": Select only
40622// placements that belong to these campaigns.
40623func (c *PlacementsListCall) CampaignIds(campaignIds ...int64) *PlacementsListCall {
40624	var campaignIds_ []string
40625	for _, v := range campaignIds {
40626		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
40627	}
40628	c.urlParams_.SetMulti("campaignIds", campaignIds_)
40629	return c
40630}
40631
40632// Compatibilities sets the optional parameter "compatibilities": Select
40633// only placements that are associated with these compatibilities.
40634// DISPLAY and DISPLAY_INTERSTITIAL refer to rendering either on desktop
40635// or on mobile devices for regular or interstitial ads respectively.
40636// APP and APP_INTERSTITIAL are for rendering in mobile apps.
40637// IN_STREAM_VIDEO refers to rendering in in-stream video ads developed
40638// with the VAST standard.
40639//
40640// Possible values:
40641//   "APP"
40642//   "APP_INTERSTITIAL"
40643//   "DISPLAY"
40644//   "DISPLAY_INTERSTITIAL"
40645//   "IN_STREAM_AUDIO"
40646//   "IN_STREAM_VIDEO"
40647func (c *PlacementsListCall) Compatibilities(compatibilities ...string) *PlacementsListCall {
40648	c.urlParams_.SetMulti("compatibilities", append([]string{}, compatibilities...))
40649	return c
40650}
40651
40652// ContentCategoryIds sets the optional parameter "contentCategoryIds":
40653// Select only placements that are associated with these content
40654// categories.
40655func (c *PlacementsListCall) ContentCategoryIds(contentCategoryIds ...int64) *PlacementsListCall {
40656	var contentCategoryIds_ []string
40657	for _, v := range contentCategoryIds {
40658		contentCategoryIds_ = append(contentCategoryIds_, fmt.Sprint(v))
40659	}
40660	c.urlParams_.SetMulti("contentCategoryIds", contentCategoryIds_)
40661	return c
40662}
40663
40664// DirectorySiteIds sets the optional parameter "directorySiteIds":
40665// Select only placements that are associated with these directory
40666// sites.
40667func (c *PlacementsListCall) DirectorySiteIds(directorySiteIds ...int64) *PlacementsListCall {
40668	var directorySiteIds_ []string
40669	for _, v := range directorySiteIds {
40670		directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
40671	}
40672	c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
40673	return c
40674}
40675
40676// GroupIds sets the optional parameter "groupIds": Select only
40677// placements that belong to these placement groups.
40678func (c *PlacementsListCall) GroupIds(groupIds ...int64) *PlacementsListCall {
40679	var groupIds_ []string
40680	for _, v := range groupIds {
40681		groupIds_ = append(groupIds_, fmt.Sprint(v))
40682	}
40683	c.urlParams_.SetMulti("groupIds", groupIds_)
40684	return c
40685}
40686
40687// Ids sets the optional parameter "ids": Select only placements with
40688// these IDs.
40689func (c *PlacementsListCall) Ids(ids ...int64) *PlacementsListCall {
40690	var ids_ []string
40691	for _, v := range ids {
40692		ids_ = append(ids_, fmt.Sprint(v))
40693	}
40694	c.urlParams_.SetMulti("ids", ids_)
40695	return c
40696}
40697
40698// MaxEndDate sets the optional parameter "maxEndDate": Select only
40699// placements or placement groups whose end date is on or before the
40700// specified maxEndDate. The date should be formatted as "yyyy-MM-dd".
40701func (c *PlacementsListCall) MaxEndDate(maxEndDate string) *PlacementsListCall {
40702	c.urlParams_.Set("maxEndDate", maxEndDate)
40703	return c
40704}
40705
40706// MaxResults sets the optional parameter "maxResults": Maximum number
40707// of results to return.
40708func (c *PlacementsListCall) MaxResults(maxResults int64) *PlacementsListCall {
40709	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
40710	return c
40711}
40712
40713// MaxStartDate sets the optional parameter "maxStartDate": Select only
40714// placements or placement groups whose start date is on or before the
40715// specified maxStartDate. The date should be formatted as "yyyy-MM-dd".
40716func (c *PlacementsListCall) MaxStartDate(maxStartDate string) *PlacementsListCall {
40717	c.urlParams_.Set("maxStartDate", maxStartDate)
40718	return c
40719}
40720
40721// MinEndDate sets the optional parameter "minEndDate": Select only
40722// placements or placement groups whose end date is on or after the
40723// specified minEndDate. The date should be formatted as "yyyy-MM-dd".
40724func (c *PlacementsListCall) MinEndDate(minEndDate string) *PlacementsListCall {
40725	c.urlParams_.Set("minEndDate", minEndDate)
40726	return c
40727}
40728
40729// MinStartDate sets the optional parameter "minStartDate": Select only
40730// placements or placement groups whose start date is on or after the
40731// specified minStartDate. The date should be formatted as "yyyy-MM-dd".
40732func (c *PlacementsListCall) MinStartDate(minStartDate string) *PlacementsListCall {
40733	c.urlParams_.Set("minStartDate", minStartDate)
40734	return c
40735}
40736
40737// PageToken sets the optional parameter "pageToken": Value of the
40738// nextPageToken from the previous result page.
40739func (c *PlacementsListCall) PageToken(pageToken string) *PlacementsListCall {
40740	c.urlParams_.Set("pageToken", pageToken)
40741	return c
40742}
40743
40744// PaymentSource sets the optional parameter "paymentSource": Select
40745// only placements with this payment source.
40746//
40747// Possible values:
40748//   "PLACEMENT_AGENCY_PAID"
40749//   "PLACEMENT_PUBLISHER_PAID"
40750func (c *PlacementsListCall) PaymentSource(paymentSource string) *PlacementsListCall {
40751	c.urlParams_.Set("paymentSource", paymentSource)
40752	return c
40753}
40754
40755// PlacementStrategyIds sets the optional parameter
40756// "placementStrategyIds": Select only placements that are associated
40757// with these placement strategies.
40758func (c *PlacementsListCall) PlacementStrategyIds(placementStrategyIds ...int64) *PlacementsListCall {
40759	var placementStrategyIds_ []string
40760	for _, v := range placementStrategyIds {
40761		placementStrategyIds_ = append(placementStrategyIds_, fmt.Sprint(v))
40762	}
40763	c.urlParams_.SetMulti("placementStrategyIds", placementStrategyIds_)
40764	return c
40765}
40766
40767// PricingTypes sets the optional parameter "pricingTypes": Select only
40768// placements with these pricing types.
40769//
40770// Possible values:
40771//   "PRICING_TYPE_CPA"
40772//   "PRICING_TYPE_CPC"
40773//   "PRICING_TYPE_CPM"
40774//   "PRICING_TYPE_CPM_ACTIVEVIEW"
40775//   "PRICING_TYPE_FLAT_RATE_CLICKS"
40776//   "PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
40777func (c *PlacementsListCall) PricingTypes(pricingTypes ...string) *PlacementsListCall {
40778	c.urlParams_.SetMulti("pricingTypes", append([]string{}, pricingTypes...))
40779	return c
40780}
40781
40782// SearchString sets the optional parameter "searchString": Allows
40783// searching for placements by name or ID. Wildcards (*) are allowed.
40784// For example, "placement*2015" will return placements with names like
40785// "placement June 2015", "placement May 2015", or simply "placements
40786// 2015". Most of the searches also add wildcards implicitly at the
40787// start and the end of the search string. For example, a search string
40788// of "placement" will match placements with name "my placement",
40789// "placement 2015", or simply "placement".
40790func (c *PlacementsListCall) SearchString(searchString string) *PlacementsListCall {
40791	c.urlParams_.Set("searchString", searchString)
40792	return c
40793}
40794
40795// SiteIds sets the optional parameter "siteIds": Select only placements
40796// that are associated with these sites.
40797func (c *PlacementsListCall) SiteIds(siteIds ...int64) *PlacementsListCall {
40798	var siteIds_ []string
40799	for _, v := range siteIds {
40800		siteIds_ = append(siteIds_, fmt.Sprint(v))
40801	}
40802	c.urlParams_.SetMulti("siteIds", siteIds_)
40803	return c
40804}
40805
40806// SizeIds sets the optional parameter "sizeIds": Select only placements
40807// that are associated with these sizes.
40808func (c *PlacementsListCall) SizeIds(sizeIds ...int64) *PlacementsListCall {
40809	var sizeIds_ []string
40810	for _, v := range sizeIds {
40811		sizeIds_ = append(sizeIds_, fmt.Sprint(v))
40812	}
40813	c.urlParams_.SetMulti("sizeIds", sizeIds_)
40814	return c
40815}
40816
40817// SortField sets the optional parameter "sortField": Field by which to
40818// sort the list.
40819//
40820// Possible values:
40821//   "ID" (default)
40822//   "NAME"
40823func (c *PlacementsListCall) SortField(sortField string) *PlacementsListCall {
40824	c.urlParams_.Set("sortField", sortField)
40825	return c
40826}
40827
40828// SortOrder sets the optional parameter "sortOrder": Order of sorted
40829// results.
40830//
40831// Possible values:
40832//   "ASCENDING" (default)
40833//   "DESCENDING"
40834func (c *PlacementsListCall) SortOrder(sortOrder string) *PlacementsListCall {
40835	c.urlParams_.Set("sortOrder", sortOrder)
40836	return c
40837}
40838
40839// Fields allows partial responses to be retrieved. See
40840// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40841// for more information.
40842func (c *PlacementsListCall) Fields(s ...googleapi.Field) *PlacementsListCall {
40843	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40844	return c
40845}
40846
40847// IfNoneMatch sets the optional parameter which makes the operation
40848// fail if the object's ETag matches the given value. This is useful for
40849// getting updates only after the object has changed since the last
40850// request. Use googleapi.IsNotModified to check whether the response
40851// error from Do is the result of In-None-Match.
40852func (c *PlacementsListCall) IfNoneMatch(entityTag string) *PlacementsListCall {
40853	c.ifNoneMatch_ = entityTag
40854	return c
40855}
40856
40857// Context sets the context to be used in this call's Do method. Any
40858// pending HTTP request will be aborted if the provided context is
40859// canceled.
40860func (c *PlacementsListCall) Context(ctx context.Context) *PlacementsListCall {
40861	c.ctx_ = ctx
40862	return c
40863}
40864
40865// Header returns an http.Header that can be modified by the caller to
40866// add HTTP headers to the request.
40867func (c *PlacementsListCall) Header() http.Header {
40868	if c.header_ == nil {
40869		c.header_ = make(http.Header)
40870	}
40871	return c.header_
40872}
40873
40874func (c *PlacementsListCall) doRequest(alt string) (*http.Response, error) {
40875	reqHeaders := make(http.Header)
40876	for k, v := range c.header_ {
40877		reqHeaders[k] = v
40878	}
40879	reqHeaders.Set("User-Agent", c.s.userAgent())
40880	if c.ifNoneMatch_ != "" {
40881		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40882	}
40883	var body io.Reader = nil
40884	c.urlParams_.Set("alt", alt)
40885	c.urlParams_.Set("prettyPrint", "false")
40886	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
40887	urls += "?" + c.urlParams_.Encode()
40888	req, err := http.NewRequest("GET", urls, body)
40889	if err != nil {
40890		return nil, err
40891	}
40892	req.Header = reqHeaders
40893	googleapi.Expand(req.URL, map[string]string{
40894		"profileId": strconv.FormatInt(c.profileId, 10),
40895	})
40896	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40897}
40898
40899// Do executes the "dfareporting.placements.list" call.
40900// Exactly one of *PlacementsListResponse or error will be non-nil. Any
40901// non-2xx status code is an error. Response headers are in either
40902// *PlacementsListResponse.ServerResponse.Header or (if a response was
40903// returned at all) in error.(*googleapi.Error).Header. Use
40904// googleapi.IsNotModified to check whether the returned error was
40905// because http.StatusNotModified was returned.
40906func (c *PlacementsListCall) Do(opts ...googleapi.CallOption) (*PlacementsListResponse, error) {
40907	gensupport.SetOptions(c.urlParams_, opts...)
40908	res, err := c.doRequest("json")
40909	if res != nil && res.StatusCode == http.StatusNotModified {
40910		if res.Body != nil {
40911			res.Body.Close()
40912		}
40913		return nil, &googleapi.Error{
40914			Code:   res.StatusCode,
40915			Header: res.Header,
40916		}
40917	}
40918	if err != nil {
40919		return nil, err
40920	}
40921	defer googleapi.CloseBody(res)
40922	if err := googleapi.CheckResponse(res); err != nil {
40923		return nil, err
40924	}
40925	ret := &PlacementsListResponse{
40926		ServerResponse: googleapi.ServerResponse{
40927			Header:         res.Header,
40928			HTTPStatusCode: res.StatusCode,
40929		},
40930	}
40931	target := &ret
40932	if err := gensupport.DecodeResponse(target, res); err != nil {
40933		return nil, err
40934	}
40935	return ret, nil
40936	// {
40937	//   "description": "Retrieves a list of placements, possibly filtered. This method supports paging.",
40938	//   "httpMethod": "GET",
40939	//   "id": "dfareporting.placements.list",
40940	//   "parameterOrder": [
40941	//     "profileId"
40942	//   ],
40943	//   "parameters": {
40944	//     "advertiserIds": {
40945	//       "description": "Select only placements that belong to these advertisers.",
40946	//       "format": "int64",
40947	//       "location": "query",
40948	//       "repeated": true,
40949	//       "type": "string"
40950	//     },
40951	//     "archived": {
40952	//       "description": "Select only archived placements. Don't set this field to select both archived and non-archived placements.",
40953	//       "location": "query",
40954	//       "type": "boolean"
40955	//     },
40956	//     "campaignIds": {
40957	//       "description": "Select only placements that belong to these campaigns.",
40958	//       "format": "int64",
40959	//       "location": "query",
40960	//       "repeated": true,
40961	//       "type": "string"
40962	//     },
40963	//     "compatibilities": {
40964	//       "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.",
40965	//       "enum": [
40966	//         "APP",
40967	//         "APP_INTERSTITIAL",
40968	//         "DISPLAY",
40969	//         "DISPLAY_INTERSTITIAL",
40970	//         "IN_STREAM_AUDIO",
40971	//         "IN_STREAM_VIDEO"
40972	//       ],
40973	//       "enumDescriptions": [
40974	//         "",
40975	//         "",
40976	//         "",
40977	//         "",
40978	//         "",
40979	//         ""
40980	//       ],
40981	//       "location": "query",
40982	//       "repeated": true,
40983	//       "type": "string"
40984	//     },
40985	//     "contentCategoryIds": {
40986	//       "description": "Select only placements that are associated with these content categories.",
40987	//       "format": "int64",
40988	//       "location": "query",
40989	//       "repeated": true,
40990	//       "type": "string"
40991	//     },
40992	//     "directorySiteIds": {
40993	//       "description": "Select only placements that are associated with these directory sites.",
40994	//       "format": "int64",
40995	//       "location": "query",
40996	//       "repeated": true,
40997	//       "type": "string"
40998	//     },
40999	//     "groupIds": {
41000	//       "description": "Select only placements that belong to these placement groups.",
41001	//       "format": "int64",
41002	//       "location": "query",
41003	//       "repeated": true,
41004	//       "type": "string"
41005	//     },
41006	//     "ids": {
41007	//       "description": "Select only placements with these IDs.",
41008	//       "format": "int64",
41009	//       "location": "query",
41010	//       "repeated": true,
41011	//       "type": "string"
41012	//     },
41013	//     "maxEndDate": {
41014	//       "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\".",
41015	//       "location": "query",
41016	//       "type": "string"
41017	//     },
41018	//     "maxResults": {
41019	//       "default": "1000",
41020	//       "description": "Maximum number of results to return.",
41021	//       "format": "int32",
41022	//       "location": "query",
41023	//       "maximum": "1000",
41024	//       "minimum": "0",
41025	//       "type": "integer"
41026	//     },
41027	//     "maxStartDate": {
41028	//       "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\".",
41029	//       "location": "query",
41030	//       "type": "string"
41031	//     },
41032	//     "minEndDate": {
41033	//       "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\".",
41034	//       "location": "query",
41035	//       "type": "string"
41036	//     },
41037	//     "minStartDate": {
41038	//       "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\".",
41039	//       "location": "query",
41040	//       "type": "string"
41041	//     },
41042	//     "pageToken": {
41043	//       "description": "Value of the nextPageToken from the previous result page.",
41044	//       "location": "query",
41045	//       "type": "string"
41046	//     },
41047	//     "paymentSource": {
41048	//       "description": "Select only placements with this payment source.",
41049	//       "enum": [
41050	//         "PLACEMENT_AGENCY_PAID",
41051	//         "PLACEMENT_PUBLISHER_PAID"
41052	//       ],
41053	//       "enumDescriptions": [
41054	//         "",
41055	//         ""
41056	//       ],
41057	//       "location": "query",
41058	//       "type": "string"
41059	//     },
41060	//     "placementStrategyIds": {
41061	//       "description": "Select only placements that are associated with these placement strategies.",
41062	//       "format": "int64",
41063	//       "location": "query",
41064	//       "repeated": true,
41065	//       "type": "string"
41066	//     },
41067	//     "pricingTypes": {
41068	//       "description": "Select only placements with these pricing types.",
41069	//       "enum": [
41070	//         "PRICING_TYPE_CPA",
41071	//         "PRICING_TYPE_CPC",
41072	//         "PRICING_TYPE_CPM",
41073	//         "PRICING_TYPE_CPM_ACTIVEVIEW",
41074	//         "PRICING_TYPE_FLAT_RATE_CLICKS",
41075	//         "PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
41076	//       ],
41077	//       "enumDescriptions": [
41078	//         "",
41079	//         "",
41080	//         "",
41081	//         "",
41082	//         "",
41083	//         ""
41084	//       ],
41085	//       "location": "query",
41086	//       "repeated": true,
41087	//       "type": "string"
41088	//     },
41089	//     "profileId": {
41090	//       "description": "User profile ID associated with this request.",
41091	//       "format": "int64",
41092	//       "location": "path",
41093	//       "required": true,
41094	//       "type": "string"
41095	//     },
41096	//     "searchString": {
41097	//       "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\".",
41098	//       "location": "query",
41099	//       "type": "string"
41100	//     },
41101	//     "siteIds": {
41102	//       "description": "Select only placements that are associated with these sites.",
41103	//       "format": "int64",
41104	//       "location": "query",
41105	//       "repeated": true,
41106	//       "type": "string"
41107	//     },
41108	//     "sizeIds": {
41109	//       "description": "Select only placements that are associated with these sizes.",
41110	//       "format": "int64",
41111	//       "location": "query",
41112	//       "repeated": true,
41113	//       "type": "string"
41114	//     },
41115	//     "sortField": {
41116	//       "default": "ID",
41117	//       "description": "Field by which to sort the list.",
41118	//       "enum": [
41119	//         "ID",
41120	//         "NAME"
41121	//       ],
41122	//       "enumDescriptions": [
41123	//         "",
41124	//         ""
41125	//       ],
41126	//       "location": "query",
41127	//       "type": "string"
41128	//     },
41129	//     "sortOrder": {
41130	//       "default": "ASCENDING",
41131	//       "description": "Order of sorted results.",
41132	//       "enum": [
41133	//         "ASCENDING",
41134	//         "DESCENDING"
41135	//       ],
41136	//       "enumDescriptions": [
41137	//         "",
41138	//         ""
41139	//       ],
41140	//       "location": "query",
41141	//       "type": "string"
41142	//     }
41143	//   },
41144	//   "path": "userprofiles/{profileId}/placements",
41145	//   "response": {
41146	//     "$ref": "PlacementsListResponse"
41147	//   },
41148	//   "scopes": [
41149	//     "https://www.googleapis.com/auth/dfatrafficking"
41150	//   ]
41151	// }
41152
41153}
41154
41155// Pages invokes f for each page of results.
41156// A non-nil error returned from f will halt the iteration.
41157// The provided context supersedes any context provided to the Context method.
41158func (c *PlacementsListCall) Pages(ctx context.Context, f func(*PlacementsListResponse) error) error {
41159	c.ctx_ = ctx
41160	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
41161	for {
41162		x, err := c.Do()
41163		if err != nil {
41164			return err
41165		}
41166		if err := f(x); err != nil {
41167			return err
41168		}
41169		if x.NextPageToken == "" {
41170			return nil
41171		}
41172		c.PageToken(x.NextPageToken)
41173	}
41174}
41175
41176// method id "dfareporting.placements.patch":
41177
41178type PlacementsPatchCall struct {
41179	s          *Service
41180	profileId  int64
41181	placement  *Placement
41182	urlParams_ gensupport.URLParams
41183	ctx_       context.Context
41184	header_    http.Header
41185}
41186
41187// Patch: Updates an existing placement. This method supports patch
41188// semantics.
41189func (r *PlacementsService) Patch(profileId int64, id int64, placement *Placement) *PlacementsPatchCall {
41190	c := &PlacementsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41191	c.profileId = profileId
41192	c.urlParams_.Set("id", fmt.Sprint(id))
41193	c.placement = placement
41194	return c
41195}
41196
41197// Fields allows partial responses to be retrieved. See
41198// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41199// for more information.
41200func (c *PlacementsPatchCall) Fields(s ...googleapi.Field) *PlacementsPatchCall {
41201	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41202	return c
41203}
41204
41205// Context sets the context to be used in this call's Do method. Any
41206// pending HTTP request will be aborted if the provided context is
41207// canceled.
41208func (c *PlacementsPatchCall) Context(ctx context.Context) *PlacementsPatchCall {
41209	c.ctx_ = ctx
41210	return c
41211}
41212
41213// Header returns an http.Header that can be modified by the caller to
41214// add HTTP headers to the request.
41215func (c *PlacementsPatchCall) Header() http.Header {
41216	if c.header_ == nil {
41217		c.header_ = make(http.Header)
41218	}
41219	return c.header_
41220}
41221
41222func (c *PlacementsPatchCall) doRequest(alt string) (*http.Response, error) {
41223	reqHeaders := make(http.Header)
41224	for k, v := range c.header_ {
41225		reqHeaders[k] = v
41226	}
41227	reqHeaders.Set("User-Agent", c.s.userAgent())
41228	var body io.Reader = nil
41229	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
41230	if err != nil {
41231		return nil, err
41232	}
41233	reqHeaders.Set("Content-Type", "application/json")
41234	c.urlParams_.Set("alt", alt)
41235	c.urlParams_.Set("prettyPrint", "false")
41236	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
41237	urls += "?" + c.urlParams_.Encode()
41238	req, err := http.NewRequest("PATCH", urls, body)
41239	if err != nil {
41240		return nil, err
41241	}
41242	req.Header = reqHeaders
41243	googleapi.Expand(req.URL, map[string]string{
41244		"profileId": strconv.FormatInt(c.profileId, 10),
41245	})
41246	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41247}
41248
41249// Do executes the "dfareporting.placements.patch" call.
41250// Exactly one of *Placement or error will be non-nil. Any non-2xx
41251// status code is an error. Response headers are in either
41252// *Placement.ServerResponse.Header or (if a response was returned at
41253// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
41254// to check whether the returned error was because
41255// http.StatusNotModified was returned.
41256func (c *PlacementsPatchCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
41257	gensupport.SetOptions(c.urlParams_, opts...)
41258	res, err := c.doRequest("json")
41259	if res != nil && res.StatusCode == http.StatusNotModified {
41260		if res.Body != nil {
41261			res.Body.Close()
41262		}
41263		return nil, &googleapi.Error{
41264			Code:   res.StatusCode,
41265			Header: res.Header,
41266		}
41267	}
41268	if err != nil {
41269		return nil, err
41270	}
41271	defer googleapi.CloseBody(res)
41272	if err := googleapi.CheckResponse(res); err != nil {
41273		return nil, err
41274	}
41275	ret := &Placement{
41276		ServerResponse: googleapi.ServerResponse{
41277			Header:         res.Header,
41278			HTTPStatusCode: res.StatusCode,
41279		},
41280	}
41281	target := &ret
41282	if err := gensupport.DecodeResponse(target, res); err != nil {
41283		return nil, err
41284	}
41285	return ret, nil
41286	// {
41287	//   "description": "Updates an existing placement. This method supports patch semantics.",
41288	//   "httpMethod": "PATCH",
41289	//   "id": "dfareporting.placements.patch",
41290	//   "parameterOrder": [
41291	//     "profileId",
41292	//     "id"
41293	//   ],
41294	//   "parameters": {
41295	//     "id": {
41296	//       "description": "Placement ID.",
41297	//       "format": "int64",
41298	//       "location": "query",
41299	//       "required": true,
41300	//       "type": "string"
41301	//     },
41302	//     "profileId": {
41303	//       "description": "User profile ID associated with this request.",
41304	//       "format": "int64",
41305	//       "location": "path",
41306	//       "required": true,
41307	//       "type": "string"
41308	//     }
41309	//   },
41310	//   "path": "userprofiles/{profileId}/placements",
41311	//   "request": {
41312	//     "$ref": "Placement"
41313	//   },
41314	//   "response": {
41315	//     "$ref": "Placement"
41316	//   },
41317	//   "scopes": [
41318	//     "https://www.googleapis.com/auth/dfatrafficking"
41319	//   ]
41320	// }
41321
41322}
41323
41324// method id "dfareporting.placements.update":
41325
41326type PlacementsUpdateCall struct {
41327	s          *Service
41328	profileId  int64
41329	placement  *Placement
41330	urlParams_ gensupport.URLParams
41331	ctx_       context.Context
41332	header_    http.Header
41333}
41334
41335// Update: Updates an existing placement.
41336func (r *PlacementsService) Update(profileId int64, placement *Placement) *PlacementsUpdateCall {
41337	c := &PlacementsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41338	c.profileId = profileId
41339	c.placement = placement
41340	return c
41341}
41342
41343// Fields allows partial responses to be retrieved. See
41344// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41345// for more information.
41346func (c *PlacementsUpdateCall) Fields(s ...googleapi.Field) *PlacementsUpdateCall {
41347	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41348	return c
41349}
41350
41351// Context sets the context to be used in this call's Do method. Any
41352// pending HTTP request will be aborted if the provided context is
41353// canceled.
41354func (c *PlacementsUpdateCall) Context(ctx context.Context) *PlacementsUpdateCall {
41355	c.ctx_ = ctx
41356	return c
41357}
41358
41359// Header returns an http.Header that can be modified by the caller to
41360// add HTTP headers to the request.
41361func (c *PlacementsUpdateCall) Header() http.Header {
41362	if c.header_ == nil {
41363		c.header_ = make(http.Header)
41364	}
41365	return c.header_
41366}
41367
41368func (c *PlacementsUpdateCall) doRequest(alt string) (*http.Response, error) {
41369	reqHeaders := make(http.Header)
41370	for k, v := range c.header_ {
41371		reqHeaders[k] = v
41372	}
41373	reqHeaders.Set("User-Agent", c.s.userAgent())
41374	var body io.Reader = nil
41375	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
41376	if err != nil {
41377		return nil, err
41378	}
41379	reqHeaders.Set("Content-Type", "application/json")
41380	c.urlParams_.Set("alt", alt)
41381	c.urlParams_.Set("prettyPrint", "false")
41382	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
41383	urls += "?" + c.urlParams_.Encode()
41384	req, err := http.NewRequest("PUT", urls, body)
41385	if err != nil {
41386		return nil, err
41387	}
41388	req.Header = reqHeaders
41389	googleapi.Expand(req.URL, map[string]string{
41390		"profileId": strconv.FormatInt(c.profileId, 10),
41391	})
41392	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41393}
41394
41395// Do executes the "dfareporting.placements.update" call.
41396// Exactly one of *Placement or error will be non-nil. Any non-2xx
41397// status code is an error. Response headers are in either
41398// *Placement.ServerResponse.Header or (if a response was returned at
41399// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
41400// to check whether the returned error was because
41401// http.StatusNotModified was returned.
41402func (c *PlacementsUpdateCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
41403	gensupport.SetOptions(c.urlParams_, opts...)
41404	res, err := c.doRequest("json")
41405	if res != nil && res.StatusCode == http.StatusNotModified {
41406		if res.Body != nil {
41407			res.Body.Close()
41408		}
41409		return nil, &googleapi.Error{
41410			Code:   res.StatusCode,
41411			Header: res.Header,
41412		}
41413	}
41414	if err != nil {
41415		return nil, err
41416	}
41417	defer googleapi.CloseBody(res)
41418	if err := googleapi.CheckResponse(res); err != nil {
41419		return nil, err
41420	}
41421	ret := &Placement{
41422		ServerResponse: googleapi.ServerResponse{
41423			Header:         res.Header,
41424			HTTPStatusCode: res.StatusCode,
41425		},
41426	}
41427	target := &ret
41428	if err := gensupport.DecodeResponse(target, res); err != nil {
41429		return nil, err
41430	}
41431	return ret, nil
41432	// {
41433	//   "description": "Updates an existing placement.",
41434	//   "httpMethod": "PUT",
41435	//   "id": "dfareporting.placements.update",
41436	//   "parameterOrder": [
41437	//     "profileId"
41438	//   ],
41439	//   "parameters": {
41440	//     "profileId": {
41441	//       "description": "User profile ID associated with this request.",
41442	//       "format": "int64",
41443	//       "location": "path",
41444	//       "required": true,
41445	//       "type": "string"
41446	//     }
41447	//   },
41448	//   "path": "userprofiles/{profileId}/placements",
41449	//   "request": {
41450	//     "$ref": "Placement"
41451	//   },
41452	//   "response": {
41453	//     "$ref": "Placement"
41454	//   },
41455	//   "scopes": [
41456	//     "https://www.googleapis.com/auth/dfatrafficking"
41457	//   ]
41458	// }
41459
41460}
41461
41462// method id "dfareporting.platformTypes.get":
41463
41464type PlatformTypesGetCall struct {
41465	s            *Service
41466	profileId    int64
41467	id           int64
41468	urlParams_   gensupport.URLParams
41469	ifNoneMatch_ string
41470	ctx_         context.Context
41471	header_      http.Header
41472}
41473
41474// Get: Gets one platform type by ID.
41475func (r *PlatformTypesService) Get(profileId int64, id int64) *PlatformTypesGetCall {
41476	c := &PlatformTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41477	c.profileId = profileId
41478	c.id = id
41479	return c
41480}
41481
41482// Fields allows partial responses to be retrieved. See
41483// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41484// for more information.
41485func (c *PlatformTypesGetCall) Fields(s ...googleapi.Field) *PlatformTypesGetCall {
41486	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41487	return c
41488}
41489
41490// IfNoneMatch sets the optional parameter which makes the operation
41491// fail if the object's ETag matches the given value. This is useful for
41492// getting updates only after the object has changed since the last
41493// request. Use googleapi.IsNotModified to check whether the response
41494// error from Do is the result of In-None-Match.
41495func (c *PlatformTypesGetCall) IfNoneMatch(entityTag string) *PlatformTypesGetCall {
41496	c.ifNoneMatch_ = entityTag
41497	return c
41498}
41499
41500// Context sets the context to be used in this call's Do method. Any
41501// pending HTTP request will be aborted if the provided context is
41502// canceled.
41503func (c *PlatformTypesGetCall) Context(ctx context.Context) *PlatformTypesGetCall {
41504	c.ctx_ = ctx
41505	return c
41506}
41507
41508// Header returns an http.Header that can be modified by the caller to
41509// add HTTP headers to the request.
41510func (c *PlatformTypesGetCall) Header() http.Header {
41511	if c.header_ == nil {
41512		c.header_ = make(http.Header)
41513	}
41514	return c.header_
41515}
41516
41517func (c *PlatformTypesGetCall) doRequest(alt string) (*http.Response, error) {
41518	reqHeaders := make(http.Header)
41519	for k, v := range c.header_ {
41520		reqHeaders[k] = v
41521	}
41522	reqHeaders.Set("User-Agent", c.s.userAgent())
41523	if c.ifNoneMatch_ != "" {
41524		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41525	}
41526	var body io.Reader = nil
41527	c.urlParams_.Set("alt", alt)
41528	c.urlParams_.Set("prettyPrint", "false")
41529	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/platformTypes/{id}")
41530	urls += "?" + c.urlParams_.Encode()
41531	req, err := http.NewRequest("GET", urls, body)
41532	if err != nil {
41533		return nil, err
41534	}
41535	req.Header = reqHeaders
41536	googleapi.Expand(req.URL, map[string]string{
41537		"profileId": strconv.FormatInt(c.profileId, 10),
41538		"id":        strconv.FormatInt(c.id, 10),
41539	})
41540	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41541}
41542
41543// Do executes the "dfareporting.platformTypes.get" call.
41544// Exactly one of *PlatformType or error will be non-nil. Any non-2xx
41545// status code is an error. Response headers are in either
41546// *PlatformType.ServerResponse.Header or (if a response was returned at
41547// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
41548// to check whether the returned error was because
41549// http.StatusNotModified was returned.
41550func (c *PlatformTypesGetCall) Do(opts ...googleapi.CallOption) (*PlatformType, error) {
41551	gensupport.SetOptions(c.urlParams_, opts...)
41552	res, err := c.doRequest("json")
41553	if res != nil && res.StatusCode == http.StatusNotModified {
41554		if res.Body != nil {
41555			res.Body.Close()
41556		}
41557		return nil, &googleapi.Error{
41558			Code:   res.StatusCode,
41559			Header: res.Header,
41560		}
41561	}
41562	if err != nil {
41563		return nil, err
41564	}
41565	defer googleapi.CloseBody(res)
41566	if err := googleapi.CheckResponse(res); err != nil {
41567		return nil, err
41568	}
41569	ret := &PlatformType{
41570		ServerResponse: googleapi.ServerResponse{
41571			Header:         res.Header,
41572			HTTPStatusCode: res.StatusCode,
41573		},
41574	}
41575	target := &ret
41576	if err := gensupport.DecodeResponse(target, res); err != nil {
41577		return nil, err
41578	}
41579	return ret, nil
41580	// {
41581	//   "description": "Gets one platform type by ID.",
41582	//   "httpMethod": "GET",
41583	//   "id": "dfareporting.platformTypes.get",
41584	//   "parameterOrder": [
41585	//     "profileId",
41586	//     "id"
41587	//   ],
41588	//   "parameters": {
41589	//     "id": {
41590	//       "description": "Platform type ID.",
41591	//       "format": "int64",
41592	//       "location": "path",
41593	//       "required": true,
41594	//       "type": "string"
41595	//     },
41596	//     "profileId": {
41597	//       "description": "User profile ID associated with this request.",
41598	//       "format": "int64",
41599	//       "location": "path",
41600	//       "required": true,
41601	//       "type": "string"
41602	//     }
41603	//   },
41604	//   "path": "userprofiles/{profileId}/platformTypes/{id}",
41605	//   "response": {
41606	//     "$ref": "PlatformType"
41607	//   },
41608	//   "scopes": [
41609	//     "https://www.googleapis.com/auth/dfatrafficking"
41610	//   ]
41611	// }
41612
41613}
41614
41615// method id "dfareporting.platformTypes.list":
41616
41617type PlatformTypesListCall struct {
41618	s            *Service
41619	profileId    int64
41620	urlParams_   gensupport.URLParams
41621	ifNoneMatch_ string
41622	ctx_         context.Context
41623	header_      http.Header
41624}
41625
41626// List: Retrieves a list of platform types.
41627func (r *PlatformTypesService) List(profileId int64) *PlatformTypesListCall {
41628	c := &PlatformTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41629	c.profileId = profileId
41630	return c
41631}
41632
41633// Fields allows partial responses to be retrieved. See
41634// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41635// for more information.
41636func (c *PlatformTypesListCall) Fields(s ...googleapi.Field) *PlatformTypesListCall {
41637	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41638	return c
41639}
41640
41641// IfNoneMatch sets the optional parameter which makes the operation
41642// fail if the object's ETag matches the given value. This is useful for
41643// getting updates only after the object has changed since the last
41644// request. Use googleapi.IsNotModified to check whether the response
41645// error from Do is the result of In-None-Match.
41646func (c *PlatformTypesListCall) IfNoneMatch(entityTag string) *PlatformTypesListCall {
41647	c.ifNoneMatch_ = entityTag
41648	return c
41649}
41650
41651// Context sets the context to be used in this call's Do method. Any
41652// pending HTTP request will be aborted if the provided context is
41653// canceled.
41654func (c *PlatformTypesListCall) Context(ctx context.Context) *PlatformTypesListCall {
41655	c.ctx_ = ctx
41656	return c
41657}
41658
41659// Header returns an http.Header that can be modified by the caller to
41660// add HTTP headers to the request.
41661func (c *PlatformTypesListCall) Header() http.Header {
41662	if c.header_ == nil {
41663		c.header_ = make(http.Header)
41664	}
41665	return c.header_
41666}
41667
41668func (c *PlatformTypesListCall) doRequest(alt string) (*http.Response, error) {
41669	reqHeaders := make(http.Header)
41670	for k, v := range c.header_ {
41671		reqHeaders[k] = v
41672	}
41673	reqHeaders.Set("User-Agent", c.s.userAgent())
41674	if c.ifNoneMatch_ != "" {
41675		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41676	}
41677	var body io.Reader = nil
41678	c.urlParams_.Set("alt", alt)
41679	c.urlParams_.Set("prettyPrint", "false")
41680	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/platformTypes")
41681	urls += "?" + c.urlParams_.Encode()
41682	req, err := http.NewRequest("GET", urls, body)
41683	if err != nil {
41684		return nil, err
41685	}
41686	req.Header = reqHeaders
41687	googleapi.Expand(req.URL, map[string]string{
41688		"profileId": strconv.FormatInt(c.profileId, 10),
41689	})
41690	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41691}
41692
41693// Do executes the "dfareporting.platformTypes.list" call.
41694// Exactly one of *PlatformTypesListResponse or error will be non-nil.
41695// Any non-2xx status code is an error. Response headers are in either
41696// *PlatformTypesListResponse.ServerResponse.Header or (if a response
41697// was returned at all) in error.(*googleapi.Error).Header. Use
41698// googleapi.IsNotModified to check whether the returned error was
41699// because http.StatusNotModified was returned.
41700func (c *PlatformTypesListCall) Do(opts ...googleapi.CallOption) (*PlatformTypesListResponse, error) {
41701	gensupport.SetOptions(c.urlParams_, opts...)
41702	res, err := c.doRequest("json")
41703	if res != nil && res.StatusCode == http.StatusNotModified {
41704		if res.Body != nil {
41705			res.Body.Close()
41706		}
41707		return nil, &googleapi.Error{
41708			Code:   res.StatusCode,
41709			Header: res.Header,
41710		}
41711	}
41712	if err != nil {
41713		return nil, err
41714	}
41715	defer googleapi.CloseBody(res)
41716	if err := googleapi.CheckResponse(res); err != nil {
41717		return nil, err
41718	}
41719	ret := &PlatformTypesListResponse{
41720		ServerResponse: googleapi.ServerResponse{
41721			Header:         res.Header,
41722			HTTPStatusCode: res.StatusCode,
41723		},
41724	}
41725	target := &ret
41726	if err := gensupport.DecodeResponse(target, res); err != nil {
41727		return nil, err
41728	}
41729	return ret, nil
41730	// {
41731	//   "description": "Retrieves a list of platform types.",
41732	//   "httpMethod": "GET",
41733	//   "id": "dfareporting.platformTypes.list",
41734	//   "parameterOrder": [
41735	//     "profileId"
41736	//   ],
41737	//   "parameters": {
41738	//     "profileId": {
41739	//       "description": "User profile ID associated with this request.",
41740	//       "format": "int64",
41741	//       "location": "path",
41742	//       "required": true,
41743	//       "type": "string"
41744	//     }
41745	//   },
41746	//   "path": "userprofiles/{profileId}/platformTypes",
41747	//   "response": {
41748	//     "$ref": "PlatformTypesListResponse"
41749	//   },
41750	//   "scopes": [
41751	//     "https://www.googleapis.com/auth/dfatrafficking"
41752	//   ]
41753	// }
41754
41755}
41756
41757// method id "dfareporting.postalCodes.get":
41758
41759type PostalCodesGetCall struct {
41760	s            *Service
41761	profileId    int64
41762	code         string
41763	urlParams_   gensupport.URLParams
41764	ifNoneMatch_ string
41765	ctx_         context.Context
41766	header_      http.Header
41767}
41768
41769// Get: Gets one postal code by ID.
41770func (r *PostalCodesService) Get(profileId int64, code string) *PostalCodesGetCall {
41771	c := &PostalCodesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41772	c.profileId = profileId
41773	c.code = code
41774	return c
41775}
41776
41777// Fields allows partial responses to be retrieved. See
41778// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41779// for more information.
41780func (c *PostalCodesGetCall) Fields(s ...googleapi.Field) *PostalCodesGetCall {
41781	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41782	return c
41783}
41784
41785// IfNoneMatch sets the optional parameter which makes the operation
41786// fail if the object's ETag matches the given value. This is useful for
41787// getting updates only after the object has changed since the last
41788// request. Use googleapi.IsNotModified to check whether the response
41789// error from Do is the result of In-None-Match.
41790func (c *PostalCodesGetCall) IfNoneMatch(entityTag string) *PostalCodesGetCall {
41791	c.ifNoneMatch_ = entityTag
41792	return c
41793}
41794
41795// Context sets the context to be used in this call's Do method. Any
41796// pending HTTP request will be aborted if the provided context is
41797// canceled.
41798func (c *PostalCodesGetCall) Context(ctx context.Context) *PostalCodesGetCall {
41799	c.ctx_ = ctx
41800	return c
41801}
41802
41803// Header returns an http.Header that can be modified by the caller to
41804// add HTTP headers to the request.
41805func (c *PostalCodesGetCall) Header() http.Header {
41806	if c.header_ == nil {
41807		c.header_ = make(http.Header)
41808	}
41809	return c.header_
41810}
41811
41812func (c *PostalCodesGetCall) doRequest(alt string) (*http.Response, error) {
41813	reqHeaders := make(http.Header)
41814	for k, v := range c.header_ {
41815		reqHeaders[k] = v
41816	}
41817	reqHeaders.Set("User-Agent", c.s.userAgent())
41818	if c.ifNoneMatch_ != "" {
41819		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41820	}
41821	var body io.Reader = nil
41822	c.urlParams_.Set("alt", alt)
41823	c.urlParams_.Set("prettyPrint", "false")
41824	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/postalCodes/{code}")
41825	urls += "?" + c.urlParams_.Encode()
41826	req, err := http.NewRequest("GET", urls, body)
41827	if err != nil {
41828		return nil, err
41829	}
41830	req.Header = reqHeaders
41831	googleapi.Expand(req.URL, map[string]string{
41832		"profileId": strconv.FormatInt(c.profileId, 10),
41833		"code":      c.code,
41834	})
41835	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41836}
41837
41838// Do executes the "dfareporting.postalCodes.get" call.
41839// Exactly one of *PostalCode or error will be non-nil. Any non-2xx
41840// status code is an error. Response headers are in either
41841// *PostalCode.ServerResponse.Header or (if a response was returned at
41842// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
41843// to check whether the returned error was because
41844// http.StatusNotModified was returned.
41845func (c *PostalCodesGetCall) Do(opts ...googleapi.CallOption) (*PostalCode, error) {
41846	gensupport.SetOptions(c.urlParams_, opts...)
41847	res, err := c.doRequest("json")
41848	if res != nil && res.StatusCode == http.StatusNotModified {
41849		if res.Body != nil {
41850			res.Body.Close()
41851		}
41852		return nil, &googleapi.Error{
41853			Code:   res.StatusCode,
41854			Header: res.Header,
41855		}
41856	}
41857	if err != nil {
41858		return nil, err
41859	}
41860	defer googleapi.CloseBody(res)
41861	if err := googleapi.CheckResponse(res); err != nil {
41862		return nil, err
41863	}
41864	ret := &PostalCode{
41865		ServerResponse: googleapi.ServerResponse{
41866			Header:         res.Header,
41867			HTTPStatusCode: res.StatusCode,
41868		},
41869	}
41870	target := &ret
41871	if err := gensupport.DecodeResponse(target, res); err != nil {
41872		return nil, err
41873	}
41874	return ret, nil
41875	// {
41876	//   "description": "Gets one postal code by ID.",
41877	//   "httpMethod": "GET",
41878	//   "id": "dfareporting.postalCodes.get",
41879	//   "parameterOrder": [
41880	//     "profileId",
41881	//     "code"
41882	//   ],
41883	//   "parameters": {
41884	//     "code": {
41885	//       "description": "Postal code ID.",
41886	//       "location": "path",
41887	//       "required": true,
41888	//       "type": "string"
41889	//     },
41890	//     "profileId": {
41891	//       "description": "User profile ID associated with this request.",
41892	//       "format": "int64",
41893	//       "location": "path",
41894	//       "required": true,
41895	//       "type": "string"
41896	//     }
41897	//   },
41898	//   "path": "userprofiles/{profileId}/postalCodes/{code}",
41899	//   "response": {
41900	//     "$ref": "PostalCode"
41901	//   },
41902	//   "scopes": [
41903	//     "https://www.googleapis.com/auth/dfatrafficking"
41904	//   ]
41905	// }
41906
41907}
41908
41909// method id "dfareporting.postalCodes.list":
41910
41911type PostalCodesListCall struct {
41912	s            *Service
41913	profileId    int64
41914	urlParams_   gensupport.URLParams
41915	ifNoneMatch_ string
41916	ctx_         context.Context
41917	header_      http.Header
41918}
41919
41920// List: Retrieves a list of postal codes.
41921func (r *PostalCodesService) List(profileId int64) *PostalCodesListCall {
41922	c := &PostalCodesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41923	c.profileId = profileId
41924	return c
41925}
41926
41927// Fields allows partial responses to be retrieved. See
41928// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41929// for more information.
41930func (c *PostalCodesListCall) Fields(s ...googleapi.Field) *PostalCodesListCall {
41931	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41932	return c
41933}
41934
41935// IfNoneMatch sets the optional parameter which makes the operation
41936// fail if the object's ETag matches the given value. This is useful for
41937// getting updates only after the object has changed since the last
41938// request. Use googleapi.IsNotModified to check whether the response
41939// error from Do is the result of In-None-Match.
41940func (c *PostalCodesListCall) IfNoneMatch(entityTag string) *PostalCodesListCall {
41941	c.ifNoneMatch_ = entityTag
41942	return c
41943}
41944
41945// Context sets the context to be used in this call's Do method. Any
41946// pending HTTP request will be aborted if the provided context is
41947// canceled.
41948func (c *PostalCodesListCall) Context(ctx context.Context) *PostalCodesListCall {
41949	c.ctx_ = ctx
41950	return c
41951}
41952
41953// Header returns an http.Header that can be modified by the caller to
41954// add HTTP headers to the request.
41955func (c *PostalCodesListCall) Header() http.Header {
41956	if c.header_ == nil {
41957		c.header_ = make(http.Header)
41958	}
41959	return c.header_
41960}
41961
41962func (c *PostalCodesListCall) doRequest(alt string) (*http.Response, error) {
41963	reqHeaders := make(http.Header)
41964	for k, v := range c.header_ {
41965		reqHeaders[k] = v
41966	}
41967	reqHeaders.Set("User-Agent", c.s.userAgent())
41968	if c.ifNoneMatch_ != "" {
41969		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41970	}
41971	var body io.Reader = nil
41972	c.urlParams_.Set("alt", alt)
41973	c.urlParams_.Set("prettyPrint", "false")
41974	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/postalCodes")
41975	urls += "?" + c.urlParams_.Encode()
41976	req, err := http.NewRequest("GET", urls, body)
41977	if err != nil {
41978		return nil, err
41979	}
41980	req.Header = reqHeaders
41981	googleapi.Expand(req.URL, map[string]string{
41982		"profileId": strconv.FormatInt(c.profileId, 10),
41983	})
41984	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41985}
41986
41987// Do executes the "dfareporting.postalCodes.list" call.
41988// Exactly one of *PostalCodesListResponse or error will be non-nil. Any
41989// non-2xx status code is an error. Response headers are in either
41990// *PostalCodesListResponse.ServerResponse.Header or (if a response was
41991// returned at all) in error.(*googleapi.Error).Header. Use
41992// googleapi.IsNotModified to check whether the returned error was
41993// because http.StatusNotModified was returned.
41994func (c *PostalCodesListCall) Do(opts ...googleapi.CallOption) (*PostalCodesListResponse, error) {
41995	gensupport.SetOptions(c.urlParams_, opts...)
41996	res, err := c.doRequest("json")
41997	if res != nil && res.StatusCode == http.StatusNotModified {
41998		if res.Body != nil {
41999			res.Body.Close()
42000		}
42001		return nil, &googleapi.Error{
42002			Code:   res.StatusCode,
42003			Header: res.Header,
42004		}
42005	}
42006	if err != nil {
42007		return nil, err
42008	}
42009	defer googleapi.CloseBody(res)
42010	if err := googleapi.CheckResponse(res); err != nil {
42011		return nil, err
42012	}
42013	ret := &PostalCodesListResponse{
42014		ServerResponse: googleapi.ServerResponse{
42015			Header:         res.Header,
42016			HTTPStatusCode: res.StatusCode,
42017		},
42018	}
42019	target := &ret
42020	if err := gensupport.DecodeResponse(target, res); err != nil {
42021		return nil, err
42022	}
42023	return ret, nil
42024	// {
42025	//   "description": "Retrieves a list of postal codes.",
42026	//   "httpMethod": "GET",
42027	//   "id": "dfareporting.postalCodes.list",
42028	//   "parameterOrder": [
42029	//     "profileId"
42030	//   ],
42031	//   "parameters": {
42032	//     "profileId": {
42033	//       "description": "User profile ID associated with this request.",
42034	//       "format": "int64",
42035	//       "location": "path",
42036	//       "required": true,
42037	//       "type": "string"
42038	//     }
42039	//   },
42040	//   "path": "userprofiles/{profileId}/postalCodes",
42041	//   "response": {
42042	//     "$ref": "PostalCodesListResponse"
42043	//   },
42044	//   "scopes": [
42045	//     "https://www.googleapis.com/auth/dfatrafficking"
42046	//   ]
42047	// }
42048
42049}
42050
42051// method id "dfareporting.projects.get":
42052
42053type ProjectsGetCall struct {
42054	s            *Service
42055	profileId    int64
42056	id           int64
42057	urlParams_   gensupport.URLParams
42058	ifNoneMatch_ string
42059	ctx_         context.Context
42060	header_      http.Header
42061}
42062
42063// Get: Gets one project by ID.
42064func (r *ProjectsService) Get(profileId int64, id int64) *ProjectsGetCall {
42065	c := &ProjectsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42066	c.profileId = profileId
42067	c.id = id
42068	return c
42069}
42070
42071// Fields allows partial responses to be retrieved. See
42072// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42073// for more information.
42074func (c *ProjectsGetCall) Fields(s ...googleapi.Field) *ProjectsGetCall {
42075	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42076	return c
42077}
42078
42079// IfNoneMatch sets the optional parameter which makes the operation
42080// fail if the object's ETag matches the given value. This is useful for
42081// getting updates only after the object has changed since the last
42082// request. Use googleapi.IsNotModified to check whether the response
42083// error from Do is the result of In-None-Match.
42084func (c *ProjectsGetCall) IfNoneMatch(entityTag string) *ProjectsGetCall {
42085	c.ifNoneMatch_ = entityTag
42086	return c
42087}
42088
42089// Context sets the context to be used in this call's Do method. Any
42090// pending HTTP request will be aborted if the provided context is
42091// canceled.
42092func (c *ProjectsGetCall) Context(ctx context.Context) *ProjectsGetCall {
42093	c.ctx_ = ctx
42094	return c
42095}
42096
42097// Header returns an http.Header that can be modified by the caller to
42098// add HTTP headers to the request.
42099func (c *ProjectsGetCall) Header() http.Header {
42100	if c.header_ == nil {
42101		c.header_ = make(http.Header)
42102	}
42103	return c.header_
42104}
42105
42106func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) {
42107	reqHeaders := make(http.Header)
42108	for k, v := range c.header_ {
42109		reqHeaders[k] = v
42110	}
42111	reqHeaders.Set("User-Agent", c.s.userAgent())
42112	if c.ifNoneMatch_ != "" {
42113		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42114	}
42115	var body io.Reader = nil
42116	c.urlParams_.Set("alt", alt)
42117	c.urlParams_.Set("prettyPrint", "false")
42118	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{id}")
42119	urls += "?" + c.urlParams_.Encode()
42120	req, err := http.NewRequest("GET", urls, body)
42121	if err != nil {
42122		return nil, err
42123	}
42124	req.Header = reqHeaders
42125	googleapi.Expand(req.URL, map[string]string{
42126		"profileId": strconv.FormatInt(c.profileId, 10),
42127		"id":        strconv.FormatInt(c.id, 10),
42128	})
42129	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42130}
42131
42132// Do executes the "dfareporting.projects.get" call.
42133// Exactly one of *Project or error will be non-nil. Any non-2xx status
42134// code is an error. Response headers are in either
42135// *Project.ServerResponse.Header or (if a response was returned at all)
42136// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
42137// check whether the returned error was because http.StatusNotModified
42138// was returned.
42139func (c *ProjectsGetCall) Do(opts ...googleapi.CallOption) (*Project, error) {
42140	gensupport.SetOptions(c.urlParams_, opts...)
42141	res, err := c.doRequest("json")
42142	if res != nil && res.StatusCode == http.StatusNotModified {
42143		if res.Body != nil {
42144			res.Body.Close()
42145		}
42146		return nil, &googleapi.Error{
42147			Code:   res.StatusCode,
42148			Header: res.Header,
42149		}
42150	}
42151	if err != nil {
42152		return nil, err
42153	}
42154	defer googleapi.CloseBody(res)
42155	if err := googleapi.CheckResponse(res); err != nil {
42156		return nil, err
42157	}
42158	ret := &Project{
42159		ServerResponse: googleapi.ServerResponse{
42160			Header:         res.Header,
42161			HTTPStatusCode: res.StatusCode,
42162		},
42163	}
42164	target := &ret
42165	if err := gensupport.DecodeResponse(target, res); err != nil {
42166		return nil, err
42167	}
42168	return ret, nil
42169	// {
42170	//   "description": "Gets one project by ID.",
42171	//   "httpMethod": "GET",
42172	//   "id": "dfareporting.projects.get",
42173	//   "parameterOrder": [
42174	//     "profileId",
42175	//     "id"
42176	//   ],
42177	//   "parameters": {
42178	//     "id": {
42179	//       "description": "Project ID.",
42180	//       "format": "int64",
42181	//       "location": "path",
42182	//       "required": true,
42183	//       "type": "string"
42184	//     },
42185	//     "profileId": {
42186	//       "description": "User profile ID associated with this request.",
42187	//       "format": "int64",
42188	//       "location": "path",
42189	//       "required": true,
42190	//       "type": "string"
42191	//     }
42192	//   },
42193	//   "path": "userprofiles/{profileId}/projects/{id}",
42194	//   "response": {
42195	//     "$ref": "Project"
42196	//   },
42197	//   "scopes": [
42198	//     "https://www.googleapis.com/auth/dfatrafficking"
42199	//   ]
42200	// }
42201
42202}
42203
42204// method id "dfareporting.projects.list":
42205
42206type ProjectsListCall struct {
42207	s            *Service
42208	profileId    int64
42209	urlParams_   gensupport.URLParams
42210	ifNoneMatch_ string
42211	ctx_         context.Context
42212	header_      http.Header
42213}
42214
42215// List: Retrieves a list of projects, possibly filtered. This method
42216// supports paging.
42217func (r *ProjectsService) List(profileId int64) *ProjectsListCall {
42218	c := &ProjectsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42219	c.profileId = profileId
42220	return c
42221}
42222
42223// AdvertiserIds sets the optional parameter "advertiserIds": Select
42224// only projects with these advertiser IDs.
42225func (c *ProjectsListCall) AdvertiserIds(advertiserIds ...int64) *ProjectsListCall {
42226	var advertiserIds_ []string
42227	for _, v := range advertiserIds {
42228		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
42229	}
42230	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
42231	return c
42232}
42233
42234// Ids sets the optional parameter "ids": Select only projects with
42235// these IDs.
42236func (c *ProjectsListCall) Ids(ids ...int64) *ProjectsListCall {
42237	var ids_ []string
42238	for _, v := range ids {
42239		ids_ = append(ids_, fmt.Sprint(v))
42240	}
42241	c.urlParams_.SetMulti("ids", ids_)
42242	return c
42243}
42244
42245// MaxResults sets the optional parameter "maxResults": Maximum number
42246// of results to return.
42247func (c *ProjectsListCall) MaxResults(maxResults int64) *ProjectsListCall {
42248	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
42249	return c
42250}
42251
42252// PageToken sets the optional parameter "pageToken": Value of the
42253// nextPageToken from the previous result page.
42254func (c *ProjectsListCall) PageToken(pageToken string) *ProjectsListCall {
42255	c.urlParams_.Set("pageToken", pageToken)
42256	return c
42257}
42258
42259// SearchString sets the optional parameter "searchString": Allows
42260// searching for projects by name or ID. Wildcards (*) are allowed. For
42261// example, "project*2015" will return projects with names like "project
42262// June 2015", "project April 2015", or simply "project 2015". Most of
42263// the searches also add wildcards implicitly at the start and the end
42264// of the search string. For example, a search string of "project" will
42265// match projects with name "my project", "project 2015", or simply
42266// "project".
42267func (c *ProjectsListCall) SearchString(searchString string) *ProjectsListCall {
42268	c.urlParams_.Set("searchString", searchString)
42269	return c
42270}
42271
42272// SortField sets the optional parameter "sortField": Field by which to
42273// sort the list.
42274//
42275// Possible values:
42276//   "ID" (default)
42277//   "NAME"
42278func (c *ProjectsListCall) SortField(sortField string) *ProjectsListCall {
42279	c.urlParams_.Set("sortField", sortField)
42280	return c
42281}
42282
42283// SortOrder sets the optional parameter "sortOrder": Order of sorted
42284// results.
42285//
42286// Possible values:
42287//   "ASCENDING" (default)
42288//   "DESCENDING"
42289func (c *ProjectsListCall) SortOrder(sortOrder string) *ProjectsListCall {
42290	c.urlParams_.Set("sortOrder", sortOrder)
42291	return c
42292}
42293
42294// Fields allows partial responses to be retrieved. See
42295// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42296// for more information.
42297func (c *ProjectsListCall) Fields(s ...googleapi.Field) *ProjectsListCall {
42298	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42299	return c
42300}
42301
42302// IfNoneMatch sets the optional parameter which makes the operation
42303// fail if the object's ETag matches the given value. This is useful for
42304// getting updates only after the object has changed since the last
42305// request. Use googleapi.IsNotModified to check whether the response
42306// error from Do is the result of In-None-Match.
42307func (c *ProjectsListCall) IfNoneMatch(entityTag string) *ProjectsListCall {
42308	c.ifNoneMatch_ = entityTag
42309	return c
42310}
42311
42312// Context sets the context to be used in this call's Do method. Any
42313// pending HTTP request will be aborted if the provided context is
42314// canceled.
42315func (c *ProjectsListCall) Context(ctx context.Context) *ProjectsListCall {
42316	c.ctx_ = ctx
42317	return c
42318}
42319
42320// Header returns an http.Header that can be modified by the caller to
42321// add HTTP headers to the request.
42322func (c *ProjectsListCall) Header() http.Header {
42323	if c.header_ == nil {
42324		c.header_ = make(http.Header)
42325	}
42326	return c.header_
42327}
42328
42329func (c *ProjectsListCall) doRequest(alt string) (*http.Response, error) {
42330	reqHeaders := make(http.Header)
42331	for k, v := range c.header_ {
42332		reqHeaders[k] = v
42333	}
42334	reqHeaders.Set("User-Agent", c.s.userAgent())
42335	if c.ifNoneMatch_ != "" {
42336		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42337	}
42338	var body io.Reader = nil
42339	c.urlParams_.Set("alt", alt)
42340	c.urlParams_.Set("prettyPrint", "false")
42341	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects")
42342	urls += "?" + c.urlParams_.Encode()
42343	req, err := http.NewRequest("GET", urls, body)
42344	if err != nil {
42345		return nil, err
42346	}
42347	req.Header = reqHeaders
42348	googleapi.Expand(req.URL, map[string]string{
42349		"profileId": strconv.FormatInt(c.profileId, 10),
42350	})
42351	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42352}
42353
42354// Do executes the "dfareporting.projects.list" call.
42355// Exactly one of *ProjectsListResponse or error will be non-nil. Any
42356// non-2xx status code is an error. Response headers are in either
42357// *ProjectsListResponse.ServerResponse.Header or (if a response was
42358// returned at all) in error.(*googleapi.Error).Header. Use
42359// googleapi.IsNotModified to check whether the returned error was
42360// because http.StatusNotModified was returned.
42361func (c *ProjectsListCall) Do(opts ...googleapi.CallOption) (*ProjectsListResponse, error) {
42362	gensupport.SetOptions(c.urlParams_, opts...)
42363	res, err := c.doRequest("json")
42364	if res != nil && res.StatusCode == http.StatusNotModified {
42365		if res.Body != nil {
42366			res.Body.Close()
42367		}
42368		return nil, &googleapi.Error{
42369			Code:   res.StatusCode,
42370			Header: res.Header,
42371		}
42372	}
42373	if err != nil {
42374		return nil, err
42375	}
42376	defer googleapi.CloseBody(res)
42377	if err := googleapi.CheckResponse(res); err != nil {
42378		return nil, err
42379	}
42380	ret := &ProjectsListResponse{
42381		ServerResponse: googleapi.ServerResponse{
42382			Header:         res.Header,
42383			HTTPStatusCode: res.StatusCode,
42384		},
42385	}
42386	target := &ret
42387	if err := gensupport.DecodeResponse(target, res); err != nil {
42388		return nil, err
42389	}
42390	return ret, nil
42391	// {
42392	//   "description": "Retrieves a list of projects, possibly filtered. This method supports paging.",
42393	//   "httpMethod": "GET",
42394	//   "id": "dfareporting.projects.list",
42395	//   "parameterOrder": [
42396	//     "profileId"
42397	//   ],
42398	//   "parameters": {
42399	//     "advertiserIds": {
42400	//       "description": "Select only projects with these advertiser IDs.",
42401	//       "format": "int64",
42402	//       "location": "query",
42403	//       "repeated": true,
42404	//       "type": "string"
42405	//     },
42406	//     "ids": {
42407	//       "description": "Select only projects with these IDs.",
42408	//       "format": "int64",
42409	//       "location": "query",
42410	//       "repeated": true,
42411	//       "type": "string"
42412	//     },
42413	//     "maxResults": {
42414	//       "default": "1000",
42415	//       "description": "Maximum number of results to return.",
42416	//       "format": "int32",
42417	//       "location": "query",
42418	//       "maximum": "1000",
42419	//       "minimum": "0",
42420	//       "type": "integer"
42421	//     },
42422	//     "pageToken": {
42423	//       "description": "Value of the nextPageToken from the previous result page.",
42424	//       "location": "query",
42425	//       "type": "string"
42426	//     },
42427	//     "profileId": {
42428	//       "description": "User profile ID associated with this request.",
42429	//       "format": "int64",
42430	//       "location": "path",
42431	//       "required": true,
42432	//       "type": "string"
42433	//     },
42434	//     "searchString": {
42435	//       "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\".",
42436	//       "location": "query",
42437	//       "type": "string"
42438	//     },
42439	//     "sortField": {
42440	//       "default": "ID",
42441	//       "description": "Field by which to sort the list.",
42442	//       "enum": [
42443	//         "ID",
42444	//         "NAME"
42445	//       ],
42446	//       "enumDescriptions": [
42447	//         "",
42448	//         ""
42449	//       ],
42450	//       "location": "query",
42451	//       "type": "string"
42452	//     },
42453	//     "sortOrder": {
42454	//       "default": "ASCENDING",
42455	//       "description": "Order of sorted results.",
42456	//       "enum": [
42457	//         "ASCENDING",
42458	//         "DESCENDING"
42459	//       ],
42460	//       "enumDescriptions": [
42461	//         "",
42462	//         ""
42463	//       ],
42464	//       "location": "query",
42465	//       "type": "string"
42466	//     }
42467	//   },
42468	//   "path": "userprofiles/{profileId}/projects",
42469	//   "response": {
42470	//     "$ref": "ProjectsListResponse"
42471	//   },
42472	//   "scopes": [
42473	//     "https://www.googleapis.com/auth/dfatrafficking"
42474	//   ]
42475	// }
42476
42477}
42478
42479// Pages invokes f for each page of results.
42480// A non-nil error returned from f will halt the iteration.
42481// The provided context supersedes any context provided to the Context method.
42482func (c *ProjectsListCall) Pages(ctx context.Context, f func(*ProjectsListResponse) error) error {
42483	c.ctx_ = ctx
42484	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
42485	for {
42486		x, err := c.Do()
42487		if err != nil {
42488			return err
42489		}
42490		if err := f(x); err != nil {
42491			return err
42492		}
42493		if x.NextPageToken == "" {
42494			return nil
42495		}
42496		c.PageToken(x.NextPageToken)
42497	}
42498}
42499
42500// method id "dfareporting.regions.list":
42501
42502type RegionsListCall struct {
42503	s            *Service
42504	profileId    int64
42505	urlParams_   gensupport.URLParams
42506	ifNoneMatch_ string
42507	ctx_         context.Context
42508	header_      http.Header
42509}
42510
42511// List: Retrieves a list of regions.
42512func (r *RegionsService) List(profileId int64) *RegionsListCall {
42513	c := &RegionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42514	c.profileId = profileId
42515	return c
42516}
42517
42518// Fields allows partial responses to be retrieved. See
42519// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42520// for more information.
42521func (c *RegionsListCall) Fields(s ...googleapi.Field) *RegionsListCall {
42522	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42523	return c
42524}
42525
42526// IfNoneMatch sets the optional parameter which makes the operation
42527// fail if the object's ETag matches the given value. This is useful for
42528// getting updates only after the object has changed since the last
42529// request. Use googleapi.IsNotModified to check whether the response
42530// error from Do is the result of In-None-Match.
42531func (c *RegionsListCall) IfNoneMatch(entityTag string) *RegionsListCall {
42532	c.ifNoneMatch_ = entityTag
42533	return c
42534}
42535
42536// Context sets the context to be used in this call's Do method. Any
42537// pending HTTP request will be aborted if the provided context is
42538// canceled.
42539func (c *RegionsListCall) Context(ctx context.Context) *RegionsListCall {
42540	c.ctx_ = ctx
42541	return c
42542}
42543
42544// Header returns an http.Header that can be modified by the caller to
42545// add HTTP headers to the request.
42546func (c *RegionsListCall) Header() http.Header {
42547	if c.header_ == nil {
42548		c.header_ = make(http.Header)
42549	}
42550	return c.header_
42551}
42552
42553func (c *RegionsListCall) doRequest(alt string) (*http.Response, error) {
42554	reqHeaders := make(http.Header)
42555	for k, v := range c.header_ {
42556		reqHeaders[k] = v
42557	}
42558	reqHeaders.Set("User-Agent", c.s.userAgent())
42559	if c.ifNoneMatch_ != "" {
42560		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42561	}
42562	var body io.Reader = nil
42563	c.urlParams_.Set("alt", alt)
42564	c.urlParams_.Set("prettyPrint", "false")
42565	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/regions")
42566	urls += "?" + c.urlParams_.Encode()
42567	req, err := http.NewRequest("GET", urls, body)
42568	if err != nil {
42569		return nil, err
42570	}
42571	req.Header = reqHeaders
42572	googleapi.Expand(req.URL, map[string]string{
42573		"profileId": strconv.FormatInt(c.profileId, 10),
42574	})
42575	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42576}
42577
42578// Do executes the "dfareporting.regions.list" call.
42579// Exactly one of *RegionsListResponse or error will be non-nil. Any
42580// non-2xx status code is an error. Response headers are in either
42581// *RegionsListResponse.ServerResponse.Header or (if a response was
42582// returned at all) in error.(*googleapi.Error).Header. Use
42583// googleapi.IsNotModified to check whether the returned error was
42584// because http.StatusNotModified was returned.
42585func (c *RegionsListCall) Do(opts ...googleapi.CallOption) (*RegionsListResponse, error) {
42586	gensupport.SetOptions(c.urlParams_, opts...)
42587	res, err := c.doRequest("json")
42588	if res != nil && res.StatusCode == http.StatusNotModified {
42589		if res.Body != nil {
42590			res.Body.Close()
42591		}
42592		return nil, &googleapi.Error{
42593			Code:   res.StatusCode,
42594			Header: res.Header,
42595		}
42596	}
42597	if err != nil {
42598		return nil, err
42599	}
42600	defer googleapi.CloseBody(res)
42601	if err := googleapi.CheckResponse(res); err != nil {
42602		return nil, err
42603	}
42604	ret := &RegionsListResponse{
42605		ServerResponse: googleapi.ServerResponse{
42606			Header:         res.Header,
42607			HTTPStatusCode: res.StatusCode,
42608		},
42609	}
42610	target := &ret
42611	if err := gensupport.DecodeResponse(target, res); err != nil {
42612		return nil, err
42613	}
42614	return ret, nil
42615	// {
42616	//   "description": "Retrieves a list of regions.",
42617	//   "httpMethod": "GET",
42618	//   "id": "dfareporting.regions.list",
42619	//   "parameterOrder": [
42620	//     "profileId"
42621	//   ],
42622	//   "parameters": {
42623	//     "profileId": {
42624	//       "description": "User profile ID associated with this request.",
42625	//       "format": "int64",
42626	//       "location": "path",
42627	//       "required": true,
42628	//       "type": "string"
42629	//     }
42630	//   },
42631	//   "path": "userprofiles/{profileId}/regions",
42632	//   "response": {
42633	//     "$ref": "RegionsListResponse"
42634	//   },
42635	//   "scopes": [
42636	//     "https://www.googleapis.com/auth/dfatrafficking"
42637	//   ]
42638	// }
42639
42640}
42641
42642// method id "dfareporting.remarketingListShares.get":
42643
42644type RemarketingListSharesGetCall struct {
42645	s                 *Service
42646	profileId         int64
42647	remarketingListId int64
42648	urlParams_        gensupport.URLParams
42649	ifNoneMatch_      string
42650	ctx_              context.Context
42651	header_           http.Header
42652}
42653
42654// Get: Gets one remarketing list share by remarketing list ID.
42655func (r *RemarketingListSharesService) Get(profileId int64, remarketingListId int64) *RemarketingListSharesGetCall {
42656	c := &RemarketingListSharesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42657	c.profileId = profileId
42658	c.remarketingListId = remarketingListId
42659	return c
42660}
42661
42662// Fields allows partial responses to be retrieved. See
42663// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42664// for more information.
42665func (c *RemarketingListSharesGetCall) Fields(s ...googleapi.Field) *RemarketingListSharesGetCall {
42666	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42667	return c
42668}
42669
42670// IfNoneMatch sets the optional parameter which makes the operation
42671// fail if the object's ETag matches the given value. This is useful for
42672// getting updates only after the object has changed since the last
42673// request. Use googleapi.IsNotModified to check whether the response
42674// error from Do is the result of In-None-Match.
42675func (c *RemarketingListSharesGetCall) IfNoneMatch(entityTag string) *RemarketingListSharesGetCall {
42676	c.ifNoneMatch_ = entityTag
42677	return c
42678}
42679
42680// Context sets the context to be used in this call's Do method. Any
42681// pending HTTP request will be aborted if the provided context is
42682// canceled.
42683func (c *RemarketingListSharesGetCall) Context(ctx context.Context) *RemarketingListSharesGetCall {
42684	c.ctx_ = ctx
42685	return c
42686}
42687
42688// Header returns an http.Header that can be modified by the caller to
42689// add HTTP headers to the request.
42690func (c *RemarketingListSharesGetCall) Header() http.Header {
42691	if c.header_ == nil {
42692		c.header_ = make(http.Header)
42693	}
42694	return c.header_
42695}
42696
42697func (c *RemarketingListSharesGetCall) doRequest(alt string) (*http.Response, error) {
42698	reqHeaders := make(http.Header)
42699	for k, v := range c.header_ {
42700		reqHeaders[k] = v
42701	}
42702	reqHeaders.Set("User-Agent", c.s.userAgent())
42703	if c.ifNoneMatch_ != "" {
42704		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42705	}
42706	var body io.Reader = nil
42707	c.urlParams_.Set("alt", alt)
42708	c.urlParams_.Set("prettyPrint", "false")
42709	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares/{remarketingListId}")
42710	urls += "?" + c.urlParams_.Encode()
42711	req, err := http.NewRequest("GET", urls, body)
42712	if err != nil {
42713		return nil, err
42714	}
42715	req.Header = reqHeaders
42716	googleapi.Expand(req.URL, map[string]string{
42717		"profileId":         strconv.FormatInt(c.profileId, 10),
42718		"remarketingListId": strconv.FormatInt(c.remarketingListId, 10),
42719	})
42720	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42721}
42722
42723// Do executes the "dfareporting.remarketingListShares.get" call.
42724// Exactly one of *RemarketingListShare or error will be non-nil. Any
42725// non-2xx status code is an error. Response headers are in either
42726// *RemarketingListShare.ServerResponse.Header or (if a response was
42727// returned at all) in error.(*googleapi.Error).Header. Use
42728// googleapi.IsNotModified to check whether the returned error was
42729// because http.StatusNotModified was returned.
42730func (c *RemarketingListSharesGetCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
42731	gensupport.SetOptions(c.urlParams_, opts...)
42732	res, err := c.doRequest("json")
42733	if res != nil && res.StatusCode == http.StatusNotModified {
42734		if res.Body != nil {
42735			res.Body.Close()
42736		}
42737		return nil, &googleapi.Error{
42738			Code:   res.StatusCode,
42739			Header: res.Header,
42740		}
42741	}
42742	if err != nil {
42743		return nil, err
42744	}
42745	defer googleapi.CloseBody(res)
42746	if err := googleapi.CheckResponse(res); err != nil {
42747		return nil, err
42748	}
42749	ret := &RemarketingListShare{
42750		ServerResponse: googleapi.ServerResponse{
42751			Header:         res.Header,
42752			HTTPStatusCode: res.StatusCode,
42753		},
42754	}
42755	target := &ret
42756	if err := gensupport.DecodeResponse(target, res); err != nil {
42757		return nil, err
42758	}
42759	return ret, nil
42760	// {
42761	//   "description": "Gets one remarketing list share by remarketing list ID.",
42762	//   "httpMethod": "GET",
42763	//   "id": "dfareporting.remarketingListShares.get",
42764	//   "parameterOrder": [
42765	//     "profileId",
42766	//     "remarketingListId"
42767	//   ],
42768	//   "parameters": {
42769	//     "profileId": {
42770	//       "description": "User profile ID associated with this request.",
42771	//       "format": "int64",
42772	//       "location": "path",
42773	//       "required": true,
42774	//       "type": "string"
42775	//     },
42776	//     "remarketingListId": {
42777	//       "description": "Remarketing list ID.",
42778	//       "format": "int64",
42779	//       "location": "path",
42780	//       "required": true,
42781	//       "type": "string"
42782	//     }
42783	//   },
42784	//   "path": "userprofiles/{profileId}/remarketingListShares/{remarketingListId}",
42785	//   "response": {
42786	//     "$ref": "RemarketingListShare"
42787	//   },
42788	//   "scopes": [
42789	//     "https://www.googleapis.com/auth/dfatrafficking"
42790	//   ]
42791	// }
42792
42793}
42794
42795// method id "dfareporting.remarketingListShares.patch":
42796
42797type RemarketingListSharesPatchCall struct {
42798	s                    *Service
42799	profileId            int64
42800	remarketinglistshare *RemarketingListShare
42801	urlParams_           gensupport.URLParams
42802	ctx_                 context.Context
42803	header_              http.Header
42804}
42805
42806// Patch: Updates an existing remarketing list share. This method
42807// supports patch semantics.
42808func (r *RemarketingListSharesService) Patch(profileId int64, remarketingListId int64, remarketinglistshare *RemarketingListShare) *RemarketingListSharesPatchCall {
42809	c := &RemarketingListSharesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42810	c.profileId = profileId
42811	c.urlParams_.Set("remarketingListId", fmt.Sprint(remarketingListId))
42812	c.remarketinglistshare = remarketinglistshare
42813	return c
42814}
42815
42816// Fields allows partial responses to be retrieved. See
42817// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42818// for more information.
42819func (c *RemarketingListSharesPatchCall) Fields(s ...googleapi.Field) *RemarketingListSharesPatchCall {
42820	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42821	return c
42822}
42823
42824// Context sets the context to be used in this call's Do method. Any
42825// pending HTTP request will be aborted if the provided context is
42826// canceled.
42827func (c *RemarketingListSharesPatchCall) Context(ctx context.Context) *RemarketingListSharesPatchCall {
42828	c.ctx_ = ctx
42829	return c
42830}
42831
42832// Header returns an http.Header that can be modified by the caller to
42833// add HTTP headers to the request.
42834func (c *RemarketingListSharesPatchCall) Header() http.Header {
42835	if c.header_ == nil {
42836		c.header_ = make(http.Header)
42837	}
42838	return c.header_
42839}
42840
42841func (c *RemarketingListSharesPatchCall) doRequest(alt string) (*http.Response, error) {
42842	reqHeaders := make(http.Header)
42843	for k, v := range c.header_ {
42844		reqHeaders[k] = v
42845	}
42846	reqHeaders.Set("User-Agent", c.s.userAgent())
42847	var body io.Reader = nil
42848	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglistshare)
42849	if err != nil {
42850		return nil, err
42851	}
42852	reqHeaders.Set("Content-Type", "application/json")
42853	c.urlParams_.Set("alt", alt)
42854	c.urlParams_.Set("prettyPrint", "false")
42855	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares")
42856	urls += "?" + c.urlParams_.Encode()
42857	req, err := http.NewRequest("PATCH", urls, body)
42858	if err != nil {
42859		return nil, err
42860	}
42861	req.Header = reqHeaders
42862	googleapi.Expand(req.URL, map[string]string{
42863		"profileId": strconv.FormatInt(c.profileId, 10),
42864	})
42865	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42866}
42867
42868// Do executes the "dfareporting.remarketingListShares.patch" call.
42869// Exactly one of *RemarketingListShare or error will be non-nil. Any
42870// non-2xx status code is an error. Response headers are in either
42871// *RemarketingListShare.ServerResponse.Header or (if a response was
42872// returned at all) in error.(*googleapi.Error).Header. Use
42873// googleapi.IsNotModified to check whether the returned error was
42874// because http.StatusNotModified was returned.
42875func (c *RemarketingListSharesPatchCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
42876	gensupport.SetOptions(c.urlParams_, opts...)
42877	res, err := c.doRequest("json")
42878	if res != nil && res.StatusCode == http.StatusNotModified {
42879		if res.Body != nil {
42880			res.Body.Close()
42881		}
42882		return nil, &googleapi.Error{
42883			Code:   res.StatusCode,
42884			Header: res.Header,
42885		}
42886	}
42887	if err != nil {
42888		return nil, err
42889	}
42890	defer googleapi.CloseBody(res)
42891	if err := googleapi.CheckResponse(res); err != nil {
42892		return nil, err
42893	}
42894	ret := &RemarketingListShare{
42895		ServerResponse: googleapi.ServerResponse{
42896			Header:         res.Header,
42897			HTTPStatusCode: res.StatusCode,
42898		},
42899	}
42900	target := &ret
42901	if err := gensupport.DecodeResponse(target, res); err != nil {
42902		return nil, err
42903	}
42904	return ret, nil
42905	// {
42906	//   "description": "Updates an existing remarketing list share. This method supports patch semantics.",
42907	//   "httpMethod": "PATCH",
42908	//   "id": "dfareporting.remarketingListShares.patch",
42909	//   "parameterOrder": [
42910	//     "profileId",
42911	//     "remarketingListId"
42912	//   ],
42913	//   "parameters": {
42914	//     "profileId": {
42915	//       "description": "User profile ID associated with this request.",
42916	//       "format": "int64",
42917	//       "location": "path",
42918	//       "required": true,
42919	//       "type": "string"
42920	//     },
42921	//     "remarketingListId": {
42922	//       "description": "Remarketing list ID.",
42923	//       "format": "int64",
42924	//       "location": "query",
42925	//       "required": true,
42926	//       "type": "string"
42927	//     }
42928	//   },
42929	//   "path": "userprofiles/{profileId}/remarketingListShares",
42930	//   "request": {
42931	//     "$ref": "RemarketingListShare"
42932	//   },
42933	//   "response": {
42934	//     "$ref": "RemarketingListShare"
42935	//   },
42936	//   "scopes": [
42937	//     "https://www.googleapis.com/auth/dfatrafficking"
42938	//   ]
42939	// }
42940
42941}
42942
42943// method id "dfareporting.remarketingListShares.update":
42944
42945type RemarketingListSharesUpdateCall struct {
42946	s                    *Service
42947	profileId            int64
42948	remarketinglistshare *RemarketingListShare
42949	urlParams_           gensupport.URLParams
42950	ctx_                 context.Context
42951	header_              http.Header
42952}
42953
42954// Update: Updates an existing remarketing list share.
42955func (r *RemarketingListSharesService) Update(profileId int64, remarketinglistshare *RemarketingListShare) *RemarketingListSharesUpdateCall {
42956	c := &RemarketingListSharesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42957	c.profileId = profileId
42958	c.remarketinglistshare = remarketinglistshare
42959	return c
42960}
42961
42962// Fields allows partial responses to be retrieved. See
42963// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42964// for more information.
42965func (c *RemarketingListSharesUpdateCall) Fields(s ...googleapi.Field) *RemarketingListSharesUpdateCall {
42966	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42967	return c
42968}
42969
42970// Context sets the context to be used in this call's Do method. Any
42971// pending HTTP request will be aborted if the provided context is
42972// canceled.
42973func (c *RemarketingListSharesUpdateCall) Context(ctx context.Context) *RemarketingListSharesUpdateCall {
42974	c.ctx_ = ctx
42975	return c
42976}
42977
42978// Header returns an http.Header that can be modified by the caller to
42979// add HTTP headers to the request.
42980func (c *RemarketingListSharesUpdateCall) Header() http.Header {
42981	if c.header_ == nil {
42982		c.header_ = make(http.Header)
42983	}
42984	return c.header_
42985}
42986
42987func (c *RemarketingListSharesUpdateCall) doRequest(alt string) (*http.Response, error) {
42988	reqHeaders := make(http.Header)
42989	for k, v := range c.header_ {
42990		reqHeaders[k] = v
42991	}
42992	reqHeaders.Set("User-Agent", c.s.userAgent())
42993	var body io.Reader = nil
42994	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglistshare)
42995	if err != nil {
42996		return nil, err
42997	}
42998	reqHeaders.Set("Content-Type", "application/json")
42999	c.urlParams_.Set("alt", alt)
43000	c.urlParams_.Set("prettyPrint", "false")
43001	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares")
43002	urls += "?" + c.urlParams_.Encode()
43003	req, err := http.NewRequest("PUT", urls, body)
43004	if err != nil {
43005		return nil, err
43006	}
43007	req.Header = reqHeaders
43008	googleapi.Expand(req.URL, map[string]string{
43009		"profileId": strconv.FormatInt(c.profileId, 10),
43010	})
43011	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43012}
43013
43014// Do executes the "dfareporting.remarketingListShares.update" call.
43015// Exactly one of *RemarketingListShare or error will be non-nil. Any
43016// non-2xx status code is an error. Response headers are in either
43017// *RemarketingListShare.ServerResponse.Header or (if a response was
43018// returned at all) in error.(*googleapi.Error).Header. Use
43019// googleapi.IsNotModified to check whether the returned error was
43020// because http.StatusNotModified was returned.
43021func (c *RemarketingListSharesUpdateCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
43022	gensupport.SetOptions(c.urlParams_, opts...)
43023	res, err := c.doRequest("json")
43024	if res != nil && res.StatusCode == http.StatusNotModified {
43025		if res.Body != nil {
43026			res.Body.Close()
43027		}
43028		return nil, &googleapi.Error{
43029			Code:   res.StatusCode,
43030			Header: res.Header,
43031		}
43032	}
43033	if err != nil {
43034		return nil, err
43035	}
43036	defer googleapi.CloseBody(res)
43037	if err := googleapi.CheckResponse(res); err != nil {
43038		return nil, err
43039	}
43040	ret := &RemarketingListShare{
43041		ServerResponse: googleapi.ServerResponse{
43042			Header:         res.Header,
43043			HTTPStatusCode: res.StatusCode,
43044		},
43045	}
43046	target := &ret
43047	if err := gensupport.DecodeResponse(target, res); err != nil {
43048		return nil, err
43049	}
43050	return ret, nil
43051	// {
43052	//   "description": "Updates an existing remarketing list share.",
43053	//   "httpMethod": "PUT",
43054	//   "id": "dfareporting.remarketingListShares.update",
43055	//   "parameterOrder": [
43056	//     "profileId"
43057	//   ],
43058	//   "parameters": {
43059	//     "profileId": {
43060	//       "description": "User profile ID associated with this request.",
43061	//       "format": "int64",
43062	//       "location": "path",
43063	//       "required": true,
43064	//       "type": "string"
43065	//     }
43066	//   },
43067	//   "path": "userprofiles/{profileId}/remarketingListShares",
43068	//   "request": {
43069	//     "$ref": "RemarketingListShare"
43070	//   },
43071	//   "response": {
43072	//     "$ref": "RemarketingListShare"
43073	//   },
43074	//   "scopes": [
43075	//     "https://www.googleapis.com/auth/dfatrafficking"
43076	//   ]
43077	// }
43078
43079}
43080
43081// method id "dfareporting.remarketingLists.get":
43082
43083type RemarketingListsGetCall struct {
43084	s            *Service
43085	profileId    int64
43086	id           int64
43087	urlParams_   gensupport.URLParams
43088	ifNoneMatch_ string
43089	ctx_         context.Context
43090	header_      http.Header
43091}
43092
43093// Get: Gets one remarketing list by ID.
43094func (r *RemarketingListsService) Get(profileId int64, id int64) *RemarketingListsGetCall {
43095	c := &RemarketingListsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43096	c.profileId = profileId
43097	c.id = id
43098	return c
43099}
43100
43101// Fields allows partial responses to be retrieved. See
43102// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43103// for more information.
43104func (c *RemarketingListsGetCall) Fields(s ...googleapi.Field) *RemarketingListsGetCall {
43105	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43106	return c
43107}
43108
43109// IfNoneMatch sets the optional parameter which makes the operation
43110// fail if the object's ETag matches the given value. This is useful for
43111// getting updates only after the object has changed since the last
43112// request. Use googleapi.IsNotModified to check whether the response
43113// error from Do is the result of In-None-Match.
43114func (c *RemarketingListsGetCall) IfNoneMatch(entityTag string) *RemarketingListsGetCall {
43115	c.ifNoneMatch_ = entityTag
43116	return c
43117}
43118
43119// Context sets the context to be used in this call's Do method. Any
43120// pending HTTP request will be aborted if the provided context is
43121// canceled.
43122func (c *RemarketingListsGetCall) Context(ctx context.Context) *RemarketingListsGetCall {
43123	c.ctx_ = ctx
43124	return c
43125}
43126
43127// Header returns an http.Header that can be modified by the caller to
43128// add HTTP headers to the request.
43129func (c *RemarketingListsGetCall) Header() http.Header {
43130	if c.header_ == nil {
43131		c.header_ = make(http.Header)
43132	}
43133	return c.header_
43134}
43135
43136func (c *RemarketingListsGetCall) doRequest(alt string) (*http.Response, error) {
43137	reqHeaders := make(http.Header)
43138	for k, v := range c.header_ {
43139		reqHeaders[k] = v
43140	}
43141	reqHeaders.Set("User-Agent", c.s.userAgent())
43142	if c.ifNoneMatch_ != "" {
43143		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43144	}
43145	var body io.Reader = nil
43146	c.urlParams_.Set("alt", alt)
43147	c.urlParams_.Set("prettyPrint", "false")
43148	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists/{id}")
43149	urls += "?" + c.urlParams_.Encode()
43150	req, err := http.NewRequest("GET", urls, body)
43151	if err != nil {
43152		return nil, err
43153	}
43154	req.Header = reqHeaders
43155	googleapi.Expand(req.URL, map[string]string{
43156		"profileId": strconv.FormatInt(c.profileId, 10),
43157		"id":        strconv.FormatInt(c.id, 10),
43158	})
43159	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43160}
43161
43162// Do executes the "dfareporting.remarketingLists.get" call.
43163// Exactly one of *RemarketingList or error will be non-nil. Any non-2xx
43164// status code is an error. Response headers are in either
43165// *RemarketingList.ServerResponse.Header or (if a response was returned
43166// at all) in error.(*googleapi.Error).Header. Use
43167// googleapi.IsNotModified to check whether the returned error was
43168// because http.StatusNotModified was returned.
43169func (c *RemarketingListsGetCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
43170	gensupport.SetOptions(c.urlParams_, opts...)
43171	res, err := c.doRequest("json")
43172	if res != nil && res.StatusCode == http.StatusNotModified {
43173		if res.Body != nil {
43174			res.Body.Close()
43175		}
43176		return nil, &googleapi.Error{
43177			Code:   res.StatusCode,
43178			Header: res.Header,
43179		}
43180	}
43181	if err != nil {
43182		return nil, err
43183	}
43184	defer googleapi.CloseBody(res)
43185	if err := googleapi.CheckResponse(res); err != nil {
43186		return nil, err
43187	}
43188	ret := &RemarketingList{
43189		ServerResponse: googleapi.ServerResponse{
43190			Header:         res.Header,
43191			HTTPStatusCode: res.StatusCode,
43192		},
43193	}
43194	target := &ret
43195	if err := gensupport.DecodeResponse(target, res); err != nil {
43196		return nil, err
43197	}
43198	return ret, nil
43199	// {
43200	//   "description": "Gets one remarketing list by ID.",
43201	//   "httpMethod": "GET",
43202	//   "id": "dfareporting.remarketingLists.get",
43203	//   "parameterOrder": [
43204	//     "profileId",
43205	//     "id"
43206	//   ],
43207	//   "parameters": {
43208	//     "id": {
43209	//       "description": "Remarketing list ID.",
43210	//       "format": "int64",
43211	//       "location": "path",
43212	//       "required": true,
43213	//       "type": "string"
43214	//     },
43215	//     "profileId": {
43216	//       "description": "User profile ID associated with this request.",
43217	//       "format": "int64",
43218	//       "location": "path",
43219	//       "required": true,
43220	//       "type": "string"
43221	//     }
43222	//   },
43223	//   "path": "userprofiles/{profileId}/remarketingLists/{id}",
43224	//   "response": {
43225	//     "$ref": "RemarketingList"
43226	//   },
43227	//   "scopes": [
43228	//     "https://www.googleapis.com/auth/dfatrafficking"
43229	//   ]
43230	// }
43231
43232}
43233
43234// method id "dfareporting.remarketingLists.insert":
43235
43236type RemarketingListsInsertCall struct {
43237	s               *Service
43238	profileId       int64
43239	remarketinglist *RemarketingList
43240	urlParams_      gensupport.URLParams
43241	ctx_            context.Context
43242	header_         http.Header
43243}
43244
43245// Insert: Inserts a new remarketing list.
43246func (r *RemarketingListsService) Insert(profileId int64, remarketinglist *RemarketingList) *RemarketingListsInsertCall {
43247	c := &RemarketingListsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43248	c.profileId = profileId
43249	c.remarketinglist = remarketinglist
43250	return c
43251}
43252
43253// Fields allows partial responses to be retrieved. See
43254// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43255// for more information.
43256func (c *RemarketingListsInsertCall) Fields(s ...googleapi.Field) *RemarketingListsInsertCall {
43257	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43258	return c
43259}
43260
43261// Context sets the context to be used in this call's Do method. Any
43262// pending HTTP request will be aborted if the provided context is
43263// canceled.
43264func (c *RemarketingListsInsertCall) Context(ctx context.Context) *RemarketingListsInsertCall {
43265	c.ctx_ = ctx
43266	return c
43267}
43268
43269// Header returns an http.Header that can be modified by the caller to
43270// add HTTP headers to the request.
43271func (c *RemarketingListsInsertCall) Header() http.Header {
43272	if c.header_ == nil {
43273		c.header_ = make(http.Header)
43274	}
43275	return c.header_
43276}
43277
43278func (c *RemarketingListsInsertCall) doRequest(alt string) (*http.Response, error) {
43279	reqHeaders := make(http.Header)
43280	for k, v := range c.header_ {
43281		reqHeaders[k] = v
43282	}
43283	reqHeaders.Set("User-Agent", c.s.userAgent())
43284	var body io.Reader = nil
43285	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
43286	if err != nil {
43287		return nil, err
43288	}
43289	reqHeaders.Set("Content-Type", "application/json")
43290	c.urlParams_.Set("alt", alt)
43291	c.urlParams_.Set("prettyPrint", "false")
43292	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43293	urls += "?" + c.urlParams_.Encode()
43294	req, err := http.NewRequest("POST", urls, body)
43295	if err != nil {
43296		return nil, err
43297	}
43298	req.Header = reqHeaders
43299	googleapi.Expand(req.URL, map[string]string{
43300		"profileId": strconv.FormatInt(c.profileId, 10),
43301	})
43302	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43303}
43304
43305// Do executes the "dfareporting.remarketingLists.insert" call.
43306// Exactly one of *RemarketingList or error will be non-nil. Any non-2xx
43307// status code is an error. Response headers are in either
43308// *RemarketingList.ServerResponse.Header or (if a response was returned
43309// at all) in error.(*googleapi.Error).Header. Use
43310// googleapi.IsNotModified to check whether the returned error was
43311// because http.StatusNotModified was returned.
43312func (c *RemarketingListsInsertCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
43313	gensupport.SetOptions(c.urlParams_, opts...)
43314	res, err := c.doRequest("json")
43315	if res != nil && res.StatusCode == http.StatusNotModified {
43316		if res.Body != nil {
43317			res.Body.Close()
43318		}
43319		return nil, &googleapi.Error{
43320			Code:   res.StatusCode,
43321			Header: res.Header,
43322		}
43323	}
43324	if err != nil {
43325		return nil, err
43326	}
43327	defer googleapi.CloseBody(res)
43328	if err := googleapi.CheckResponse(res); err != nil {
43329		return nil, err
43330	}
43331	ret := &RemarketingList{
43332		ServerResponse: googleapi.ServerResponse{
43333			Header:         res.Header,
43334			HTTPStatusCode: res.StatusCode,
43335		},
43336	}
43337	target := &ret
43338	if err := gensupport.DecodeResponse(target, res); err != nil {
43339		return nil, err
43340	}
43341	return ret, nil
43342	// {
43343	//   "description": "Inserts a new remarketing list.",
43344	//   "httpMethod": "POST",
43345	//   "id": "dfareporting.remarketingLists.insert",
43346	//   "parameterOrder": [
43347	//     "profileId"
43348	//   ],
43349	//   "parameters": {
43350	//     "profileId": {
43351	//       "description": "User profile ID associated with this request.",
43352	//       "format": "int64",
43353	//       "location": "path",
43354	//       "required": true,
43355	//       "type": "string"
43356	//     }
43357	//   },
43358	//   "path": "userprofiles/{profileId}/remarketingLists",
43359	//   "request": {
43360	//     "$ref": "RemarketingList"
43361	//   },
43362	//   "response": {
43363	//     "$ref": "RemarketingList"
43364	//   },
43365	//   "scopes": [
43366	//     "https://www.googleapis.com/auth/dfatrafficking"
43367	//   ]
43368	// }
43369
43370}
43371
43372// method id "dfareporting.remarketingLists.list":
43373
43374type RemarketingListsListCall struct {
43375	s            *Service
43376	profileId    int64
43377	urlParams_   gensupport.URLParams
43378	ifNoneMatch_ string
43379	ctx_         context.Context
43380	header_      http.Header
43381}
43382
43383// List: Retrieves a list of remarketing lists, possibly filtered. This
43384// method supports paging.
43385func (r *RemarketingListsService) List(profileId int64, advertiserId int64) *RemarketingListsListCall {
43386	c := &RemarketingListsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43387	c.profileId = profileId
43388	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
43389	return c
43390}
43391
43392// Active sets the optional parameter "active": Select only active or
43393// only inactive remarketing lists.
43394func (c *RemarketingListsListCall) Active(active bool) *RemarketingListsListCall {
43395	c.urlParams_.Set("active", fmt.Sprint(active))
43396	return c
43397}
43398
43399// FloodlightActivityId sets the optional parameter
43400// "floodlightActivityId": Select only remarketing lists that have this
43401// floodlight activity ID.
43402func (c *RemarketingListsListCall) FloodlightActivityId(floodlightActivityId int64) *RemarketingListsListCall {
43403	c.urlParams_.Set("floodlightActivityId", fmt.Sprint(floodlightActivityId))
43404	return c
43405}
43406
43407// MaxResults sets the optional parameter "maxResults": Maximum number
43408// of results to return.
43409func (c *RemarketingListsListCall) MaxResults(maxResults int64) *RemarketingListsListCall {
43410	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
43411	return c
43412}
43413
43414// Name sets the optional parameter "name": Allows searching for objects
43415// by name or ID. Wildcards (*) are allowed. For example, "remarketing
43416// list*2015" will return objects with names like "remarketing list June
43417// 2015", "remarketing list April 2015", or simply "remarketing list
43418// 2015". Most of the searches also add wildcards implicitly at the
43419// start and the end of the search string. For example, a search string
43420// of "remarketing list" will match objects with name "my remarketing
43421// list", "remarketing list 2015", or simply "remarketing list".
43422func (c *RemarketingListsListCall) Name(name string) *RemarketingListsListCall {
43423	c.urlParams_.Set("name", name)
43424	return c
43425}
43426
43427// PageToken sets the optional parameter "pageToken": Value of the
43428// nextPageToken from the previous result page.
43429func (c *RemarketingListsListCall) PageToken(pageToken string) *RemarketingListsListCall {
43430	c.urlParams_.Set("pageToken", pageToken)
43431	return c
43432}
43433
43434// SortField sets the optional parameter "sortField": Field by which to
43435// sort the list.
43436//
43437// Possible values:
43438//   "ID" (default)
43439//   "NAME"
43440func (c *RemarketingListsListCall) SortField(sortField string) *RemarketingListsListCall {
43441	c.urlParams_.Set("sortField", sortField)
43442	return c
43443}
43444
43445// SortOrder sets the optional parameter "sortOrder": Order of sorted
43446// results.
43447//
43448// Possible values:
43449//   "ASCENDING" (default)
43450//   "DESCENDING"
43451func (c *RemarketingListsListCall) SortOrder(sortOrder string) *RemarketingListsListCall {
43452	c.urlParams_.Set("sortOrder", sortOrder)
43453	return c
43454}
43455
43456// Fields allows partial responses to be retrieved. See
43457// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43458// for more information.
43459func (c *RemarketingListsListCall) Fields(s ...googleapi.Field) *RemarketingListsListCall {
43460	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43461	return c
43462}
43463
43464// IfNoneMatch sets the optional parameter which makes the operation
43465// fail if the object's ETag matches the given value. This is useful for
43466// getting updates only after the object has changed since the last
43467// request. Use googleapi.IsNotModified to check whether the response
43468// error from Do is the result of In-None-Match.
43469func (c *RemarketingListsListCall) IfNoneMatch(entityTag string) *RemarketingListsListCall {
43470	c.ifNoneMatch_ = entityTag
43471	return c
43472}
43473
43474// Context sets the context to be used in this call's Do method. Any
43475// pending HTTP request will be aborted if the provided context is
43476// canceled.
43477func (c *RemarketingListsListCall) Context(ctx context.Context) *RemarketingListsListCall {
43478	c.ctx_ = ctx
43479	return c
43480}
43481
43482// Header returns an http.Header that can be modified by the caller to
43483// add HTTP headers to the request.
43484func (c *RemarketingListsListCall) Header() http.Header {
43485	if c.header_ == nil {
43486		c.header_ = make(http.Header)
43487	}
43488	return c.header_
43489}
43490
43491func (c *RemarketingListsListCall) doRequest(alt string) (*http.Response, error) {
43492	reqHeaders := make(http.Header)
43493	for k, v := range c.header_ {
43494		reqHeaders[k] = v
43495	}
43496	reqHeaders.Set("User-Agent", c.s.userAgent())
43497	if c.ifNoneMatch_ != "" {
43498		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43499	}
43500	var body io.Reader = nil
43501	c.urlParams_.Set("alt", alt)
43502	c.urlParams_.Set("prettyPrint", "false")
43503	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43504	urls += "?" + c.urlParams_.Encode()
43505	req, err := http.NewRequest("GET", urls, body)
43506	if err != nil {
43507		return nil, err
43508	}
43509	req.Header = reqHeaders
43510	googleapi.Expand(req.URL, map[string]string{
43511		"profileId": strconv.FormatInt(c.profileId, 10),
43512	})
43513	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43514}
43515
43516// Do executes the "dfareporting.remarketingLists.list" call.
43517// Exactly one of *RemarketingListsListResponse or error will be
43518// non-nil. Any non-2xx status code is an error. Response headers are in
43519// either *RemarketingListsListResponse.ServerResponse.Header or (if a
43520// response was returned at all) in error.(*googleapi.Error).Header. Use
43521// googleapi.IsNotModified to check whether the returned error was
43522// because http.StatusNotModified was returned.
43523func (c *RemarketingListsListCall) Do(opts ...googleapi.CallOption) (*RemarketingListsListResponse, error) {
43524	gensupport.SetOptions(c.urlParams_, opts...)
43525	res, err := c.doRequest("json")
43526	if res != nil && res.StatusCode == http.StatusNotModified {
43527		if res.Body != nil {
43528			res.Body.Close()
43529		}
43530		return nil, &googleapi.Error{
43531			Code:   res.StatusCode,
43532			Header: res.Header,
43533		}
43534	}
43535	if err != nil {
43536		return nil, err
43537	}
43538	defer googleapi.CloseBody(res)
43539	if err := googleapi.CheckResponse(res); err != nil {
43540		return nil, err
43541	}
43542	ret := &RemarketingListsListResponse{
43543		ServerResponse: googleapi.ServerResponse{
43544			Header:         res.Header,
43545			HTTPStatusCode: res.StatusCode,
43546		},
43547	}
43548	target := &ret
43549	if err := gensupport.DecodeResponse(target, res); err != nil {
43550		return nil, err
43551	}
43552	return ret, nil
43553	// {
43554	//   "description": "Retrieves a list of remarketing lists, possibly filtered. This method supports paging.",
43555	//   "httpMethod": "GET",
43556	//   "id": "dfareporting.remarketingLists.list",
43557	//   "parameterOrder": [
43558	//     "profileId",
43559	//     "advertiserId"
43560	//   ],
43561	//   "parameters": {
43562	//     "active": {
43563	//       "description": "Select only active or only inactive remarketing lists.",
43564	//       "location": "query",
43565	//       "type": "boolean"
43566	//     },
43567	//     "advertiserId": {
43568	//       "description": "Select only remarketing lists owned by this advertiser.",
43569	//       "format": "int64",
43570	//       "location": "query",
43571	//       "required": true,
43572	//       "type": "string"
43573	//     },
43574	//     "floodlightActivityId": {
43575	//       "description": "Select only remarketing lists that have this floodlight activity ID.",
43576	//       "format": "int64",
43577	//       "location": "query",
43578	//       "type": "string"
43579	//     },
43580	//     "maxResults": {
43581	//       "default": "1000",
43582	//       "description": "Maximum number of results to return.",
43583	//       "format": "int32",
43584	//       "location": "query",
43585	//       "maximum": "1000",
43586	//       "minimum": "0",
43587	//       "type": "integer"
43588	//     },
43589	//     "name": {
43590	//       "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\".",
43591	//       "location": "query",
43592	//       "type": "string"
43593	//     },
43594	//     "pageToken": {
43595	//       "description": "Value of the nextPageToken from the previous result page.",
43596	//       "location": "query",
43597	//       "type": "string"
43598	//     },
43599	//     "profileId": {
43600	//       "description": "User profile ID associated with this request.",
43601	//       "format": "int64",
43602	//       "location": "path",
43603	//       "required": true,
43604	//       "type": "string"
43605	//     },
43606	//     "sortField": {
43607	//       "default": "ID",
43608	//       "description": "Field by which to sort the list.",
43609	//       "enum": [
43610	//         "ID",
43611	//         "NAME"
43612	//       ],
43613	//       "enumDescriptions": [
43614	//         "",
43615	//         ""
43616	//       ],
43617	//       "location": "query",
43618	//       "type": "string"
43619	//     },
43620	//     "sortOrder": {
43621	//       "default": "ASCENDING",
43622	//       "description": "Order of sorted results.",
43623	//       "enum": [
43624	//         "ASCENDING",
43625	//         "DESCENDING"
43626	//       ],
43627	//       "enumDescriptions": [
43628	//         "",
43629	//         ""
43630	//       ],
43631	//       "location": "query",
43632	//       "type": "string"
43633	//     }
43634	//   },
43635	//   "path": "userprofiles/{profileId}/remarketingLists",
43636	//   "response": {
43637	//     "$ref": "RemarketingListsListResponse"
43638	//   },
43639	//   "scopes": [
43640	//     "https://www.googleapis.com/auth/dfatrafficking"
43641	//   ]
43642	// }
43643
43644}
43645
43646// Pages invokes f for each page of results.
43647// A non-nil error returned from f will halt the iteration.
43648// The provided context supersedes any context provided to the Context method.
43649func (c *RemarketingListsListCall) Pages(ctx context.Context, f func(*RemarketingListsListResponse) error) error {
43650	c.ctx_ = ctx
43651	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
43652	for {
43653		x, err := c.Do()
43654		if err != nil {
43655			return err
43656		}
43657		if err := f(x); err != nil {
43658			return err
43659		}
43660		if x.NextPageToken == "" {
43661			return nil
43662		}
43663		c.PageToken(x.NextPageToken)
43664	}
43665}
43666
43667// method id "dfareporting.remarketingLists.patch":
43668
43669type RemarketingListsPatchCall struct {
43670	s               *Service
43671	profileId       int64
43672	remarketinglist *RemarketingList
43673	urlParams_      gensupport.URLParams
43674	ctx_            context.Context
43675	header_         http.Header
43676}
43677
43678// Patch: Updates an existing remarketing list. This method supports
43679// patch semantics.
43680func (r *RemarketingListsService) Patch(profileId int64, id int64, remarketinglist *RemarketingList) *RemarketingListsPatchCall {
43681	c := &RemarketingListsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43682	c.profileId = profileId
43683	c.urlParams_.Set("id", fmt.Sprint(id))
43684	c.remarketinglist = remarketinglist
43685	return c
43686}
43687
43688// Fields allows partial responses to be retrieved. See
43689// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43690// for more information.
43691func (c *RemarketingListsPatchCall) Fields(s ...googleapi.Field) *RemarketingListsPatchCall {
43692	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43693	return c
43694}
43695
43696// Context sets the context to be used in this call's Do method. Any
43697// pending HTTP request will be aborted if the provided context is
43698// canceled.
43699func (c *RemarketingListsPatchCall) Context(ctx context.Context) *RemarketingListsPatchCall {
43700	c.ctx_ = ctx
43701	return c
43702}
43703
43704// Header returns an http.Header that can be modified by the caller to
43705// add HTTP headers to the request.
43706func (c *RemarketingListsPatchCall) Header() http.Header {
43707	if c.header_ == nil {
43708		c.header_ = make(http.Header)
43709	}
43710	return c.header_
43711}
43712
43713func (c *RemarketingListsPatchCall) doRequest(alt string) (*http.Response, error) {
43714	reqHeaders := make(http.Header)
43715	for k, v := range c.header_ {
43716		reqHeaders[k] = v
43717	}
43718	reqHeaders.Set("User-Agent", c.s.userAgent())
43719	var body io.Reader = nil
43720	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
43721	if err != nil {
43722		return nil, err
43723	}
43724	reqHeaders.Set("Content-Type", "application/json")
43725	c.urlParams_.Set("alt", alt)
43726	c.urlParams_.Set("prettyPrint", "false")
43727	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43728	urls += "?" + c.urlParams_.Encode()
43729	req, err := http.NewRequest("PATCH", urls, body)
43730	if err != nil {
43731		return nil, err
43732	}
43733	req.Header = reqHeaders
43734	googleapi.Expand(req.URL, map[string]string{
43735		"profileId": strconv.FormatInt(c.profileId, 10),
43736	})
43737	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43738}
43739
43740// Do executes the "dfareporting.remarketingLists.patch" call.
43741// Exactly one of *RemarketingList or error will be non-nil. Any non-2xx
43742// status code is an error. Response headers are in either
43743// *RemarketingList.ServerResponse.Header or (if a response was returned
43744// at all) in error.(*googleapi.Error).Header. Use
43745// googleapi.IsNotModified to check whether the returned error was
43746// because http.StatusNotModified was returned.
43747func (c *RemarketingListsPatchCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
43748	gensupport.SetOptions(c.urlParams_, opts...)
43749	res, err := c.doRequest("json")
43750	if res != nil && res.StatusCode == http.StatusNotModified {
43751		if res.Body != nil {
43752			res.Body.Close()
43753		}
43754		return nil, &googleapi.Error{
43755			Code:   res.StatusCode,
43756			Header: res.Header,
43757		}
43758	}
43759	if err != nil {
43760		return nil, err
43761	}
43762	defer googleapi.CloseBody(res)
43763	if err := googleapi.CheckResponse(res); err != nil {
43764		return nil, err
43765	}
43766	ret := &RemarketingList{
43767		ServerResponse: googleapi.ServerResponse{
43768			Header:         res.Header,
43769			HTTPStatusCode: res.StatusCode,
43770		},
43771	}
43772	target := &ret
43773	if err := gensupport.DecodeResponse(target, res); err != nil {
43774		return nil, err
43775	}
43776	return ret, nil
43777	// {
43778	//   "description": "Updates an existing remarketing list. This method supports patch semantics.",
43779	//   "httpMethod": "PATCH",
43780	//   "id": "dfareporting.remarketingLists.patch",
43781	//   "parameterOrder": [
43782	//     "profileId",
43783	//     "id"
43784	//   ],
43785	//   "parameters": {
43786	//     "id": {
43787	//       "description": "Remarketing list ID.",
43788	//       "format": "int64",
43789	//       "location": "query",
43790	//       "required": true,
43791	//       "type": "string"
43792	//     },
43793	//     "profileId": {
43794	//       "description": "User profile ID associated with this request.",
43795	//       "format": "int64",
43796	//       "location": "path",
43797	//       "required": true,
43798	//       "type": "string"
43799	//     }
43800	//   },
43801	//   "path": "userprofiles/{profileId}/remarketingLists",
43802	//   "request": {
43803	//     "$ref": "RemarketingList"
43804	//   },
43805	//   "response": {
43806	//     "$ref": "RemarketingList"
43807	//   },
43808	//   "scopes": [
43809	//     "https://www.googleapis.com/auth/dfatrafficking"
43810	//   ]
43811	// }
43812
43813}
43814
43815// method id "dfareporting.remarketingLists.update":
43816
43817type RemarketingListsUpdateCall struct {
43818	s               *Service
43819	profileId       int64
43820	remarketinglist *RemarketingList
43821	urlParams_      gensupport.URLParams
43822	ctx_            context.Context
43823	header_         http.Header
43824}
43825
43826// Update: Updates an existing remarketing list.
43827func (r *RemarketingListsService) Update(profileId int64, remarketinglist *RemarketingList) *RemarketingListsUpdateCall {
43828	c := &RemarketingListsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43829	c.profileId = profileId
43830	c.remarketinglist = remarketinglist
43831	return c
43832}
43833
43834// Fields allows partial responses to be retrieved. See
43835// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43836// for more information.
43837func (c *RemarketingListsUpdateCall) Fields(s ...googleapi.Field) *RemarketingListsUpdateCall {
43838	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43839	return c
43840}
43841
43842// Context sets the context to be used in this call's Do method. Any
43843// pending HTTP request will be aborted if the provided context is
43844// canceled.
43845func (c *RemarketingListsUpdateCall) Context(ctx context.Context) *RemarketingListsUpdateCall {
43846	c.ctx_ = ctx
43847	return c
43848}
43849
43850// Header returns an http.Header that can be modified by the caller to
43851// add HTTP headers to the request.
43852func (c *RemarketingListsUpdateCall) Header() http.Header {
43853	if c.header_ == nil {
43854		c.header_ = make(http.Header)
43855	}
43856	return c.header_
43857}
43858
43859func (c *RemarketingListsUpdateCall) doRequest(alt string) (*http.Response, error) {
43860	reqHeaders := make(http.Header)
43861	for k, v := range c.header_ {
43862		reqHeaders[k] = v
43863	}
43864	reqHeaders.Set("User-Agent", c.s.userAgent())
43865	var body io.Reader = nil
43866	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
43867	if err != nil {
43868		return nil, err
43869	}
43870	reqHeaders.Set("Content-Type", "application/json")
43871	c.urlParams_.Set("alt", alt)
43872	c.urlParams_.Set("prettyPrint", "false")
43873	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43874	urls += "?" + c.urlParams_.Encode()
43875	req, err := http.NewRequest("PUT", urls, body)
43876	if err != nil {
43877		return nil, err
43878	}
43879	req.Header = reqHeaders
43880	googleapi.Expand(req.URL, map[string]string{
43881		"profileId": strconv.FormatInt(c.profileId, 10),
43882	})
43883	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43884}
43885
43886// Do executes the "dfareporting.remarketingLists.update" call.
43887// Exactly one of *RemarketingList or error will be non-nil. Any non-2xx
43888// status code is an error. Response headers are in either
43889// *RemarketingList.ServerResponse.Header or (if a response was returned
43890// at all) in error.(*googleapi.Error).Header. Use
43891// googleapi.IsNotModified to check whether the returned error was
43892// because http.StatusNotModified was returned.
43893func (c *RemarketingListsUpdateCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
43894	gensupport.SetOptions(c.urlParams_, opts...)
43895	res, err := c.doRequest("json")
43896	if res != nil && res.StatusCode == http.StatusNotModified {
43897		if res.Body != nil {
43898			res.Body.Close()
43899		}
43900		return nil, &googleapi.Error{
43901			Code:   res.StatusCode,
43902			Header: res.Header,
43903		}
43904	}
43905	if err != nil {
43906		return nil, err
43907	}
43908	defer googleapi.CloseBody(res)
43909	if err := googleapi.CheckResponse(res); err != nil {
43910		return nil, err
43911	}
43912	ret := &RemarketingList{
43913		ServerResponse: googleapi.ServerResponse{
43914			Header:         res.Header,
43915			HTTPStatusCode: res.StatusCode,
43916		},
43917	}
43918	target := &ret
43919	if err := gensupport.DecodeResponse(target, res); err != nil {
43920		return nil, err
43921	}
43922	return ret, nil
43923	// {
43924	//   "description": "Updates an existing remarketing list.",
43925	//   "httpMethod": "PUT",
43926	//   "id": "dfareporting.remarketingLists.update",
43927	//   "parameterOrder": [
43928	//     "profileId"
43929	//   ],
43930	//   "parameters": {
43931	//     "profileId": {
43932	//       "description": "User profile ID associated with this request.",
43933	//       "format": "int64",
43934	//       "location": "path",
43935	//       "required": true,
43936	//       "type": "string"
43937	//     }
43938	//   },
43939	//   "path": "userprofiles/{profileId}/remarketingLists",
43940	//   "request": {
43941	//     "$ref": "RemarketingList"
43942	//   },
43943	//   "response": {
43944	//     "$ref": "RemarketingList"
43945	//   },
43946	//   "scopes": [
43947	//     "https://www.googleapis.com/auth/dfatrafficking"
43948	//   ]
43949	// }
43950
43951}
43952
43953// method id "dfareporting.reports.delete":
43954
43955type ReportsDeleteCall struct {
43956	s          *Service
43957	profileId  int64
43958	reportId   int64
43959	urlParams_ gensupport.URLParams
43960	ctx_       context.Context
43961	header_    http.Header
43962}
43963
43964// Delete: Deletes a report by its ID.
43965func (r *ReportsService) Delete(profileId int64, reportId int64) *ReportsDeleteCall {
43966	c := &ReportsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43967	c.profileId = profileId
43968	c.reportId = reportId
43969	return c
43970}
43971
43972// Fields allows partial responses to be retrieved. See
43973// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43974// for more information.
43975func (c *ReportsDeleteCall) Fields(s ...googleapi.Field) *ReportsDeleteCall {
43976	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43977	return c
43978}
43979
43980// Context sets the context to be used in this call's Do method. Any
43981// pending HTTP request will be aborted if the provided context is
43982// canceled.
43983func (c *ReportsDeleteCall) Context(ctx context.Context) *ReportsDeleteCall {
43984	c.ctx_ = ctx
43985	return c
43986}
43987
43988// Header returns an http.Header that can be modified by the caller to
43989// add HTTP headers to the request.
43990func (c *ReportsDeleteCall) Header() http.Header {
43991	if c.header_ == nil {
43992		c.header_ = make(http.Header)
43993	}
43994	return c.header_
43995}
43996
43997func (c *ReportsDeleteCall) doRequest(alt string) (*http.Response, error) {
43998	reqHeaders := make(http.Header)
43999	for k, v := range c.header_ {
44000		reqHeaders[k] = v
44001	}
44002	reqHeaders.Set("User-Agent", c.s.userAgent())
44003	var body io.Reader = nil
44004	c.urlParams_.Set("alt", alt)
44005	c.urlParams_.Set("prettyPrint", "false")
44006	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44007	urls += "?" + c.urlParams_.Encode()
44008	req, err := http.NewRequest("DELETE", urls, body)
44009	if err != nil {
44010		return nil, err
44011	}
44012	req.Header = reqHeaders
44013	googleapi.Expand(req.URL, map[string]string{
44014		"profileId": strconv.FormatInt(c.profileId, 10),
44015		"reportId":  strconv.FormatInt(c.reportId, 10),
44016	})
44017	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44018}
44019
44020// Do executes the "dfareporting.reports.delete" call.
44021func (c *ReportsDeleteCall) Do(opts ...googleapi.CallOption) error {
44022	gensupport.SetOptions(c.urlParams_, opts...)
44023	res, err := c.doRequest("json")
44024	if err != nil {
44025		return err
44026	}
44027	defer googleapi.CloseBody(res)
44028	if err := googleapi.CheckResponse(res); err != nil {
44029		return err
44030	}
44031	return nil
44032	// {
44033	//   "description": "Deletes a report by its ID.",
44034	//   "httpMethod": "DELETE",
44035	//   "id": "dfareporting.reports.delete",
44036	//   "parameterOrder": [
44037	//     "profileId",
44038	//     "reportId"
44039	//   ],
44040	//   "parameters": {
44041	//     "profileId": {
44042	//       "description": "The DFA user profile ID.",
44043	//       "format": "int64",
44044	//       "location": "path",
44045	//       "required": true,
44046	//       "type": "string"
44047	//     },
44048	//     "reportId": {
44049	//       "description": "The ID of the report.",
44050	//       "format": "int64",
44051	//       "location": "path",
44052	//       "required": true,
44053	//       "type": "string"
44054	//     }
44055	//   },
44056	//   "path": "userprofiles/{profileId}/reports/{reportId}",
44057	//   "scopes": [
44058	//     "https://www.googleapis.com/auth/dfareporting"
44059	//   ]
44060	// }
44061
44062}
44063
44064// method id "dfareporting.reports.get":
44065
44066type ReportsGetCall struct {
44067	s            *Service
44068	profileId    int64
44069	reportId     int64
44070	urlParams_   gensupport.URLParams
44071	ifNoneMatch_ string
44072	ctx_         context.Context
44073	header_      http.Header
44074}
44075
44076// Get: Retrieves a report by its ID.
44077func (r *ReportsService) Get(profileId int64, reportId int64) *ReportsGetCall {
44078	c := &ReportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44079	c.profileId = profileId
44080	c.reportId = reportId
44081	return c
44082}
44083
44084// Fields allows partial responses to be retrieved. See
44085// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44086// for more information.
44087func (c *ReportsGetCall) Fields(s ...googleapi.Field) *ReportsGetCall {
44088	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44089	return c
44090}
44091
44092// IfNoneMatch sets the optional parameter which makes the operation
44093// fail if the object's ETag matches the given value. This is useful for
44094// getting updates only after the object has changed since the last
44095// request. Use googleapi.IsNotModified to check whether the response
44096// error from Do is the result of In-None-Match.
44097func (c *ReportsGetCall) IfNoneMatch(entityTag string) *ReportsGetCall {
44098	c.ifNoneMatch_ = entityTag
44099	return c
44100}
44101
44102// Context sets the context to be used in this call's Do method. Any
44103// pending HTTP request will be aborted if the provided context is
44104// canceled.
44105func (c *ReportsGetCall) Context(ctx context.Context) *ReportsGetCall {
44106	c.ctx_ = ctx
44107	return c
44108}
44109
44110// Header returns an http.Header that can be modified by the caller to
44111// add HTTP headers to the request.
44112func (c *ReportsGetCall) Header() http.Header {
44113	if c.header_ == nil {
44114		c.header_ = make(http.Header)
44115	}
44116	return c.header_
44117}
44118
44119func (c *ReportsGetCall) doRequest(alt string) (*http.Response, error) {
44120	reqHeaders := make(http.Header)
44121	for k, v := range c.header_ {
44122		reqHeaders[k] = v
44123	}
44124	reqHeaders.Set("User-Agent", c.s.userAgent())
44125	if c.ifNoneMatch_ != "" {
44126		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44127	}
44128	var body io.Reader = nil
44129	c.urlParams_.Set("alt", alt)
44130	c.urlParams_.Set("prettyPrint", "false")
44131	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44132	urls += "?" + c.urlParams_.Encode()
44133	req, err := http.NewRequest("GET", urls, body)
44134	if err != nil {
44135		return nil, err
44136	}
44137	req.Header = reqHeaders
44138	googleapi.Expand(req.URL, map[string]string{
44139		"profileId": strconv.FormatInt(c.profileId, 10),
44140		"reportId":  strconv.FormatInt(c.reportId, 10),
44141	})
44142	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44143}
44144
44145// Do executes the "dfareporting.reports.get" call.
44146// Exactly one of *Report or error will be non-nil. Any non-2xx status
44147// code is an error. Response headers are in either
44148// *Report.ServerResponse.Header or (if a response was returned at all)
44149// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
44150// check whether the returned error was because http.StatusNotModified
44151// was returned.
44152func (c *ReportsGetCall) Do(opts ...googleapi.CallOption) (*Report, error) {
44153	gensupport.SetOptions(c.urlParams_, opts...)
44154	res, err := c.doRequest("json")
44155	if res != nil && res.StatusCode == http.StatusNotModified {
44156		if res.Body != nil {
44157			res.Body.Close()
44158		}
44159		return nil, &googleapi.Error{
44160			Code:   res.StatusCode,
44161			Header: res.Header,
44162		}
44163	}
44164	if err != nil {
44165		return nil, err
44166	}
44167	defer googleapi.CloseBody(res)
44168	if err := googleapi.CheckResponse(res); err != nil {
44169		return nil, err
44170	}
44171	ret := &Report{
44172		ServerResponse: googleapi.ServerResponse{
44173			Header:         res.Header,
44174			HTTPStatusCode: res.StatusCode,
44175		},
44176	}
44177	target := &ret
44178	if err := gensupport.DecodeResponse(target, res); err != nil {
44179		return nil, err
44180	}
44181	return ret, nil
44182	// {
44183	//   "description": "Retrieves a report by its ID.",
44184	//   "httpMethod": "GET",
44185	//   "id": "dfareporting.reports.get",
44186	//   "parameterOrder": [
44187	//     "profileId",
44188	//     "reportId"
44189	//   ],
44190	//   "parameters": {
44191	//     "profileId": {
44192	//       "description": "The DFA user profile ID.",
44193	//       "format": "int64",
44194	//       "location": "path",
44195	//       "required": true,
44196	//       "type": "string"
44197	//     },
44198	//     "reportId": {
44199	//       "description": "The ID of the report.",
44200	//       "format": "int64",
44201	//       "location": "path",
44202	//       "required": true,
44203	//       "type": "string"
44204	//     }
44205	//   },
44206	//   "path": "userprofiles/{profileId}/reports/{reportId}",
44207	//   "response": {
44208	//     "$ref": "Report"
44209	//   },
44210	//   "scopes": [
44211	//     "https://www.googleapis.com/auth/dfareporting"
44212	//   ]
44213	// }
44214
44215}
44216
44217// method id "dfareporting.reports.insert":
44218
44219type ReportsInsertCall struct {
44220	s          *Service
44221	profileId  int64
44222	report     *Report
44223	urlParams_ gensupport.URLParams
44224	ctx_       context.Context
44225	header_    http.Header
44226}
44227
44228// Insert: Creates a report.
44229func (r *ReportsService) Insert(profileId int64, report *Report) *ReportsInsertCall {
44230	c := &ReportsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44231	c.profileId = profileId
44232	c.report = report
44233	return c
44234}
44235
44236// Fields allows partial responses to be retrieved. See
44237// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44238// for more information.
44239func (c *ReportsInsertCall) Fields(s ...googleapi.Field) *ReportsInsertCall {
44240	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44241	return c
44242}
44243
44244// Context sets the context to be used in this call's Do method. Any
44245// pending HTTP request will be aborted if the provided context is
44246// canceled.
44247func (c *ReportsInsertCall) Context(ctx context.Context) *ReportsInsertCall {
44248	c.ctx_ = ctx
44249	return c
44250}
44251
44252// Header returns an http.Header that can be modified by the caller to
44253// add HTTP headers to the request.
44254func (c *ReportsInsertCall) Header() http.Header {
44255	if c.header_ == nil {
44256		c.header_ = make(http.Header)
44257	}
44258	return c.header_
44259}
44260
44261func (c *ReportsInsertCall) doRequest(alt string) (*http.Response, error) {
44262	reqHeaders := make(http.Header)
44263	for k, v := range c.header_ {
44264		reqHeaders[k] = v
44265	}
44266	reqHeaders.Set("User-Agent", c.s.userAgent())
44267	var body io.Reader = nil
44268	body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
44269	if err != nil {
44270		return nil, err
44271	}
44272	reqHeaders.Set("Content-Type", "application/json")
44273	c.urlParams_.Set("alt", alt)
44274	c.urlParams_.Set("prettyPrint", "false")
44275	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports")
44276	urls += "?" + c.urlParams_.Encode()
44277	req, err := http.NewRequest("POST", urls, body)
44278	if err != nil {
44279		return nil, err
44280	}
44281	req.Header = reqHeaders
44282	googleapi.Expand(req.URL, map[string]string{
44283		"profileId": strconv.FormatInt(c.profileId, 10),
44284	})
44285	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44286}
44287
44288// Do executes the "dfareporting.reports.insert" call.
44289// Exactly one of *Report or error will be non-nil. Any non-2xx status
44290// code is an error. Response headers are in either
44291// *Report.ServerResponse.Header or (if a response was returned at all)
44292// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
44293// check whether the returned error was because http.StatusNotModified
44294// was returned.
44295func (c *ReportsInsertCall) Do(opts ...googleapi.CallOption) (*Report, error) {
44296	gensupport.SetOptions(c.urlParams_, opts...)
44297	res, err := c.doRequest("json")
44298	if res != nil && res.StatusCode == http.StatusNotModified {
44299		if res.Body != nil {
44300			res.Body.Close()
44301		}
44302		return nil, &googleapi.Error{
44303			Code:   res.StatusCode,
44304			Header: res.Header,
44305		}
44306	}
44307	if err != nil {
44308		return nil, err
44309	}
44310	defer googleapi.CloseBody(res)
44311	if err := googleapi.CheckResponse(res); err != nil {
44312		return nil, err
44313	}
44314	ret := &Report{
44315		ServerResponse: googleapi.ServerResponse{
44316			Header:         res.Header,
44317			HTTPStatusCode: res.StatusCode,
44318		},
44319	}
44320	target := &ret
44321	if err := gensupport.DecodeResponse(target, res); err != nil {
44322		return nil, err
44323	}
44324	return ret, nil
44325	// {
44326	//   "description": "Creates a report.",
44327	//   "httpMethod": "POST",
44328	//   "id": "dfareporting.reports.insert",
44329	//   "parameterOrder": [
44330	//     "profileId"
44331	//   ],
44332	//   "parameters": {
44333	//     "profileId": {
44334	//       "description": "The DFA user profile ID.",
44335	//       "format": "int64",
44336	//       "location": "path",
44337	//       "required": true,
44338	//       "type": "string"
44339	//     }
44340	//   },
44341	//   "path": "userprofiles/{profileId}/reports",
44342	//   "request": {
44343	//     "$ref": "Report"
44344	//   },
44345	//   "response": {
44346	//     "$ref": "Report"
44347	//   },
44348	//   "scopes": [
44349	//     "https://www.googleapis.com/auth/dfareporting"
44350	//   ]
44351	// }
44352
44353}
44354
44355// method id "dfareporting.reports.list":
44356
44357type ReportsListCall struct {
44358	s            *Service
44359	profileId    int64
44360	urlParams_   gensupport.URLParams
44361	ifNoneMatch_ string
44362	ctx_         context.Context
44363	header_      http.Header
44364}
44365
44366// List: Retrieves list of reports.
44367func (r *ReportsService) List(profileId int64) *ReportsListCall {
44368	c := &ReportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44369	c.profileId = profileId
44370	return c
44371}
44372
44373// MaxResults sets the optional parameter "maxResults": Maximum number
44374// of results to return.
44375func (c *ReportsListCall) MaxResults(maxResults int64) *ReportsListCall {
44376	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
44377	return c
44378}
44379
44380// PageToken sets the optional parameter "pageToken": The value of the
44381// nextToken from the previous result page.
44382func (c *ReportsListCall) PageToken(pageToken string) *ReportsListCall {
44383	c.urlParams_.Set("pageToken", pageToken)
44384	return c
44385}
44386
44387// Scope sets the optional parameter "scope": The scope that defines
44388// which results are returned.
44389//
44390// Possible values:
44391//   "ALL" - All reports in account.
44392//   "MINE" (default) - My reports.
44393func (c *ReportsListCall) Scope(scope string) *ReportsListCall {
44394	c.urlParams_.Set("scope", scope)
44395	return c
44396}
44397
44398// SortField sets the optional parameter "sortField": The field by which
44399// to sort the list.
44400//
44401// Possible values:
44402//   "ID" - Sort by report ID.
44403//   "LAST_MODIFIED_TIME" (default) - Sort by 'lastModifiedTime' field.
44404//   "NAME" - Sort by name of reports.
44405func (c *ReportsListCall) SortField(sortField string) *ReportsListCall {
44406	c.urlParams_.Set("sortField", sortField)
44407	return c
44408}
44409
44410// SortOrder sets the optional parameter "sortOrder": Order of sorted
44411// results.
44412//
44413// Possible values:
44414//   "ASCENDING" - Ascending order.
44415//   "DESCENDING" (default) - Descending order.
44416func (c *ReportsListCall) SortOrder(sortOrder string) *ReportsListCall {
44417	c.urlParams_.Set("sortOrder", sortOrder)
44418	return c
44419}
44420
44421// Fields allows partial responses to be retrieved. See
44422// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44423// for more information.
44424func (c *ReportsListCall) Fields(s ...googleapi.Field) *ReportsListCall {
44425	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44426	return c
44427}
44428
44429// IfNoneMatch sets the optional parameter which makes the operation
44430// fail if the object's ETag matches the given value. This is useful for
44431// getting updates only after the object has changed since the last
44432// request. Use googleapi.IsNotModified to check whether the response
44433// error from Do is the result of In-None-Match.
44434func (c *ReportsListCall) IfNoneMatch(entityTag string) *ReportsListCall {
44435	c.ifNoneMatch_ = entityTag
44436	return c
44437}
44438
44439// Context sets the context to be used in this call's Do method. Any
44440// pending HTTP request will be aborted if the provided context is
44441// canceled.
44442func (c *ReportsListCall) Context(ctx context.Context) *ReportsListCall {
44443	c.ctx_ = ctx
44444	return c
44445}
44446
44447// Header returns an http.Header that can be modified by the caller to
44448// add HTTP headers to the request.
44449func (c *ReportsListCall) Header() http.Header {
44450	if c.header_ == nil {
44451		c.header_ = make(http.Header)
44452	}
44453	return c.header_
44454}
44455
44456func (c *ReportsListCall) doRequest(alt string) (*http.Response, error) {
44457	reqHeaders := make(http.Header)
44458	for k, v := range c.header_ {
44459		reqHeaders[k] = v
44460	}
44461	reqHeaders.Set("User-Agent", c.s.userAgent())
44462	if c.ifNoneMatch_ != "" {
44463		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44464	}
44465	var body io.Reader = nil
44466	c.urlParams_.Set("alt", alt)
44467	c.urlParams_.Set("prettyPrint", "false")
44468	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports")
44469	urls += "?" + c.urlParams_.Encode()
44470	req, err := http.NewRequest("GET", urls, body)
44471	if err != nil {
44472		return nil, err
44473	}
44474	req.Header = reqHeaders
44475	googleapi.Expand(req.URL, map[string]string{
44476		"profileId": strconv.FormatInt(c.profileId, 10),
44477	})
44478	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44479}
44480
44481// Do executes the "dfareporting.reports.list" call.
44482// Exactly one of *ReportList or error will be non-nil. Any non-2xx
44483// status code is an error. Response headers are in either
44484// *ReportList.ServerResponse.Header or (if a response was returned at
44485// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
44486// to check whether the returned error was because
44487// http.StatusNotModified was returned.
44488func (c *ReportsListCall) Do(opts ...googleapi.CallOption) (*ReportList, error) {
44489	gensupport.SetOptions(c.urlParams_, opts...)
44490	res, err := c.doRequest("json")
44491	if res != nil && res.StatusCode == http.StatusNotModified {
44492		if res.Body != nil {
44493			res.Body.Close()
44494		}
44495		return nil, &googleapi.Error{
44496			Code:   res.StatusCode,
44497			Header: res.Header,
44498		}
44499	}
44500	if err != nil {
44501		return nil, err
44502	}
44503	defer googleapi.CloseBody(res)
44504	if err := googleapi.CheckResponse(res); err != nil {
44505		return nil, err
44506	}
44507	ret := &ReportList{
44508		ServerResponse: googleapi.ServerResponse{
44509			Header:         res.Header,
44510			HTTPStatusCode: res.StatusCode,
44511		},
44512	}
44513	target := &ret
44514	if err := gensupport.DecodeResponse(target, res); err != nil {
44515		return nil, err
44516	}
44517	return ret, nil
44518	// {
44519	//   "description": "Retrieves list of reports.",
44520	//   "httpMethod": "GET",
44521	//   "id": "dfareporting.reports.list",
44522	//   "parameterOrder": [
44523	//     "profileId"
44524	//   ],
44525	//   "parameters": {
44526	//     "maxResults": {
44527	//       "default": "10",
44528	//       "description": "Maximum number of results to return.",
44529	//       "format": "int32",
44530	//       "location": "query",
44531	//       "maximum": "10",
44532	//       "minimum": "0",
44533	//       "type": "integer"
44534	//     },
44535	//     "pageToken": {
44536	//       "description": "The value of the nextToken from the previous result page.",
44537	//       "location": "query",
44538	//       "type": "string"
44539	//     },
44540	//     "profileId": {
44541	//       "description": "The DFA user profile ID.",
44542	//       "format": "int64",
44543	//       "location": "path",
44544	//       "required": true,
44545	//       "type": "string"
44546	//     },
44547	//     "scope": {
44548	//       "default": "MINE",
44549	//       "description": "The scope that defines which results are returned.",
44550	//       "enum": [
44551	//         "ALL",
44552	//         "MINE"
44553	//       ],
44554	//       "enumDescriptions": [
44555	//         "All reports in account.",
44556	//         "My reports."
44557	//       ],
44558	//       "location": "query",
44559	//       "type": "string"
44560	//     },
44561	//     "sortField": {
44562	//       "default": "LAST_MODIFIED_TIME",
44563	//       "description": "The field by which to sort the list.",
44564	//       "enum": [
44565	//         "ID",
44566	//         "LAST_MODIFIED_TIME",
44567	//         "NAME"
44568	//       ],
44569	//       "enumDescriptions": [
44570	//         "Sort by report ID.",
44571	//         "Sort by 'lastModifiedTime' field.",
44572	//         "Sort by name of reports."
44573	//       ],
44574	//       "location": "query",
44575	//       "type": "string"
44576	//     },
44577	//     "sortOrder": {
44578	//       "default": "DESCENDING",
44579	//       "description": "Order of sorted results.",
44580	//       "enum": [
44581	//         "ASCENDING",
44582	//         "DESCENDING"
44583	//       ],
44584	//       "enumDescriptions": [
44585	//         "Ascending order.",
44586	//         "Descending order."
44587	//       ],
44588	//       "location": "query",
44589	//       "type": "string"
44590	//     }
44591	//   },
44592	//   "path": "userprofiles/{profileId}/reports",
44593	//   "response": {
44594	//     "$ref": "ReportList"
44595	//   },
44596	//   "scopes": [
44597	//     "https://www.googleapis.com/auth/dfareporting"
44598	//   ]
44599	// }
44600
44601}
44602
44603// Pages invokes f for each page of results.
44604// A non-nil error returned from f will halt the iteration.
44605// The provided context supersedes any context provided to the Context method.
44606func (c *ReportsListCall) Pages(ctx context.Context, f func(*ReportList) error) error {
44607	c.ctx_ = ctx
44608	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
44609	for {
44610		x, err := c.Do()
44611		if err != nil {
44612			return err
44613		}
44614		if err := f(x); err != nil {
44615			return err
44616		}
44617		if x.NextPageToken == "" {
44618			return nil
44619		}
44620		c.PageToken(x.NextPageToken)
44621	}
44622}
44623
44624// method id "dfareporting.reports.patch":
44625
44626type ReportsPatchCall struct {
44627	s          *Service
44628	profileId  int64
44629	reportId   int64
44630	report     *Report
44631	urlParams_ gensupport.URLParams
44632	ctx_       context.Context
44633	header_    http.Header
44634}
44635
44636// Patch: Updates a report. This method supports patch semantics.
44637func (r *ReportsService) Patch(profileId int64, reportId int64, report *Report) *ReportsPatchCall {
44638	c := &ReportsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44639	c.profileId = profileId
44640	c.reportId = reportId
44641	c.report = report
44642	return c
44643}
44644
44645// Fields allows partial responses to be retrieved. See
44646// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44647// for more information.
44648func (c *ReportsPatchCall) Fields(s ...googleapi.Field) *ReportsPatchCall {
44649	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44650	return c
44651}
44652
44653// Context sets the context to be used in this call's Do method. Any
44654// pending HTTP request will be aborted if the provided context is
44655// canceled.
44656func (c *ReportsPatchCall) Context(ctx context.Context) *ReportsPatchCall {
44657	c.ctx_ = ctx
44658	return c
44659}
44660
44661// Header returns an http.Header that can be modified by the caller to
44662// add HTTP headers to the request.
44663func (c *ReportsPatchCall) Header() http.Header {
44664	if c.header_ == nil {
44665		c.header_ = make(http.Header)
44666	}
44667	return c.header_
44668}
44669
44670func (c *ReportsPatchCall) doRequest(alt string) (*http.Response, error) {
44671	reqHeaders := make(http.Header)
44672	for k, v := range c.header_ {
44673		reqHeaders[k] = v
44674	}
44675	reqHeaders.Set("User-Agent", c.s.userAgent())
44676	var body io.Reader = nil
44677	body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
44678	if err != nil {
44679		return nil, err
44680	}
44681	reqHeaders.Set("Content-Type", "application/json")
44682	c.urlParams_.Set("alt", alt)
44683	c.urlParams_.Set("prettyPrint", "false")
44684	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44685	urls += "?" + c.urlParams_.Encode()
44686	req, err := http.NewRequest("PATCH", urls, body)
44687	if err != nil {
44688		return nil, err
44689	}
44690	req.Header = reqHeaders
44691	googleapi.Expand(req.URL, map[string]string{
44692		"profileId": strconv.FormatInt(c.profileId, 10),
44693		"reportId":  strconv.FormatInt(c.reportId, 10),
44694	})
44695	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44696}
44697
44698// Do executes the "dfareporting.reports.patch" call.
44699// Exactly one of *Report or error will be non-nil. Any non-2xx status
44700// code is an error. Response headers are in either
44701// *Report.ServerResponse.Header or (if a response was returned at all)
44702// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
44703// check whether the returned error was because http.StatusNotModified
44704// was returned.
44705func (c *ReportsPatchCall) Do(opts ...googleapi.CallOption) (*Report, error) {
44706	gensupport.SetOptions(c.urlParams_, opts...)
44707	res, err := c.doRequest("json")
44708	if res != nil && res.StatusCode == http.StatusNotModified {
44709		if res.Body != nil {
44710			res.Body.Close()
44711		}
44712		return nil, &googleapi.Error{
44713			Code:   res.StatusCode,
44714			Header: res.Header,
44715		}
44716	}
44717	if err != nil {
44718		return nil, err
44719	}
44720	defer googleapi.CloseBody(res)
44721	if err := googleapi.CheckResponse(res); err != nil {
44722		return nil, err
44723	}
44724	ret := &Report{
44725		ServerResponse: googleapi.ServerResponse{
44726			Header:         res.Header,
44727			HTTPStatusCode: res.StatusCode,
44728		},
44729	}
44730	target := &ret
44731	if err := gensupport.DecodeResponse(target, res); err != nil {
44732		return nil, err
44733	}
44734	return ret, nil
44735	// {
44736	//   "description": "Updates a report. This method supports patch semantics.",
44737	//   "httpMethod": "PATCH",
44738	//   "id": "dfareporting.reports.patch",
44739	//   "parameterOrder": [
44740	//     "profileId",
44741	//     "reportId"
44742	//   ],
44743	//   "parameters": {
44744	//     "profileId": {
44745	//       "description": "The DFA user profile ID.",
44746	//       "format": "int64",
44747	//       "location": "path",
44748	//       "required": true,
44749	//       "type": "string"
44750	//     },
44751	//     "reportId": {
44752	//       "description": "The ID of the report.",
44753	//       "format": "int64",
44754	//       "location": "path",
44755	//       "required": true,
44756	//       "type": "string"
44757	//     }
44758	//   },
44759	//   "path": "userprofiles/{profileId}/reports/{reportId}",
44760	//   "request": {
44761	//     "$ref": "Report"
44762	//   },
44763	//   "response": {
44764	//     "$ref": "Report"
44765	//   },
44766	//   "scopes": [
44767	//     "https://www.googleapis.com/auth/dfareporting"
44768	//   ]
44769	// }
44770
44771}
44772
44773// method id "dfareporting.reports.run":
44774
44775type ReportsRunCall struct {
44776	s          *Service
44777	profileId  int64
44778	reportId   int64
44779	urlParams_ gensupport.URLParams
44780	ctx_       context.Context
44781	header_    http.Header
44782}
44783
44784// Run: Runs a report.
44785func (r *ReportsService) Run(profileId int64, reportId int64) *ReportsRunCall {
44786	c := &ReportsRunCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44787	c.profileId = profileId
44788	c.reportId = reportId
44789	return c
44790}
44791
44792// Synchronous sets the optional parameter "synchronous": If set and
44793// true, tries to run the report synchronously.
44794func (c *ReportsRunCall) Synchronous(synchronous bool) *ReportsRunCall {
44795	c.urlParams_.Set("synchronous", fmt.Sprint(synchronous))
44796	return c
44797}
44798
44799// Fields allows partial responses to be retrieved. See
44800// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44801// for more information.
44802func (c *ReportsRunCall) Fields(s ...googleapi.Field) *ReportsRunCall {
44803	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44804	return c
44805}
44806
44807// Context sets the context to be used in this call's Do method. Any
44808// pending HTTP request will be aborted if the provided context is
44809// canceled.
44810func (c *ReportsRunCall) Context(ctx context.Context) *ReportsRunCall {
44811	c.ctx_ = ctx
44812	return c
44813}
44814
44815// Header returns an http.Header that can be modified by the caller to
44816// add HTTP headers to the request.
44817func (c *ReportsRunCall) Header() http.Header {
44818	if c.header_ == nil {
44819		c.header_ = make(http.Header)
44820	}
44821	return c.header_
44822}
44823
44824func (c *ReportsRunCall) doRequest(alt string) (*http.Response, error) {
44825	reqHeaders := make(http.Header)
44826	for k, v := range c.header_ {
44827		reqHeaders[k] = v
44828	}
44829	reqHeaders.Set("User-Agent", c.s.userAgent())
44830	var body io.Reader = nil
44831	c.urlParams_.Set("alt", alt)
44832	c.urlParams_.Set("prettyPrint", "false")
44833	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/run")
44834	urls += "?" + c.urlParams_.Encode()
44835	req, err := http.NewRequest("POST", urls, body)
44836	if err != nil {
44837		return nil, err
44838	}
44839	req.Header = reqHeaders
44840	googleapi.Expand(req.URL, map[string]string{
44841		"profileId": strconv.FormatInt(c.profileId, 10),
44842		"reportId":  strconv.FormatInt(c.reportId, 10),
44843	})
44844	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44845}
44846
44847// Do executes the "dfareporting.reports.run" call.
44848// Exactly one of *File or error will be non-nil. Any non-2xx status
44849// code is an error. Response headers are in either
44850// *File.ServerResponse.Header or (if a response was returned at all) in
44851// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
44852// whether the returned error was because http.StatusNotModified was
44853// returned.
44854func (c *ReportsRunCall) Do(opts ...googleapi.CallOption) (*File, error) {
44855	gensupport.SetOptions(c.urlParams_, opts...)
44856	res, err := c.doRequest("json")
44857	if res != nil && res.StatusCode == http.StatusNotModified {
44858		if res.Body != nil {
44859			res.Body.Close()
44860		}
44861		return nil, &googleapi.Error{
44862			Code:   res.StatusCode,
44863			Header: res.Header,
44864		}
44865	}
44866	if err != nil {
44867		return nil, err
44868	}
44869	defer googleapi.CloseBody(res)
44870	if err := googleapi.CheckResponse(res); err != nil {
44871		return nil, err
44872	}
44873	ret := &File{
44874		ServerResponse: googleapi.ServerResponse{
44875			Header:         res.Header,
44876			HTTPStatusCode: res.StatusCode,
44877		},
44878	}
44879	target := &ret
44880	if err := gensupport.DecodeResponse(target, res); err != nil {
44881		return nil, err
44882	}
44883	return ret, nil
44884	// {
44885	//   "description": "Runs a report.",
44886	//   "httpMethod": "POST",
44887	//   "id": "dfareporting.reports.run",
44888	//   "parameterOrder": [
44889	//     "profileId",
44890	//     "reportId"
44891	//   ],
44892	//   "parameters": {
44893	//     "profileId": {
44894	//       "description": "The DFA profile ID.",
44895	//       "format": "int64",
44896	//       "location": "path",
44897	//       "required": true,
44898	//       "type": "string"
44899	//     },
44900	//     "reportId": {
44901	//       "description": "The ID of the report.",
44902	//       "format": "int64",
44903	//       "location": "path",
44904	//       "required": true,
44905	//       "type": "string"
44906	//     },
44907	//     "synchronous": {
44908	//       "default": "false",
44909	//       "description": "If set and true, tries to run the report synchronously.",
44910	//       "location": "query",
44911	//       "type": "boolean"
44912	//     }
44913	//   },
44914	//   "path": "userprofiles/{profileId}/reports/{reportId}/run",
44915	//   "response": {
44916	//     "$ref": "File"
44917	//   },
44918	//   "scopes": [
44919	//     "https://www.googleapis.com/auth/dfareporting"
44920	//   ]
44921	// }
44922
44923}
44924
44925// method id "dfareporting.reports.update":
44926
44927type ReportsUpdateCall struct {
44928	s          *Service
44929	profileId  int64
44930	reportId   int64
44931	report     *Report
44932	urlParams_ gensupport.URLParams
44933	ctx_       context.Context
44934	header_    http.Header
44935}
44936
44937// Update: Updates a report.
44938func (r *ReportsService) Update(profileId int64, reportId int64, report *Report) *ReportsUpdateCall {
44939	c := &ReportsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44940	c.profileId = profileId
44941	c.reportId = reportId
44942	c.report = report
44943	return c
44944}
44945
44946// Fields allows partial responses to be retrieved. See
44947// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44948// for more information.
44949func (c *ReportsUpdateCall) Fields(s ...googleapi.Field) *ReportsUpdateCall {
44950	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44951	return c
44952}
44953
44954// Context sets the context to be used in this call's Do method. Any
44955// pending HTTP request will be aborted if the provided context is
44956// canceled.
44957func (c *ReportsUpdateCall) Context(ctx context.Context) *ReportsUpdateCall {
44958	c.ctx_ = ctx
44959	return c
44960}
44961
44962// Header returns an http.Header that can be modified by the caller to
44963// add HTTP headers to the request.
44964func (c *ReportsUpdateCall) Header() http.Header {
44965	if c.header_ == nil {
44966		c.header_ = make(http.Header)
44967	}
44968	return c.header_
44969}
44970
44971func (c *ReportsUpdateCall) doRequest(alt string) (*http.Response, error) {
44972	reqHeaders := make(http.Header)
44973	for k, v := range c.header_ {
44974		reqHeaders[k] = v
44975	}
44976	reqHeaders.Set("User-Agent", c.s.userAgent())
44977	var body io.Reader = nil
44978	body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
44979	if err != nil {
44980		return nil, err
44981	}
44982	reqHeaders.Set("Content-Type", "application/json")
44983	c.urlParams_.Set("alt", alt)
44984	c.urlParams_.Set("prettyPrint", "false")
44985	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44986	urls += "?" + c.urlParams_.Encode()
44987	req, err := http.NewRequest("PUT", urls, body)
44988	if err != nil {
44989		return nil, err
44990	}
44991	req.Header = reqHeaders
44992	googleapi.Expand(req.URL, map[string]string{
44993		"profileId": strconv.FormatInt(c.profileId, 10),
44994		"reportId":  strconv.FormatInt(c.reportId, 10),
44995	})
44996	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44997}
44998
44999// Do executes the "dfareporting.reports.update" call.
45000// Exactly one of *Report or error will be non-nil. Any non-2xx status
45001// code is an error. Response headers are in either
45002// *Report.ServerResponse.Header or (if a response was returned at all)
45003// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
45004// check whether the returned error was because http.StatusNotModified
45005// was returned.
45006func (c *ReportsUpdateCall) Do(opts ...googleapi.CallOption) (*Report, error) {
45007	gensupport.SetOptions(c.urlParams_, opts...)
45008	res, err := c.doRequest("json")
45009	if res != nil && res.StatusCode == http.StatusNotModified {
45010		if res.Body != nil {
45011			res.Body.Close()
45012		}
45013		return nil, &googleapi.Error{
45014			Code:   res.StatusCode,
45015			Header: res.Header,
45016		}
45017	}
45018	if err != nil {
45019		return nil, err
45020	}
45021	defer googleapi.CloseBody(res)
45022	if err := googleapi.CheckResponse(res); err != nil {
45023		return nil, err
45024	}
45025	ret := &Report{
45026		ServerResponse: googleapi.ServerResponse{
45027			Header:         res.Header,
45028			HTTPStatusCode: res.StatusCode,
45029		},
45030	}
45031	target := &ret
45032	if err := gensupport.DecodeResponse(target, res); err != nil {
45033		return nil, err
45034	}
45035	return ret, nil
45036	// {
45037	//   "description": "Updates a report.",
45038	//   "httpMethod": "PUT",
45039	//   "id": "dfareporting.reports.update",
45040	//   "parameterOrder": [
45041	//     "profileId",
45042	//     "reportId"
45043	//   ],
45044	//   "parameters": {
45045	//     "profileId": {
45046	//       "description": "The DFA user profile ID.",
45047	//       "format": "int64",
45048	//       "location": "path",
45049	//       "required": true,
45050	//       "type": "string"
45051	//     },
45052	//     "reportId": {
45053	//       "description": "The ID of the report.",
45054	//       "format": "int64",
45055	//       "location": "path",
45056	//       "required": true,
45057	//       "type": "string"
45058	//     }
45059	//   },
45060	//   "path": "userprofiles/{profileId}/reports/{reportId}",
45061	//   "request": {
45062	//     "$ref": "Report"
45063	//   },
45064	//   "response": {
45065	//     "$ref": "Report"
45066	//   },
45067	//   "scopes": [
45068	//     "https://www.googleapis.com/auth/dfareporting"
45069	//   ]
45070	// }
45071
45072}
45073
45074// method id "dfareporting.reports.compatibleFields.query":
45075
45076type ReportsCompatibleFieldsQueryCall struct {
45077	s          *Service
45078	profileId  int64
45079	report     *Report
45080	urlParams_ gensupport.URLParams
45081	ctx_       context.Context
45082	header_    http.Header
45083}
45084
45085// Query: Returns the fields that are compatible to be selected in the
45086// respective sections of a report criteria, given the fields already
45087// selected in the input report and user permissions.
45088func (r *ReportsCompatibleFieldsService) Query(profileId int64, report *Report) *ReportsCompatibleFieldsQueryCall {
45089	c := &ReportsCompatibleFieldsQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45090	c.profileId = profileId
45091	c.report = report
45092	return c
45093}
45094
45095// Fields allows partial responses to be retrieved. See
45096// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45097// for more information.
45098func (c *ReportsCompatibleFieldsQueryCall) Fields(s ...googleapi.Field) *ReportsCompatibleFieldsQueryCall {
45099	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45100	return c
45101}
45102
45103// Context sets the context to be used in this call's Do method. Any
45104// pending HTTP request will be aborted if the provided context is
45105// canceled.
45106func (c *ReportsCompatibleFieldsQueryCall) Context(ctx context.Context) *ReportsCompatibleFieldsQueryCall {
45107	c.ctx_ = ctx
45108	return c
45109}
45110
45111// Header returns an http.Header that can be modified by the caller to
45112// add HTTP headers to the request.
45113func (c *ReportsCompatibleFieldsQueryCall) Header() http.Header {
45114	if c.header_ == nil {
45115		c.header_ = make(http.Header)
45116	}
45117	return c.header_
45118}
45119
45120func (c *ReportsCompatibleFieldsQueryCall) doRequest(alt string) (*http.Response, error) {
45121	reqHeaders := make(http.Header)
45122	for k, v := range c.header_ {
45123		reqHeaders[k] = v
45124	}
45125	reqHeaders.Set("User-Agent", c.s.userAgent())
45126	var body io.Reader = nil
45127	body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
45128	if err != nil {
45129		return nil, err
45130	}
45131	reqHeaders.Set("Content-Type", "application/json")
45132	c.urlParams_.Set("alt", alt)
45133	c.urlParams_.Set("prettyPrint", "false")
45134	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/compatiblefields/query")
45135	urls += "?" + c.urlParams_.Encode()
45136	req, err := http.NewRequest("POST", urls, body)
45137	if err != nil {
45138		return nil, err
45139	}
45140	req.Header = reqHeaders
45141	googleapi.Expand(req.URL, map[string]string{
45142		"profileId": strconv.FormatInt(c.profileId, 10),
45143	})
45144	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45145}
45146
45147// Do executes the "dfareporting.reports.compatibleFields.query" call.
45148// Exactly one of *CompatibleFields or error will be non-nil. Any
45149// non-2xx status code is an error. Response headers are in either
45150// *CompatibleFields.ServerResponse.Header or (if a response was
45151// returned at all) in error.(*googleapi.Error).Header. Use
45152// googleapi.IsNotModified to check whether the returned error was
45153// because http.StatusNotModified was returned.
45154func (c *ReportsCompatibleFieldsQueryCall) Do(opts ...googleapi.CallOption) (*CompatibleFields, error) {
45155	gensupport.SetOptions(c.urlParams_, opts...)
45156	res, err := c.doRequest("json")
45157	if res != nil && res.StatusCode == http.StatusNotModified {
45158		if res.Body != nil {
45159			res.Body.Close()
45160		}
45161		return nil, &googleapi.Error{
45162			Code:   res.StatusCode,
45163			Header: res.Header,
45164		}
45165	}
45166	if err != nil {
45167		return nil, err
45168	}
45169	defer googleapi.CloseBody(res)
45170	if err := googleapi.CheckResponse(res); err != nil {
45171		return nil, err
45172	}
45173	ret := &CompatibleFields{
45174		ServerResponse: googleapi.ServerResponse{
45175			Header:         res.Header,
45176			HTTPStatusCode: res.StatusCode,
45177		},
45178	}
45179	target := &ret
45180	if err := gensupport.DecodeResponse(target, res); err != nil {
45181		return nil, err
45182	}
45183	return ret, nil
45184	// {
45185	//   "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.",
45186	//   "httpMethod": "POST",
45187	//   "id": "dfareporting.reports.compatibleFields.query",
45188	//   "parameterOrder": [
45189	//     "profileId"
45190	//   ],
45191	//   "parameters": {
45192	//     "profileId": {
45193	//       "description": "The DFA user profile ID.",
45194	//       "format": "int64",
45195	//       "location": "path",
45196	//       "required": true,
45197	//       "type": "string"
45198	//     }
45199	//   },
45200	//   "path": "userprofiles/{profileId}/reports/compatiblefields/query",
45201	//   "request": {
45202	//     "$ref": "Report"
45203	//   },
45204	//   "response": {
45205	//     "$ref": "CompatibleFields"
45206	//   },
45207	//   "scopes": [
45208	//     "https://www.googleapis.com/auth/dfareporting"
45209	//   ]
45210	// }
45211
45212}
45213
45214// method id "dfareporting.reports.files.get":
45215
45216type ReportsFilesGetCall struct {
45217	s            *Service
45218	profileId    int64
45219	reportId     int64
45220	fileId       int64
45221	urlParams_   gensupport.URLParams
45222	ifNoneMatch_ string
45223	ctx_         context.Context
45224	header_      http.Header
45225}
45226
45227// Get: Retrieves a report file. This method supports media download.
45228func (r *ReportsFilesService) Get(profileId int64, reportId int64, fileId int64) *ReportsFilesGetCall {
45229	c := &ReportsFilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45230	c.profileId = profileId
45231	c.reportId = reportId
45232	c.fileId = fileId
45233	return c
45234}
45235
45236// Fields allows partial responses to be retrieved. See
45237// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45238// for more information.
45239func (c *ReportsFilesGetCall) Fields(s ...googleapi.Field) *ReportsFilesGetCall {
45240	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45241	return c
45242}
45243
45244// IfNoneMatch sets the optional parameter which makes the operation
45245// fail if the object's ETag matches the given value. This is useful for
45246// getting updates only after the object has changed since the last
45247// request. Use googleapi.IsNotModified to check whether the response
45248// error from Do is the result of In-None-Match.
45249func (c *ReportsFilesGetCall) IfNoneMatch(entityTag string) *ReportsFilesGetCall {
45250	c.ifNoneMatch_ = entityTag
45251	return c
45252}
45253
45254// Context sets the context to be used in this call's Do and Download
45255// methods. Any pending HTTP request will be aborted if the provided
45256// context is canceled.
45257func (c *ReportsFilesGetCall) Context(ctx context.Context) *ReportsFilesGetCall {
45258	c.ctx_ = ctx
45259	return c
45260}
45261
45262// Header returns an http.Header that can be modified by the caller to
45263// add HTTP headers to the request.
45264func (c *ReportsFilesGetCall) Header() http.Header {
45265	if c.header_ == nil {
45266		c.header_ = make(http.Header)
45267	}
45268	return c.header_
45269}
45270
45271func (c *ReportsFilesGetCall) doRequest(alt string) (*http.Response, error) {
45272	reqHeaders := make(http.Header)
45273	for k, v := range c.header_ {
45274		reqHeaders[k] = v
45275	}
45276	reqHeaders.Set("User-Agent", c.s.userAgent())
45277	if c.ifNoneMatch_ != "" {
45278		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45279	}
45280	var body io.Reader = nil
45281	c.urlParams_.Set("alt", alt)
45282	c.urlParams_.Set("prettyPrint", "false")
45283	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/files/{fileId}")
45284	urls += "?" + c.urlParams_.Encode()
45285	req, err := http.NewRequest("GET", urls, body)
45286	if err != nil {
45287		return nil, err
45288	}
45289	req.Header = reqHeaders
45290	googleapi.Expand(req.URL, map[string]string{
45291		"profileId": strconv.FormatInt(c.profileId, 10),
45292		"reportId":  strconv.FormatInt(c.reportId, 10),
45293		"fileId":    strconv.FormatInt(c.fileId, 10),
45294	})
45295	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45296}
45297
45298// Download fetches the API endpoint's "media" value, instead of the normal
45299// API response value. If the returned error is nil, the Response is guaranteed to
45300// have a 2xx status code. Callers must close the Response.Body as usual.
45301func (c *ReportsFilesGetCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
45302	gensupport.SetOptions(c.urlParams_, opts...)
45303	res, err := c.doRequest("media")
45304	if err != nil {
45305		return nil, err
45306	}
45307	if err := googleapi.CheckMediaResponse(res); err != nil {
45308		res.Body.Close()
45309		return nil, err
45310	}
45311	return res, nil
45312}
45313
45314// Do executes the "dfareporting.reports.files.get" call.
45315// Exactly one of *File or error will be non-nil. Any non-2xx status
45316// code is an error. Response headers are in either
45317// *File.ServerResponse.Header or (if a response was returned at all) in
45318// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
45319// whether the returned error was because http.StatusNotModified was
45320// returned.
45321func (c *ReportsFilesGetCall) Do(opts ...googleapi.CallOption) (*File, error) {
45322	gensupport.SetOptions(c.urlParams_, opts...)
45323	res, err := c.doRequest("json")
45324	if res != nil && res.StatusCode == http.StatusNotModified {
45325		if res.Body != nil {
45326			res.Body.Close()
45327		}
45328		return nil, &googleapi.Error{
45329			Code:   res.StatusCode,
45330			Header: res.Header,
45331		}
45332	}
45333	if err != nil {
45334		return nil, err
45335	}
45336	defer googleapi.CloseBody(res)
45337	if err := googleapi.CheckResponse(res); err != nil {
45338		return nil, err
45339	}
45340	ret := &File{
45341		ServerResponse: googleapi.ServerResponse{
45342			Header:         res.Header,
45343			HTTPStatusCode: res.StatusCode,
45344		},
45345	}
45346	target := &ret
45347	if err := gensupport.DecodeResponse(target, res); err != nil {
45348		return nil, err
45349	}
45350	return ret, nil
45351	// {
45352	//   "description": "Retrieves a report file. This method supports media download.",
45353	//   "httpMethod": "GET",
45354	//   "id": "dfareporting.reports.files.get",
45355	//   "parameterOrder": [
45356	//     "profileId",
45357	//     "reportId",
45358	//     "fileId"
45359	//   ],
45360	//   "parameters": {
45361	//     "fileId": {
45362	//       "description": "The ID of the report file.",
45363	//       "format": "int64",
45364	//       "location": "path",
45365	//       "required": true,
45366	//       "type": "string"
45367	//     },
45368	//     "profileId": {
45369	//       "description": "The DFA profile ID.",
45370	//       "format": "int64",
45371	//       "location": "path",
45372	//       "required": true,
45373	//       "type": "string"
45374	//     },
45375	//     "reportId": {
45376	//       "description": "The ID of the report.",
45377	//       "format": "int64",
45378	//       "location": "path",
45379	//       "required": true,
45380	//       "type": "string"
45381	//     }
45382	//   },
45383	//   "path": "userprofiles/{profileId}/reports/{reportId}/files/{fileId}",
45384	//   "response": {
45385	//     "$ref": "File"
45386	//   },
45387	//   "scopes": [
45388	//     "https://www.googleapis.com/auth/dfareporting"
45389	//   ],
45390	//   "supportsMediaDownload": true
45391	// }
45392
45393}
45394
45395// method id "dfareporting.reports.files.list":
45396
45397type ReportsFilesListCall struct {
45398	s            *Service
45399	profileId    int64
45400	reportId     int64
45401	urlParams_   gensupport.URLParams
45402	ifNoneMatch_ string
45403	ctx_         context.Context
45404	header_      http.Header
45405}
45406
45407// List: Lists files for a report.
45408func (r *ReportsFilesService) List(profileId int64, reportId int64) *ReportsFilesListCall {
45409	c := &ReportsFilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45410	c.profileId = profileId
45411	c.reportId = reportId
45412	return c
45413}
45414
45415// MaxResults sets the optional parameter "maxResults": Maximum number
45416// of results to return.
45417func (c *ReportsFilesListCall) MaxResults(maxResults int64) *ReportsFilesListCall {
45418	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
45419	return c
45420}
45421
45422// PageToken sets the optional parameter "pageToken": The value of the
45423// nextToken from the previous result page.
45424func (c *ReportsFilesListCall) PageToken(pageToken string) *ReportsFilesListCall {
45425	c.urlParams_.Set("pageToken", pageToken)
45426	return c
45427}
45428
45429// SortField sets the optional parameter "sortField": The field by which
45430// to sort the list.
45431//
45432// Possible values:
45433//   "ID" - Sort by file ID.
45434//   "LAST_MODIFIED_TIME" (default) - Sort by 'lastmodifiedAt' field.
45435func (c *ReportsFilesListCall) SortField(sortField string) *ReportsFilesListCall {
45436	c.urlParams_.Set("sortField", sortField)
45437	return c
45438}
45439
45440// SortOrder sets the optional parameter "sortOrder": Order of sorted
45441// results.
45442//
45443// Possible values:
45444//   "ASCENDING" - Ascending order.
45445//   "DESCENDING" (default) - Descending order.
45446func (c *ReportsFilesListCall) SortOrder(sortOrder string) *ReportsFilesListCall {
45447	c.urlParams_.Set("sortOrder", sortOrder)
45448	return c
45449}
45450
45451// Fields allows partial responses to be retrieved. See
45452// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45453// for more information.
45454func (c *ReportsFilesListCall) Fields(s ...googleapi.Field) *ReportsFilesListCall {
45455	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45456	return c
45457}
45458
45459// IfNoneMatch sets the optional parameter which makes the operation
45460// fail if the object's ETag matches the given value. This is useful for
45461// getting updates only after the object has changed since the last
45462// request. Use googleapi.IsNotModified to check whether the response
45463// error from Do is the result of In-None-Match.
45464func (c *ReportsFilesListCall) IfNoneMatch(entityTag string) *ReportsFilesListCall {
45465	c.ifNoneMatch_ = entityTag
45466	return c
45467}
45468
45469// Context sets the context to be used in this call's Do method. Any
45470// pending HTTP request will be aborted if the provided context is
45471// canceled.
45472func (c *ReportsFilesListCall) Context(ctx context.Context) *ReportsFilesListCall {
45473	c.ctx_ = ctx
45474	return c
45475}
45476
45477// Header returns an http.Header that can be modified by the caller to
45478// add HTTP headers to the request.
45479func (c *ReportsFilesListCall) Header() http.Header {
45480	if c.header_ == nil {
45481		c.header_ = make(http.Header)
45482	}
45483	return c.header_
45484}
45485
45486func (c *ReportsFilesListCall) doRequest(alt string) (*http.Response, error) {
45487	reqHeaders := make(http.Header)
45488	for k, v := range c.header_ {
45489		reqHeaders[k] = v
45490	}
45491	reqHeaders.Set("User-Agent", c.s.userAgent())
45492	if c.ifNoneMatch_ != "" {
45493		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45494	}
45495	var body io.Reader = nil
45496	c.urlParams_.Set("alt", alt)
45497	c.urlParams_.Set("prettyPrint", "false")
45498	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/files")
45499	urls += "?" + c.urlParams_.Encode()
45500	req, err := http.NewRequest("GET", urls, body)
45501	if err != nil {
45502		return nil, err
45503	}
45504	req.Header = reqHeaders
45505	googleapi.Expand(req.URL, map[string]string{
45506		"profileId": strconv.FormatInt(c.profileId, 10),
45507		"reportId":  strconv.FormatInt(c.reportId, 10),
45508	})
45509	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45510}
45511
45512// Do executes the "dfareporting.reports.files.list" call.
45513// Exactly one of *FileList or error will be non-nil. Any non-2xx status
45514// code is an error. Response headers are in either
45515// *FileList.ServerResponse.Header or (if a response was returned at
45516// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
45517// to check whether the returned error was because
45518// http.StatusNotModified was returned.
45519func (c *ReportsFilesListCall) Do(opts ...googleapi.CallOption) (*FileList, error) {
45520	gensupport.SetOptions(c.urlParams_, opts...)
45521	res, err := c.doRequest("json")
45522	if res != nil && res.StatusCode == http.StatusNotModified {
45523		if res.Body != nil {
45524			res.Body.Close()
45525		}
45526		return nil, &googleapi.Error{
45527			Code:   res.StatusCode,
45528			Header: res.Header,
45529		}
45530	}
45531	if err != nil {
45532		return nil, err
45533	}
45534	defer googleapi.CloseBody(res)
45535	if err := googleapi.CheckResponse(res); err != nil {
45536		return nil, err
45537	}
45538	ret := &FileList{
45539		ServerResponse: googleapi.ServerResponse{
45540			Header:         res.Header,
45541			HTTPStatusCode: res.StatusCode,
45542		},
45543	}
45544	target := &ret
45545	if err := gensupport.DecodeResponse(target, res); err != nil {
45546		return nil, err
45547	}
45548	return ret, nil
45549	// {
45550	//   "description": "Lists files for a report.",
45551	//   "httpMethod": "GET",
45552	//   "id": "dfareporting.reports.files.list",
45553	//   "parameterOrder": [
45554	//     "profileId",
45555	//     "reportId"
45556	//   ],
45557	//   "parameters": {
45558	//     "maxResults": {
45559	//       "default": "10",
45560	//       "description": "Maximum number of results to return.",
45561	//       "format": "int32",
45562	//       "location": "query",
45563	//       "maximum": "10",
45564	//       "minimum": "0",
45565	//       "type": "integer"
45566	//     },
45567	//     "pageToken": {
45568	//       "description": "The value of the nextToken from the previous result page.",
45569	//       "location": "query",
45570	//       "type": "string"
45571	//     },
45572	//     "profileId": {
45573	//       "description": "The DFA profile ID.",
45574	//       "format": "int64",
45575	//       "location": "path",
45576	//       "required": true,
45577	//       "type": "string"
45578	//     },
45579	//     "reportId": {
45580	//       "description": "The ID of the parent report.",
45581	//       "format": "int64",
45582	//       "location": "path",
45583	//       "required": true,
45584	//       "type": "string"
45585	//     },
45586	//     "sortField": {
45587	//       "default": "LAST_MODIFIED_TIME",
45588	//       "description": "The field by which to sort the list.",
45589	//       "enum": [
45590	//         "ID",
45591	//         "LAST_MODIFIED_TIME"
45592	//       ],
45593	//       "enumDescriptions": [
45594	//         "Sort by file ID.",
45595	//         "Sort by 'lastmodifiedAt' field."
45596	//       ],
45597	//       "location": "query",
45598	//       "type": "string"
45599	//     },
45600	//     "sortOrder": {
45601	//       "default": "DESCENDING",
45602	//       "description": "Order of sorted results.",
45603	//       "enum": [
45604	//         "ASCENDING",
45605	//         "DESCENDING"
45606	//       ],
45607	//       "enumDescriptions": [
45608	//         "Ascending order.",
45609	//         "Descending order."
45610	//       ],
45611	//       "location": "query",
45612	//       "type": "string"
45613	//     }
45614	//   },
45615	//   "path": "userprofiles/{profileId}/reports/{reportId}/files",
45616	//   "response": {
45617	//     "$ref": "FileList"
45618	//   },
45619	//   "scopes": [
45620	//     "https://www.googleapis.com/auth/dfareporting"
45621	//   ]
45622	// }
45623
45624}
45625
45626// Pages invokes f for each page of results.
45627// A non-nil error returned from f will halt the iteration.
45628// The provided context supersedes any context provided to the Context method.
45629func (c *ReportsFilesListCall) Pages(ctx context.Context, f func(*FileList) error) error {
45630	c.ctx_ = ctx
45631	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
45632	for {
45633		x, err := c.Do()
45634		if err != nil {
45635			return err
45636		}
45637		if err := f(x); err != nil {
45638			return err
45639		}
45640		if x.NextPageToken == "" {
45641			return nil
45642		}
45643		c.PageToken(x.NextPageToken)
45644	}
45645}
45646
45647// method id "dfareporting.sites.get":
45648
45649type SitesGetCall struct {
45650	s            *Service
45651	profileId    int64
45652	id           int64
45653	urlParams_   gensupport.URLParams
45654	ifNoneMatch_ string
45655	ctx_         context.Context
45656	header_      http.Header
45657}
45658
45659// Get: Gets one site by ID.
45660func (r *SitesService) Get(profileId int64, id int64) *SitesGetCall {
45661	c := &SitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45662	c.profileId = profileId
45663	c.id = id
45664	return c
45665}
45666
45667// Fields allows partial responses to be retrieved. See
45668// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45669// for more information.
45670func (c *SitesGetCall) Fields(s ...googleapi.Field) *SitesGetCall {
45671	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45672	return c
45673}
45674
45675// IfNoneMatch sets the optional parameter which makes the operation
45676// fail if the object's ETag matches the given value. This is useful for
45677// getting updates only after the object has changed since the last
45678// request. Use googleapi.IsNotModified to check whether the response
45679// error from Do is the result of In-None-Match.
45680func (c *SitesGetCall) IfNoneMatch(entityTag string) *SitesGetCall {
45681	c.ifNoneMatch_ = entityTag
45682	return c
45683}
45684
45685// Context sets the context to be used in this call's Do method. Any
45686// pending HTTP request will be aborted if the provided context is
45687// canceled.
45688func (c *SitesGetCall) Context(ctx context.Context) *SitesGetCall {
45689	c.ctx_ = ctx
45690	return c
45691}
45692
45693// Header returns an http.Header that can be modified by the caller to
45694// add HTTP headers to the request.
45695func (c *SitesGetCall) Header() http.Header {
45696	if c.header_ == nil {
45697		c.header_ = make(http.Header)
45698	}
45699	return c.header_
45700}
45701
45702func (c *SitesGetCall) doRequest(alt string) (*http.Response, error) {
45703	reqHeaders := make(http.Header)
45704	for k, v := range c.header_ {
45705		reqHeaders[k] = v
45706	}
45707	reqHeaders.Set("User-Agent", c.s.userAgent())
45708	if c.ifNoneMatch_ != "" {
45709		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45710	}
45711	var body io.Reader = nil
45712	c.urlParams_.Set("alt", alt)
45713	c.urlParams_.Set("prettyPrint", "false")
45714	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites/{id}")
45715	urls += "?" + c.urlParams_.Encode()
45716	req, err := http.NewRequest("GET", urls, body)
45717	if err != nil {
45718		return nil, err
45719	}
45720	req.Header = reqHeaders
45721	googleapi.Expand(req.URL, map[string]string{
45722		"profileId": strconv.FormatInt(c.profileId, 10),
45723		"id":        strconv.FormatInt(c.id, 10),
45724	})
45725	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45726}
45727
45728// Do executes the "dfareporting.sites.get" call.
45729// Exactly one of *Site or error will be non-nil. Any non-2xx status
45730// code is an error. Response headers are in either
45731// *Site.ServerResponse.Header or (if a response was returned at all) in
45732// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
45733// whether the returned error was because http.StatusNotModified was
45734// returned.
45735func (c *SitesGetCall) Do(opts ...googleapi.CallOption) (*Site, error) {
45736	gensupport.SetOptions(c.urlParams_, opts...)
45737	res, err := c.doRequest("json")
45738	if res != nil && res.StatusCode == http.StatusNotModified {
45739		if res.Body != nil {
45740			res.Body.Close()
45741		}
45742		return nil, &googleapi.Error{
45743			Code:   res.StatusCode,
45744			Header: res.Header,
45745		}
45746	}
45747	if err != nil {
45748		return nil, err
45749	}
45750	defer googleapi.CloseBody(res)
45751	if err := googleapi.CheckResponse(res); err != nil {
45752		return nil, err
45753	}
45754	ret := &Site{
45755		ServerResponse: googleapi.ServerResponse{
45756			Header:         res.Header,
45757			HTTPStatusCode: res.StatusCode,
45758		},
45759	}
45760	target := &ret
45761	if err := gensupport.DecodeResponse(target, res); err != nil {
45762		return nil, err
45763	}
45764	return ret, nil
45765	// {
45766	//   "description": "Gets one site by ID.",
45767	//   "httpMethod": "GET",
45768	//   "id": "dfareporting.sites.get",
45769	//   "parameterOrder": [
45770	//     "profileId",
45771	//     "id"
45772	//   ],
45773	//   "parameters": {
45774	//     "id": {
45775	//       "description": "Site ID.",
45776	//       "format": "int64",
45777	//       "location": "path",
45778	//       "required": true,
45779	//       "type": "string"
45780	//     },
45781	//     "profileId": {
45782	//       "description": "User profile ID associated with this request.",
45783	//       "format": "int64",
45784	//       "location": "path",
45785	//       "required": true,
45786	//       "type": "string"
45787	//     }
45788	//   },
45789	//   "path": "userprofiles/{profileId}/sites/{id}",
45790	//   "response": {
45791	//     "$ref": "Site"
45792	//   },
45793	//   "scopes": [
45794	//     "https://www.googleapis.com/auth/dfatrafficking"
45795	//   ]
45796	// }
45797
45798}
45799
45800// method id "dfareporting.sites.insert":
45801
45802type SitesInsertCall struct {
45803	s          *Service
45804	profileId  int64
45805	site       *Site
45806	urlParams_ gensupport.URLParams
45807	ctx_       context.Context
45808	header_    http.Header
45809}
45810
45811// Insert: Inserts a new site.
45812func (r *SitesService) Insert(profileId int64, site *Site) *SitesInsertCall {
45813	c := &SitesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45814	c.profileId = profileId
45815	c.site = site
45816	return c
45817}
45818
45819// Fields allows partial responses to be retrieved. See
45820// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45821// for more information.
45822func (c *SitesInsertCall) Fields(s ...googleapi.Field) *SitesInsertCall {
45823	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45824	return c
45825}
45826
45827// Context sets the context to be used in this call's Do method. Any
45828// pending HTTP request will be aborted if the provided context is
45829// canceled.
45830func (c *SitesInsertCall) Context(ctx context.Context) *SitesInsertCall {
45831	c.ctx_ = ctx
45832	return c
45833}
45834
45835// Header returns an http.Header that can be modified by the caller to
45836// add HTTP headers to the request.
45837func (c *SitesInsertCall) Header() http.Header {
45838	if c.header_ == nil {
45839		c.header_ = make(http.Header)
45840	}
45841	return c.header_
45842}
45843
45844func (c *SitesInsertCall) doRequest(alt string) (*http.Response, error) {
45845	reqHeaders := make(http.Header)
45846	for k, v := range c.header_ {
45847		reqHeaders[k] = v
45848	}
45849	reqHeaders.Set("User-Agent", c.s.userAgent())
45850	var body io.Reader = nil
45851	body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
45852	if err != nil {
45853		return nil, err
45854	}
45855	reqHeaders.Set("Content-Type", "application/json")
45856	c.urlParams_.Set("alt", alt)
45857	c.urlParams_.Set("prettyPrint", "false")
45858	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
45859	urls += "?" + c.urlParams_.Encode()
45860	req, err := http.NewRequest("POST", urls, body)
45861	if err != nil {
45862		return nil, err
45863	}
45864	req.Header = reqHeaders
45865	googleapi.Expand(req.URL, map[string]string{
45866		"profileId": strconv.FormatInt(c.profileId, 10),
45867	})
45868	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45869}
45870
45871// Do executes the "dfareporting.sites.insert" call.
45872// Exactly one of *Site or error will be non-nil. Any non-2xx status
45873// code is an error. Response headers are in either
45874// *Site.ServerResponse.Header or (if a response was returned at all) in
45875// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
45876// whether the returned error was because http.StatusNotModified was
45877// returned.
45878func (c *SitesInsertCall) Do(opts ...googleapi.CallOption) (*Site, error) {
45879	gensupport.SetOptions(c.urlParams_, opts...)
45880	res, err := c.doRequest("json")
45881	if res != nil && res.StatusCode == http.StatusNotModified {
45882		if res.Body != nil {
45883			res.Body.Close()
45884		}
45885		return nil, &googleapi.Error{
45886			Code:   res.StatusCode,
45887			Header: res.Header,
45888		}
45889	}
45890	if err != nil {
45891		return nil, err
45892	}
45893	defer googleapi.CloseBody(res)
45894	if err := googleapi.CheckResponse(res); err != nil {
45895		return nil, err
45896	}
45897	ret := &Site{
45898		ServerResponse: googleapi.ServerResponse{
45899			Header:         res.Header,
45900			HTTPStatusCode: res.StatusCode,
45901		},
45902	}
45903	target := &ret
45904	if err := gensupport.DecodeResponse(target, res); err != nil {
45905		return nil, err
45906	}
45907	return ret, nil
45908	// {
45909	//   "description": "Inserts a new site.",
45910	//   "httpMethod": "POST",
45911	//   "id": "dfareporting.sites.insert",
45912	//   "parameterOrder": [
45913	//     "profileId"
45914	//   ],
45915	//   "parameters": {
45916	//     "profileId": {
45917	//       "description": "User profile ID associated with this request.",
45918	//       "format": "int64",
45919	//       "location": "path",
45920	//       "required": true,
45921	//       "type": "string"
45922	//     }
45923	//   },
45924	//   "path": "userprofiles/{profileId}/sites",
45925	//   "request": {
45926	//     "$ref": "Site"
45927	//   },
45928	//   "response": {
45929	//     "$ref": "Site"
45930	//   },
45931	//   "scopes": [
45932	//     "https://www.googleapis.com/auth/dfatrafficking"
45933	//   ]
45934	// }
45935
45936}
45937
45938// method id "dfareporting.sites.list":
45939
45940type SitesListCall struct {
45941	s            *Service
45942	profileId    int64
45943	urlParams_   gensupport.URLParams
45944	ifNoneMatch_ string
45945	ctx_         context.Context
45946	header_      http.Header
45947}
45948
45949// List: Retrieves a list of sites, possibly filtered. This method
45950// supports paging.
45951func (r *SitesService) List(profileId int64) *SitesListCall {
45952	c := &SitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45953	c.profileId = profileId
45954	return c
45955}
45956
45957// AcceptsInStreamVideoPlacements sets the optional parameter
45958// "acceptsInStreamVideoPlacements": This search filter is no longer
45959// supported and will have no effect on the results returned.
45960func (c *SitesListCall) AcceptsInStreamVideoPlacements(acceptsInStreamVideoPlacements bool) *SitesListCall {
45961	c.urlParams_.Set("acceptsInStreamVideoPlacements", fmt.Sprint(acceptsInStreamVideoPlacements))
45962	return c
45963}
45964
45965// AcceptsInterstitialPlacements sets the optional parameter
45966// "acceptsInterstitialPlacements": This search filter is no longer
45967// supported and will have no effect on the results returned.
45968func (c *SitesListCall) AcceptsInterstitialPlacements(acceptsInterstitialPlacements bool) *SitesListCall {
45969	c.urlParams_.Set("acceptsInterstitialPlacements", fmt.Sprint(acceptsInterstitialPlacements))
45970	return c
45971}
45972
45973// AcceptsPublisherPaidPlacements sets the optional parameter
45974// "acceptsPublisherPaidPlacements": Select only sites that accept
45975// publisher paid placements.
45976func (c *SitesListCall) AcceptsPublisherPaidPlacements(acceptsPublisherPaidPlacements bool) *SitesListCall {
45977	c.urlParams_.Set("acceptsPublisherPaidPlacements", fmt.Sprint(acceptsPublisherPaidPlacements))
45978	return c
45979}
45980
45981// AdWordsSite sets the optional parameter "adWordsSite": Select only
45982// AdWords sites.
45983func (c *SitesListCall) AdWordsSite(adWordsSite bool) *SitesListCall {
45984	c.urlParams_.Set("adWordsSite", fmt.Sprint(adWordsSite))
45985	return c
45986}
45987
45988// Approved sets the optional parameter "approved": Select only approved
45989// sites.
45990func (c *SitesListCall) Approved(approved bool) *SitesListCall {
45991	c.urlParams_.Set("approved", fmt.Sprint(approved))
45992	return c
45993}
45994
45995// CampaignIds sets the optional parameter "campaignIds": Select only
45996// sites with these campaign IDs.
45997func (c *SitesListCall) CampaignIds(campaignIds ...int64) *SitesListCall {
45998	var campaignIds_ []string
45999	for _, v := range campaignIds {
46000		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
46001	}
46002	c.urlParams_.SetMulti("campaignIds", campaignIds_)
46003	return c
46004}
46005
46006// DirectorySiteIds sets the optional parameter "directorySiteIds":
46007// Select only sites with these directory site IDs.
46008func (c *SitesListCall) DirectorySiteIds(directorySiteIds ...int64) *SitesListCall {
46009	var directorySiteIds_ []string
46010	for _, v := range directorySiteIds {
46011		directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
46012	}
46013	c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
46014	return c
46015}
46016
46017// Ids sets the optional parameter "ids": Select only sites with these
46018// IDs.
46019func (c *SitesListCall) Ids(ids ...int64) *SitesListCall {
46020	var ids_ []string
46021	for _, v := range ids {
46022		ids_ = append(ids_, fmt.Sprint(v))
46023	}
46024	c.urlParams_.SetMulti("ids", ids_)
46025	return c
46026}
46027
46028// MaxResults sets the optional parameter "maxResults": Maximum number
46029// of results to return.
46030func (c *SitesListCall) MaxResults(maxResults int64) *SitesListCall {
46031	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
46032	return c
46033}
46034
46035// PageToken sets the optional parameter "pageToken": Value of the
46036// nextPageToken from the previous result page.
46037func (c *SitesListCall) PageToken(pageToken string) *SitesListCall {
46038	c.urlParams_.Set("pageToken", pageToken)
46039	return c
46040}
46041
46042// SearchString sets the optional parameter "searchString": Allows
46043// searching for objects by name, ID or keyName. Wildcards (*) are
46044// allowed. For example, "site*2015" will return objects with names like
46045// "site June 2015", "site April 2015", or simply "site 2015". Most of
46046// the searches also add wildcards implicitly at the start and the end
46047// of the search string. For example, a search string of "site" will
46048// match objects with name "my site", "site 2015", or simply "site".
46049func (c *SitesListCall) SearchString(searchString string) *SitesListCall {
46050	c.urlParams_.Set("searchString", searchString)
46051	return c
46052}
46053
46054// SortField sets the optional parameter "sortField": Field by which to
46055// sort the list.
46056//
46057// Possible values:
46058//   "ID" (default)
46059//   "NAME"
46060func (c *SitesListCall) SortField(sortField string) *SitesListCall {
46061	c.urlParams_.Set("sortField", sortField)
46062	return c
46063}
46064
46065// SortOrder sets the optional parameter "sortOrder": Order of sorted
46066// results.
46067//
46068// Possible values:
46069//   "ASCENDING" (default)
46070//   "DESCENDING"
46071func (c *SitesListCall) SortOrder(sortOrder string) *SitesListCall {
46072	c.urlParams_.Set("sortOrder", sortOrder)
46073	return c
46074}
46075
46076// SubaccountId sets the optional parameter "subaccountId": Select only
46077// sites with this subaccount ID.
46078func (c *SitesListCall) SubaccountId(subaccountId int64) *SitesListCall {
46079	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
46080	return c
46081}
46082
46083// UnmappedSite sets the optional parameter "unmappedSite": Select only
46084// sites that have not been mapped to a directory site.
46085func (c *SitesListCall) UnmappedSite(unmappedSite bool) *SitesListCall {
46086	c.urlParams_.Set("unmappedSite", fmt.Sprint(unmappedSite))
46087	return c
46088}
46089
46090// Fields allows partial responses to be retrieved. See
46091// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46092// for more information.
46093func (c *SitesListCall) Fields(s ...googleapi.Field) *SitesListCall {
46094	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46095	return c
46096}
46097
46098// IfNoneMatch sets the optional parameter which makes the operation
46099// fail if the object's ETag matches the given value. This is useful for
46100// getting updates only after the object has changed since the last
46101// request. Use googleapi.IsNotModified to check whether the response
46102// error from Do is the result of In-None-Match.
46103func (c *SitesListCall) IfNoneMatch(entityTag string) *SitesListCall {
46104	c.ifNoneMatch_ = entityTag
46105	return c
46106}
46107
46108// Context sets the context to be used in this call's Do method. Any
46109// pending HTTP request will be aborted if the provided context is
46110// canceled.
46111func (c *SitesListCall) Context(ctx context.Context) *SitesListCall {
46112	c.ctx_ = ctx
46113	return c
46114}
46115
46116// Header returns an http.Header that can be modified by the caller to
46117// add HTTP headers to the request.
46118func (c *SitesListCall) Header() http.Header {
46119	if c.header_ == nil {
46120		c.header_ = make(http.Header)
46121	}
46122	return c.header_
46123}
46124
46125func (c *SitesListCall) doRequest(alt string) (*http.Response, error) {
46126	reqHeaders := make(http.Header)
46127	for k, v := range c.header_ {
46128		reqHeaders[k] = v
46129	}
46130	reqHeaders.Set("User-Agent", c.s.userAgent())
46131	if c.ifNoneMatch_ != "" {
46132		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46133	}
46134	var body io.Reader = nil
46135	c.urlParams_.Set("alt", alt)
46136	c.urlParams_.Set("prettyPrint", "false")
46137	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46138	urls += "?" + c.urlParams_.Encode()
46139	req, err := http.NewRequest("GET", urls, body)
46140	if err != nil {
46141		return nil, err
46142	}
46143	req.Header = reqHeaders
46144	googleapi.Expand(req.URL, map[string]string{
46145		"profileId": strconv.FormatInt(c.profileId, 10),
46146	})
46147	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46148}
46149
46150// Do executes the "dfareporting.sites.list" call.
46151// Exactly one of *SitesListResponse or error will be non-nil. Any
46152// non-2xx status code is an error. Response headers are in either
46153// *SitesListResponse.ServerResponse.Header or (if a response was
46154// returned at all) in error.(*googleapi.Error).Header. Use
46155// googleapi.IsNotModified to check whether the returned error was
46156// because http.StatusNotModified was returned.
46157func (c *SitesListCall) Do(opts ...googleapi.CallOption) (*SitesListResponse, error) {
46158	gensupport.SetOptions(c.urlParams_, opts...)
46159	res, err := c.doRequest("json")
46160	if res != nil && res.StatusCode == http.StatusNotModified {
46161		if res.Body != nil {
46162			res.Body.Close()
46163		}
46164		return nil, &googleapi.Error{
46165			Code:   res.StatusCode,
46166			Header: res.Header,
46167		}
46168	}
46169	if err != nil {
46170		return nil, err
46171	}
46172	defer googleapi.CloseBody(res)
46173	if err := googleapi.CheckResponse(res); err != nil {
46174		return nil, err
46175	}
46176	ret := &SitesListResponse{
46177		ServerResponse: googleapi.ServerResponse{
46178			Header:         res.Header,
46179			HTTPStatusCode: res.StatusCode,
46180		},
46181	}
46182	target := &ret
46183	if err := gensupport.DecodeResponse(target, res); err != nil {
46184		return nil, err
46185	}
46186	return ret, nil
46187	// {
46188	//   "description": "Retrieves a list of sites, possibly filtered. This method supports paging.",
46189	//   "httpMethod": "GET",
46190	//   "id": "dfareporting.sites.list",
46191	//   "parameterOrder": [
46192	//     "profileId"
46193	//   ],
46194	//   "parameters": {
46195	//     "acceptsInStreamVideoPlacements": {
46196	//       "description": "This search filter is no longer supported and will have no effect on the results returned.",
46197	//       "location": "query",
46198	//       "type": "boolean"
46199	//     },
46200	//     "acceptsInterstitialPlacements": {
46201	//       "description": "This search filter is no longer supported and will have no effect on the results returned.",
46202	//       "location": "query",
46203	//       "type": "boolean"
46204	//     },
46205	//     "acceptsPublisherPaidPlacements": {
46206	//       "description": "Select only sites that accept publisher paid placements.",
46207	//       "location": "query",
46208	//       "type": "boolean"
46209	//     },
46210	//     "adWordsSite": {
46211	//       "description": "Select only AdWords sites.",
46212	//       "location": "query",
46213	//       "type": "boolean"
46214	//     },
46215	//     "approved": {
46216	//       "description": "Select only approved sites.",
46217	//       "location": "query",
46218	//       "type": "boolean"
46219	//     },
46220	//     "campaignIds": {
46221	//       "description": "Select only sites with these campaign IDs.",
46222	//       "format": "int64",
46223	//       "location": "query",
46224	//       "repeated": true,
46225	//       "type": "string"
46226	//     },
46227	//     "directorySiteIds": {
46228	//       "description": "Select only sites with these directory site IDs.",
46229	//       "format": "int64",
46230	//       "location": "query",
46231	//       "repeated": true,
46232	//       "type": "string"
46233	//     },
46234	//     "ids": {
46235	//       "description": "Select only sites with these IDs.",
46236	//       "format": "int64",
46237	//       "location": "query",
46238	//       "repeated": true,
46239	//       "type": "string"
46240	//     },
46241	//     "maxResults": {
46242	//       "default": "1000",
46243	//       "description": "Maximum number of results to return.",
46244	//       "format": "int32",
46245	//       "location": "query",
46246	//       "maximum": "1000",
46247	//       "minimum": "0",
46248	//       "type": "integer"
46249	//     },
46250	//     "pageToken": {
46251	//       "description": "Value of the nextPageToken from the previous result page.",
46252	//       "location": "query",
46253	//       "type": "string"
46254	//     },
46255	//     "profileId": {
46256	//       "description": "User profile ID associated with this request.",
46257	//       "format": "int64",
46258	//       "location": "path",
46259	//       "required": true,
46260	//       "type": "string"
46261	//     },
46262	//     "searchString": {
46263	//       "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\".",
46264	//       "location": "query",
46265	//       "type": "string"
46266	//     },
46267	//     "sortField": {
46268	//       "default": "ID",
46269	//       "description": "Field by which to sort the list.",
46270	//       "enum": [
46271	//         "ID",
46272	//         "NAME"
46273	//       ],
46274	//       "enumDescriptions": [
46275	//         "",
46276	//         ""
46277	//       ],
46278	//       "location": "query",
46279	//       "type": "string"
46280	//     },
46281	//     "sortOrder": {
46282	//       "default": "ASCENDING",
46283	//       "description": "Order of sorted results.",
46284	//       "enum": [
46285	//         "ASCENDING",
46286	//         "DESCENDING"
46287	//       ],
46288	//       "enumDescriptions": [
46289	//         "",
46290	//         ""
46291	//       ],
46292	//       "location": "query",
46293	//       "type": "string"
46294	//     },
46295	//     "subaccountId": {
46296	//       "description": "Select only sites with this subaccount ID.",
46297	//       "format": "int64",
46298	//       "location": "query",
46299	//       "type": "string"
46300	//     },
46301	//     "unmappedSite": {
46302	//       "description": "Select only sites that have not been mapped to a directory site.",
46303	//       "location": "query",
46304	//       "type": "boolean"
46305	//     }
46306	//   },
46307	//   "path": "userprofiles/{profileId}/sites",
46308	//   "response": {
46309	//     "$ref": "SitesListResponse"
46310	//   },
46311	//   "scopes": [
46312	//     "https://www.googleapis.com/auth/dfatrafficking"
46313	//   ]
46314	// }
46315
46316}
46317
46318// Pages invokes f for each page of results.
46319// A non-nil error returned from f will halt the iteration.
46320// The provided context supersedes any context provided to the Context method.
46321func (c *SitesListCall) Pages(ctx context.Context, f func(*SitesListResponse) error) error {
46322	c.ctx_ = ctx
46323	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
46324	for {
46325		x, err := c.Do()
46326		if err != nil {
46327			return err
46328		}
46329		if err := f(x); err != nil {
46330			return err
46331		}
46332		if x.NextPageToken == "" {
46333			return nil
46334		}
46335		c.PageToken(x.NextPageToken)
46336	}
46337}
46338
46339// method id "dfareporting.sites.patch":
46340
46341type SitesPatchCall struct {
46342	s          *Service
46343	profileId  int64
46344	site       *Site
46345	urlParams_ gensupport.URLParams
46346	ctx_       context.Context
46347	header_    http.Header
46348}
46349
46350// Patch: Updates an existing site. This method supports patch
46351// semantics.
46352func (r *SitesService) Patch(profileId int64, id int64, site *Site) *SitesPatchCall {
46353	c := &SitesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46354	c.profileId = profileId
46355	c.urlParams_.Set("id", fmt.Sprint(id))
46356	c.site = site
46357	return c
46358}
46359
46360// Fields allows partial responses to be retrieved. See
46361// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46362// for more information.
46363func (c *SitesPatchCall) Fields(s ...googleapi.Field) *SitesPatchCall {
46364	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46365	return c
46366}
46367
46368// Context sets the context to be used in this call's Do method. Any
46369// pending HTTP request will be aborted if the provided context is
46370// canceled.
46371func (c *SitesPatchCall) Context(ctx context.Context) *SitesPatchCall {
46372	c.ctx_ = ctx
46373	return c
46374}
46375
46376// Header returns an http.Header that can be modified by the caller to
46377// add HTTP headers to the request.
46378func (c *SitesPatchCall) Header() http.Header {
46379	if c.header_ == nil {
46380		c.header_ = make(http.Header)
46381	}
46382	return c.header_
46383}
46384
46385func (c *SitesPatchCall) doRequest(alt string) (*http.Response, error) {
46386	reqHeaders := make(http.Header)
46387	for k, v := range c.header_ {
46388		reqHeaders[k] = v
46389	}
46390	reqHeaders.Set("User-Agent", c.s.userAgent())
46391	var body io.Reader = nil
46392	body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
46393	if err != nil {
46394		return nil, err
46395	}
46396	reqHeaders.Set("Content-Type", "application/json")
46397	c.urlParams_.Set("alt", alt)
46398	c.urlParams_.Set("prettyPrint", "false")
46399	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46400	urls += "?" + c.urlParams_.Encode()
46401	req, err := http.NewRequest("PATCH", urls, body)
46402	if err != nil {
46403		return nil, err
46404	}
46405	req.Header = reqHeaders
46406	googleapi.Expand(req.URL, map[string]string{
46407		"profileId": strconv.FormatInt(c.profileId, 10),
46408	})
46409	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46410}
46411
46412// Do executes the "dfareporting.sites.patch" call.
46413// Exactly one of *Site or error will be non-nil. Any non-2xx status
46414// code is an error. Response headers are in either
46415// *Site.ServerResponse.Header or (if a response was returned at all) in
46416// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46417// whether the returned error was because http.StatusNotModified was
46418// returned.
46419func (c *SitesPatchCall) Do(opts ...googleapi.CallOption) (*Site, error) {
46420	gensupport.SetOptions(c.urlParams_, opts...)
46421	res, err := c.doRequest("json")
46422	if res != nil && res.StatusCode == http.StatusNotModified {
46423		if res.Body != nil {
46424			res.Body.Close()
46425		}
46426		return nil, &googleapi.Error{
46427			Code:   res.StatusCode,
46428			Header: res.Header,
46429		}
46430	}
46431	if err != nil {
46432		return nil, err
46433	}
46434	defer googleapi.CloseBody(res)
46435	if err := googleapi.CheckResponse(res); err != nil {
46436		return nil, err
46437	}
46438	ret := &Site{
46439		ServerResponse: googleapi.ServerResponse{
46440			Header:         res.Header,
46441			HTTPStatusCode: res.StatusCode,
46442		},
46443	}
46444	target := &ret
46445	if err := gensupport.DecodeResponse(target, res); err != nil {
46446		return nil, err
46447	}
46448	return ret, nil
46449	// {
46450	//   "description": "Updates an existing site. This method supports patch semantics.",
46451	//   "httpMethod": "PATCH",
46452	//   "id": "dfareporting.sites.patch",
46453	//   "parameterOrder": [
46454	//     "profileId",
46455	//     "id"
46456	//   ],
46457	//   "parameters": {
46458	//     "id": {
46459	//       "description": "Site ID.",
46460	//       "format": "int64",
46461	//       "location": "query",
46462	//       "required": true,
46463	//       "type": "string"
46464	//     },
46465	//     "profileId": {
46466	//       "description": "User profile ID associated with this request.",
46467	//       "format": "int64",
46468	//       "location": "path",
46469	//       "required": true,
46470	//       "type": "string"
46471	//     }
46472	//   },
46473	//   "path": "userprofiles/{profileId}/sites",
46474	//   "request": {
46475	//     "$ref": "Site"
46476	//   },
46477	//   "response": {
46478	//     "$ref": "Site"
46479	//   },
46480	//   "scopes": [
46481	//     "https://www.googleapis.com/auth/dfatrafficking"
46482	//   ]
46483	// }
46484
46485}
46486
46487// method id "dfareporting.sites.update":
46488
46489type SitesUpdateCall struct {
46490	s          *Service
46491	profileId  int64
46492	site       *Site
46493	urlParams_ gensupport.URLParams
46494	ctx_       context.Context
46495	header_    http.Header
46496}
46497
46498// Update: Updates an existing site.
46499func (r *SitesService) Update(profileId int64, site *Site) *SitesUpdateCall {
46500	c := &SitesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46501	c.profileId = profileId
46502	c.site = site
46503	return c
46504}
46505
46506// Fields allows partial responses to be retrieved. See
46507// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46508// for more information.
46509func (c *SitesUpdateCall) Fields(s ...googleapi.Field) *SitesUpdateCall {
46510	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46511	return c
46512}
46513
46514// Context sets the context to be used in this call's Do method. Any
46515// pending HTTP request will be aborted if the provided context is
46516// canceled.
46517func (c *SitesUpdateCall) Context(ctx context.Context) *SitesUpdateCall {
46518	c.ctx_ = ctx
46519	return c
46520}
46521
46522// Header returns an http.Header that can be modified by the caller to
46523// add HTTP headers to the request.
46524func (c *SitesUpdateCall) Header() http.Header {
46525	if c.header_ == nil {
46526		c.header_ = make(http.Header)
46527	}
46528	return c.header_
46529}
46530
46531func (c *SitesUpdateCall) doRequest(alt string) (*http.Response, error) {
46532	reqHeaders := make(http.Header)
46533	for k, v := range c.header_ {
46534		reqHeaders[k] = v
46535	}
46536	reqHeaders.Set("User-Agent", c.s.userAgent())
46537	var body io.Reader = nil
46538	body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
46539	if err != nil {
46540		return nil, err
46541	}
46542	reqHeaders.Set("Content-Type", "application/json")
46543	c.urlParams_.Set("alt", alt)
46544	c.urlParams_.Set("prettyPrint", "false")
46545	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46546	urls += "?" + c.urlParams_.Encode()
46547	req, err := http.NewRequest("PUT", urls, body)
46548	if err != nil {
46549		return nil, err
46550	}
46551	req.Header = reqHeaders
46552	googleapi.Expand(req.URL, map[string]string{
46553		"profileId": strconv.FormatInt(c.profileId, 10),
46554	})
46555	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46556}
46557
46558// Do executes the "dfareporting.sites.update" call.
46559// Exactly one of *Site or error will be non-nil. Any non-2xx status
46560// code is an error. Response headers are in either
46561// *Site.ServerResponse.Header or (if a response was returned at all) in
46562// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46563// whether the returned error was because http.StatusNotModified was
46564// returned.
46565func (c *SitesUpdateCall) Do(opts ...googleapi.CallOption) (*Site, error) {
46566	gensupport.SetOptions(c.urlParams_, opts...)
46567	res, err := c.doRequest("json")
46568	if res != nil && res.StatusCode == http.StatusNotModified {
46569		if res.Body != nil {
46570			res.Body.Close()
46571		}
46572		return nil, &googleapi.Error{
46573			Code:   res.StatusCode,
46574			Header: res.Header,
46575		}
46576	}
46577	if err != nil {
46578		return nil, err
46579	}
46580	defer googleapi.CloseBody(res)
46581	if err := googleapi.CheckResponse(res); err != nil {
46582		return nil, err
46583	}
46584	ret := &Site{
46585		ServerResponse: googleapi.ServerResponse{
46586			Header:         res.Header,
46587			HTTPStatusCode: res.StatusCode,
46588		},
46589	}
46590	target := &ret
46591	if err := gensupport.DecodeResponse(target, res); err != nil {
46592		return nil, err
46593	}
46594	return ret, nil
46595	// {
46596	//   "description": "Updates an existing site.",
46597	//   "httpMethod": "PUT",
46598	//   "id": "dfareporting.sites.update",
46599	//   "parameterOrder": [
46600	//     "profileId"
46601	//   ],
46602	//   "parameters": {
46603	//     "profileId": {
46604	//       "description": "User profile ID associated with this request.",
46605	//       "format": "int64",
46606	//       "location": "path",
46607	//       "required": true,
46608	//       "type": "string"
46609	//     }
46610	//   },
46611	//   "path": "userprofiles/{profileId}/sites",
46612	//   "request": {
46613	//     "$ref": "Site"
46614	//   },
46615	//   "response": {
46616	//     "$ref": "Site"
46617	//   },
46618	//   "scopes": [
46619	//     "https://www.googleapis.com/auth/dfatrafficking"
46620	//   ]
46621	// }
46622
46623}
46624
46625// method id "dfareporting.sizes.get":
46626
46627type SizesGetCall struct {
46628	s            *Service
46629	profileId    int64
46630	id           int64
46631	urlParams_   gensupport.URLParams
46632	ifNoneMatch_ string
46633	ctx_         context.Context
46634	header_      http.Header
46635}
46636
46637// Get: Gets one size by ID.
46638func (r *SizesService) Get(profileId int64, id int64) *SizesGetCall {
46639	c := &SizesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46640	c.profileId = profileId
46641	c.id = id
46642	return c
46643}
46644
46645// Fields allows partial responses to be retrieved. See
46646// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46647// for more information.
46648func (c *SizesGetCall) Fields(s ...googleapi.Field) *SizesGetCall {
46649	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46650	return c
46651}
46652
46653// IfNoneMatch sets the optional parameter which makes the operation
46654// fail if the object's ETag matches the given value. This is useful for
46655// getting updates only after the object has changed since the last
46656// request. Use googleapi.IsNotModified to check whether the response
46657// error from Do is the result of In-None-Match.
46658func (c *SizesGetCall) IfNoneMatch(entityTag string) *SizesGetCall {
46659	c.ifNoneMatch_ = entityTag
46660	return c
46661}
46662
46663// Context sets the context to be used in this call's Do method. Any
46664// pending HTTP request will be aborted if the provided context is
46665// canceled.
46666func (c *SizesGetCall) Context(ctx context.Context) *SizesGetCall {
46667	c.ctx_ = ctx
46668	return c
46669}
46670
46671// Header returns an http.Header that can be modified by the caller to
46672// add HTTP headers to the request.
46673func (c *SizesGetCall) Header() http.Header {
46674	if c.header_ == nil {
46675		c.header_ = make(http.Header)
46676	}
46677	return c.header_
46678}
46679
46680func (c *SizesGetCall) doRequest(alt string) (*http.Response, error) {
46681	reqHeaders := make(http.Header)
46682	for k, v := range c.header_ {
46683		reqHeaders[k] = v
46684	}
46685	reqHeaders.Set("User-Agent", c.s.userAgent())
46686	if c.ifNoneMatch_ != "" {
46687		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46688	}
46689	var body io.Reader = nil
46690	c.urlParams_.Set("alt", alt)
46691	c.urlParams_.Set("prettyPrint", "false")
46692	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes/{id}")
46693	urls += "?" + c.urlParams_.Encode()
46694	req, err := http.NewRequest("GET", urls, body)
46695	if err != nil {
46696		return nil, err
46697	}
46698	req.Header = reqHeaders
46699	googleapi.Expand(req.URL, map[string]string{
46700		"profileId": strconv.FormatInt(c.profileId, 10),
46701		"id":        strconv.FormatInt(c.id, 10),
46702	})
46703	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46704}
46705
46706// Do executes the "dfareporting.sizes.get" call.
46707// Exactly one of *Size or error will be non-nil. Any non-2xx status
46708// code is an error. Response headers are in either
46709// *Size.ServerResponse.Header or (if a response was returned at all) in
46710// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46711// whether the returned error was because http.StatusNotModified was
46712// returned.
46713func (c *SizesGetCall) Do(opts ...googleapi.CallOption) (*Size, error) {
46714	gensupport.SetOptions(c.urlParams_, opts...)
46715	res, err := c.doRequest("json")
46716	if res != nil && res.StatusCode == http.StatusNotModified {
46717		if res.Body != nil {
46718			res.Body.Close()
46719		}
46720		return nil, &googleapi.Error{
46721			Code:   res.StatusCode,
46722			Header: res.Header,
46723		}
46724	}
46725	if err != nil {
46726		return nil, err
46727	}
46728	defer googleapi.CloseBody(res)
46729	if err := googleapi.CheckResponse(res); err != nil {
46730		return nil, err
46731	}
46732	ret := &Size{
46733		ServerResponse: googleapi.ServerResponse{
46734			Header:         res.Header,
46735			HTTPStatusCode: res.StatusCode,
46736		},
46737	}
46738	target := &ret
46739	if err := gensupport.DecodeResponse(target, res); err != nil {
46740		return nil, err
46741	}
46742	return ret, nil
46743	// {
46744	//   "description": "Gets one size by ID.",
46745	//   "httpMethod": "GET",
46746	//   "id": "dfareporting.sizes.get",
46747	//   "parameterOrder": [
46748	//     "profileId",
46749	//     "id"
46750	//   ],
46751	//   "parameters": {
46752	//     "id": {
46753	//       "description": "Size ID.",
46754	//       "format": "int64",
46755	//       "location": "path",
46756	//       "required": true,
46757	//       "type": "string"
46758	//     },
46759	//     "profileId": {
46760	//       "description": "User profile ID associated with this request.",
46761	//       "format": "int64",
46762	//       "location": "path",
46763	//       "required": true,
46764	//       "type": "string"
46765	//     }
46766	//   },
46767	//   "path": "userprofiles/{profileId}/sizes/{id}",
46768	//   "response": {
46769	//     "$ref": "Size"
46770	//   },
46771	//   "scopes": [
46772	//     "https://www.googleapis.com/auth/dfatrafficking"
46773	//   ]
46774	// }
46775
46776}
46777
46778// method id "dfareporting.sizes.insert":
46779
46780type SizesInsertCall struct {
46781	s          *Service
46782	profileId  int64
46783	size       *Size
46784	urlParams_ gensupport.URLParams
46785	ctx_       context.Context
46786	header_    http.Header
46787}
46788
46789// Insert: Inserts a new size.
46790func (r *SizesService) Insert(profileId int64, size *Size) *SizesInsertCall {
46791	c := &SizesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46792	c.profileId = profileId
46793	c.size = size
46794	return c
46795}
46796
46797// Fields allows partial responses to be retrieved. See
46798// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46799// for more information.
46800func (c *SizesInsertCall) Fields(s ...googleapi.Field) *SizesInsertCall {
46801	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46802	return c
46803}
46804
46805// Context sets the context to be used in this call's Do method. Any
46806// pending HTTP request will be aborted if the provided context is
46807// canceled.
46808func (c *SizesInsertCall) Context(ctx context.Context) *SizesInsertCall {
46809	c.ctx_ = ctx
46810	return c
46811}
46812
46813// Header returns an http.Header that can be modified by the caller to
46814// add HTTP headers to the request.
46815func (c *SizesInsertCall) Header() http.Header {
46816	if c.header_ == nil {
46817		c.header_ = make(http.Header)
46818	}
46819	return c.header_
46820}
46821
46822func (c *SizesInsertCall) doRequest(alt string) (*http.Response, error) {
46823	reqHeaders := make(http.Header)
46824	for k, v := range c.header_ {
46825		reqHeaders[k] = v
46826	}
46827	reqHeaders.Set("User-Agent", c.s.userAgent())
46828	var body io.Reader = nil
46829	body, err := googleapi.WithoutDataWrapper.JSONReader(c.size)
46830	if err != nil {
46831		return nil, err
46832	}
46833	reqHeaders.Set("Content-Type", "application/json")
46834	c.urlParams_.Set("alt", alt)
46835	c.urlParams_.Set("prettyPrint", "false")
46836	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes")
46837	urls += "?" + c.urlParams_.Encode()
46838	req, err := http.NewRequest("POST", urls, body)
46839	if err != nil {
46840		return nil, err
46841	}
46842	req.Header = reqHeaders
46843	googleapi.Expand(req.URL, map[string]string{
46844		"profileId": strconv.FormatInt(c.profileId, 10),
46845	})
46846	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46847}
46848
46849// Do executes the "dfareporting.sizes.insert" call.
46850// Exactly one of *Size or error will be non-nil. Any non-2xx status
46851// code is an error. Response headers are in either
46852// *Size.ServerResponse.Header or (if a response was returned at all) in
46853// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46854// whether the returned error was because http.StatusNotModified was
46855// returned.
46856func (c *SizesInsertCall) Do(opts ...googleapi.CallOption) (*Size, error) {
46857	gensupport.SetOptions(c.urlParams_, opts...)
46858	res, err := c.doRequest("json")
46859	if res != nil && res.StatusCode == http.StatusNotModified {
46860		if res.Body != nil {
46861			res.Body.Close()
46862		}
46863		return nil, &googleapi.Error{
46864			Code:   res.StatusCode,
46865			Header: res.Header,
46866		}
46867	}
46868	if err != nil {
46869		return nil, err
46870	}
46871	defer googleapi.CloseBody(res)
46872	if err := googleapi.CheckResponse(res); err != nil {
46873		return nil, err
46874	}
46875	ret := &Size{
46876		ServerResponse: googleapi.ServerResponse{
46877			Header:         res.Header,
46878			HTTPStatusCode: res.StatusCode,
46879		},
46880	}
46881	target := &ret
46882	if err := gensupport.DecodeResponse(target, res); err != nil {
46883		return nil, err
46884	}
46885	return ret, nil
46886	// {
46887	//   "description": "Inserts a new size.",
46888	//   "httpMethod": "POST",
46889	//   "id": "dfareporting.sizes.insert",
46890	//   "parameterOrder": [
46891	//     "profileId"
46892	//   ],
46893	//   "parameters": {
46894	//     "profileId": {
46895	//       "description": "User profile ID associated with this request.",
46896	//       "format": "int64",
46897	//       "location": "path",
46898	//       "required": true,
46899	//       "type": "string"
46900	//     }
46901	//   },
46902	//   "path": "userprofiles/{profileId}/sizes",
46903	//   "request": {
46904	//     "$ref": "Size"
46905	//   },
46906	//   "response": {
46907	//     "$ref": "Size"
46908	//   },
46909	//   "scopes": [
46910	//     "https://www.googleapis.com/auth/dfatrafficking"
46911	//   ]
46912	// }
46913
46914}
46915
46916// method id "dfareporting.sizes.list":
46917
46918type SizesListCall struct {
46919	s            *Service
46920	profileId    int64
46921	urlParams_   gensupport.URLParams
46922	ifNoneMatch_ string
46923	ctx_         context.Context
46924	header_      http.Header
46925}
46926
46927// List: Retrieves a list of sizes, possibly filtered. Retrieved sizes
46928// are globally unique and may include values not currently in use by
46929// your account. Due to this, the list of sizes returned by this method
46930// may differ from the list seen in the Trafficking UI.
46931func (r *SizesService) List(profileId int64) *SizesListCall {
46932	c := &SizesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46933	c.profileId = profileId
46934	return c
46935}
46936
46937// Height sets the optional parameter "height": Select only sizes with
46938// this height.
46939func (c *SizesListCall) Height(height int64) *SizesListCall {
46940	c.urlParams_.Set("height", fmt.Sprint(height))
46941	return c
46942}
46943
46944// IabStandard sets the optional parameter "iabStandard": Select only
46945// IAB standard sizes.
46946func (c *SizesListCall) IabStandard(iabStandard bool) *SizesListCall {
46947	c.urlParams_.Set("iabStandard", fmt.Sprint(iabStandard))
46948	return c
46949}
46950
46951// Ids sets the optional parameter "ids": Select only sizes with these
46952// IDs.
46953func (c *SizesListCall) Ids(ids ...int64) *SizesListCall {
46954	var ids_ []string
46955	for _, v := range ids {
46956		ids_ = append(ids_, fmt.Sprint(v))
46957	}
46958	c.urlParams_.SetMulti("ids", ids_)
46959	return c
46960}
46961
46962// Width sets the optional parameter "width": Select only sizes with
46963// this width.
46964func (c *SizesListCall) Width(width int64) *SizesListCall {
46965	c.urlParams_.Set("width", fmt.Sprint(width))
46966	return c
46967}
46968
46969// Fields allows partial responses to be retrieved. See
46970// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46971// for more information.
46972func (c *SizesListCall) Fields(s ...googleapi.Field) *SizesListCall {
46973	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46974	return c
46975}
46976
46977// IfNoneMatch sets the optional parameter which makes the operation
46978// fail if the object's ETag matches the given value. This is useful for
46979// getting updates only after the object has changed since the last
46980// request. Use googleapi.IsNotModified to check whether the response
46981// error from Do is the result of In-None-Match.
46982func (c *SizesListCall) IfNoneMatch(entityTag string) *SizesListCall {
46983	c.ifNoneMatch_ = entityTag
46984	return c
46985}
46986
46987// Context sets the context to be used in this call's Do method. Any
46988// pending HTTP request will be aborted if the provided context is
46989// canceled.
46990func (c *SizesListCall) Context(ctx context.Context) *SizesListCall {
46991	c.ctx_ = ctx
46992	return c
46993}
46994
46995// Header returns an http.Header that can be modified by the caller to
46996// add HTTP headers to the request.
46997func (c *SizesListCall) Header() http.Header {
46998	if c.header_ == nil {
46999		c.header_ = make(http.Header)
47000	}
47001	return c.header_
47002}
47003
47004func (c *SizesListCall) doRequest(alt string) (*http.Response, error) {
47005	reqHeaders := make(http.Header)
47006	for k, v := range c.header_ {
47007		reqHeaders[k] = v
47008	}
47009	reqHeaders.Set("User-Agent", c.s.userAgent())
47010	if c.ifNoneMatch_ != "" {
47011		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47012	}
47013	var body io.Reader = nil
47014	c.urlParams_.Set("alt", alt)
47015	c.urlParams_.Set("prettyPrint", "false")
47016	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes")
47017	urls += "?" + c.urlParams_.Encode()
47018	req, err := http.NewRequest("GET", urls, body)
47019	if err != nil {
47020		return nil, err
47021	}
47022	req.Header = reqHeaders
47023	googleapi.Expand(req.URL, map[string]string{
47024		"profileId": strconv.FormatInt(c.profileId, 10),
47025	})
47026	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47027}
47028
47029// Do executes the "dfareporting.sizes.list" call.
47030// Exactly one of *SizesListResponse or error will be non-nil. Any
47031// non-2xx status code is an error. Response headers are in either
47032// *SizesListResponse.ServerResponse.Header or (if a response was
47033// returned at all) in error.(*googleapi.Error).Header. Use
47034// googleapi.IsNotModified to check whether the returned error was
47035// because http.StatusNotModified was returned.
47036func (c *SizesListCall) Do(opts ...googleapi.CallOption) (*SizesListResponse, error) {
47037	gensupport.SetOptions(c.urlParams_, opts...)
47038	res, err := c.doRequest("json")
47039	if res != nil && res.StatusCode == http.StatusNotModified {
47040		if res.Body != nil {
47041			res.Body.Close()
47042		}
47043		return nil, &googleapi.Error{
47044			Code:   res.StatusCode,
47045			Header: res.Header,
47046		}
47047	}
47048	if err != nil {
47049		return nil, err
47050	}
47051	defer googleapi.CloseBody(res)
47052	if err := googleapi.CheckResponse(res); err != nil {
47053		return nil, err
47054	}
47055	ret := &SizesListResponse{
47056		ServerResponse: googleapi.ServerResponse{
47057			Header:         res.Header,
47058			HTTPStatusCode: res.StatusCode,
47059		},
47060	}
47061	target := &ret
47062	if err := gensupport.DecodeResponse(target, res); err != nil {
47063		return nil, err
47064	}
47065	return ret, nil
47066	// {
47067	//   "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.",
47068	//   "httpMethod": "GET",
47069	//   "id": "dfareporting.sizes.list",
47070	//   "parameterOrder": [
47071	//     "profileId"
47072	//   ],
47073	//   "parameters": {
47074	//     "height": {
47075	//       "description": "Select only sizes with this height.",
47076	//       "format": "int32",
47077	//       "location": "query",
47078	//       "maximum": "32767",
47079	//       "minimum": "0",
47080	//       "type": "integer"
47081	//     },
47082	//     "iabStandard": {
47083	//       "description": "Select only IAB standard sizes.",
47084	//       "location": "query",
47085	//       "type": "boolean"
47086	//     },
47087	//     "ids": {
47088	//       "description": "Select only sizes with these IDs.",
47089	//       "format": "int64",
47090	//       "location": "query",
47091	//       "repeated": true,
47092	//       "type": "string"
47093	//     },
47094	//     "profileId": {
47095	//       "description": "User profile ID associated with this request.",
47096	//       "format": "int64",
47097	//       "location": "path",
47098	//       "required": true,
47099	//       "type": "string"
47100	//     },
47101	//     "width": {
47102	//       "description": "Select only sizes with this width.",
47103	//       "format": "int32",
47104	//       "location": "query",
47105	//       "maximum": "32767",
47106	//       "minimum": "0",
47107	//       "type": "integer"
47108	//     }
47109	//   },
47110	//   "path": "userprofiles/{profileId}/sizes",
47111	//   "response": {
47112	//     "$ref": "SizesListResponse"
47113	//   },
47114	//   "scopes": [
47115	//     "https://www.googleapis.com/auth/dfatrafficking"
47116	//   ]
47117	// }
47118
47119}
47120
47121// method id "dfareporting.subaccounts.get":
47122
47123type SubaccountsGetCall struct {
47124	s            *Service
47125	profileId    int64
47126	id           int64
47127	urlParams_   gensupport.URLParams
47128	ifNoneMatch_ string
47129	ctx_         context.Context
47130	header_      http.Header
47131}
47132
47133// Get: Gets one subaccount by ID.
47134func (r *SubaccountsService) Get(profileId int64, id int64) *SubaccountsGetCall {
47135	c := &SubaccountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47136	c.profileId = profileId
47137	c.id = id
47138	return c
47139}
47140
47141// Fields allows partial responses to be retrieved. See
47142// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47143// for more information.
47144func (c *SubaccountsGetCall) Fields(s ...googleapi.Field) *SubaccountsGetCall {
47145	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47146	return c
47147}
47148
47149// IfNoneMatch sets the optional parameter which makes the operation
47150// fail if the object's ETag matches the given value. This is useful for
47151// getting updates only after the object has changed since the last
47152// request. Use googleapi.IsNotModified to check whether the response
47153// error from Do is the result of In-None-Match.
47154func (c *SubaccountsGetCall) IfNoneMatch(entityTag string) *SubaccountsGetCall {
47155	c.ifNoneMatch_ = entityTag
47156	return c
47157}
47158
47159// Context sets the context to be used in this call's Do method. Any
47160// pending HTTP request will be aborted if the provided context is
47161// canceled.
47162func (c *SubaccountsGetCall) Context(ctx context.Context) *SubaccountsGetCall {
47163	c.ctx_ = ctx
47164	return c
47165}
47166
47167// Header returns an http.Header that can be modified by the caller to
47168// add HTTP headers to the request.
47169func (c *SubaccountsGetCall) Header() http.Header {
47170	if c.header_ == nil {
47171		c.header_ = make(http.Header)
47172	}
47173	return c.header_
47174}
47175
47176func (c *SubaccountsGetCall) doRequest(alt string) (*http.Response, error) {
47177	reqHeaders := make(http.Header)
47178	for k, v := range c.header_ {
47179		reqHeaders[k] = v
47180	}
47181	reqHeaders.Set("User-Agent", c.s.userAgent())
47182	if c.ifNoneMatch_ != "" {
47183		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47184	}
47185	var body io.Reader = nil
47186	c.urlParams_.Set("alt", alt)
47187	c.urlParams_.Set("prettyPrint", "false")
47188	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts/{id}")
47189	urls += "?" + c.urlParams_.Encode()
47190	req, err := http.NewRequest("GET", urls, body)
47191	if err != nil {
47192		return nil, err
47193	}
47194	req.Header = reqHeaders
47195	googleapi.Expand(req.URL, map[string]string{
47196		"profileId": strconv.FormatInt(c.profileId, 10),
47197		"id":        strconv.FormatInt(c.id, 10),
47198	})
47199	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47200}
47201
47202// Do executes the "dfareporting.subaccounts.get" call.
47203// Exactly one of *Subaccount or error will be non-nil. Any non-2xx
47204// status code is an error. Response headers are in either
47205// *Subaccount.ServerResponse.Header or (if a response was returned at
47206// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
47207// to check whether the returned error was because
47208// http.StatusNotModified was returned.
47209func (c *SubaccountsGetCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47210	gensupport.SetOptions(c.urlParams_, opts...)
47211	res, err := c.doRequest("json")
47212	if res != nil && res.StatusCode == http.StatusNotModified {
47213		if res.Body != nil {
47214			res.Body.Close()
47215		}
47216		return nil, &googleapi.Error{
47217			Code:   res.StatusCode,
47218			Header: res.Header,
47219		}
47220	}
47221	if err != nil {
47222		return nil, err
47223	}
47224	defer googleapi.CloseBody(res)
47225	if err := googleapi.CheckResponse(res); err != nil {
47226		return nil, err
47227	}
47228	ret := &Subaccount{
47229		ServerResponse: googleapi.ServerResponse{
47230			Header:         res.Header,
47231			HTTPStatusCode: res.StatusCode,
47232		},
47233	}
47234	target := &ret
47235	if err := gensupport.DecodeResponse(target, res); err != nil {
47236		return nil, err
47237	}
47238	return ret, nil
47239	// {
47240	//   "description": "Gets one subaccount by ID.",
47241	//   "httpMethod": "GET",
47242	//   "id": "dfareporting.subaccounts.get",
47243	//   "parameterOrder": [
47244	//     "profileId",
47245	//     "id"
47246	//   ],
47247	//   "parameters": {
47248	//     "id": {
47249	//       "description": "Subaccount ID.",
47250	//       "format": "int64",
47251	//       "location": "path",
47252	//       "required": true,
47253	//       "type": "string"
47254	//     },
47255	//     "profileId": {
47256	//       "description": "User profile ID associated with this request.",
47257	//       "format": "int64",
47258	//       "location": "path",
47259	//       "required": true,
47260	//       "type": "string"
47261	//     }
47262	//   },
47263	//   "path": "userprofiles/{profileId}/subaccounts/{id}",
47264	//   "response": {
47265	//     "$ref": "Subaccount"
47266	//   },
47267	//   "scopes": [
47268	//     "https://www.googleapis.com/auth/dfatrafficking"
47269	//   ]
47270	// }
47271
47272}
47273
47274// method id "dfareporting.subaccounts.insert":
47275
47276type SubaccountsInsertCall struct {
47277	s          *Service
47278	profileId  int64
47279	subaccount *Subaccount
47280	urlParams_ gensupport.URLParams
47281	ctx_       context.Context
47282	header_    http.Header
47283}
47284
47285// Insert: Inserts a new subaccount.
47286func (r *SubaccountsService) Insert(profileId int64, subaccount *Subaccount) *SubaccountsInsertCall {
47287	c := &SubaccountsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47288	c.profileId = profileId
47289	c.subaccount = subaccount
47290	return c
47291}
47292
47293// Fields allows partial responses to be retrieved. See
47294// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47295// for more information.
47296func (c *SubaccountsInsertCall) Fields(s ...googleapi.Field) *SubaccountsInsertCall {
47297	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47298	return c
47299}
47300
47301// Context sets the context to be used in this call's Do method. Any
47302// pending HTTP request will be aborted if the provided context is
47303// canceled.
47304func (c *SubaccountsInsertCall) Context(ctx context.Context) *SubaccountsInsertCall {
47305	c.ctx_ = ctx
47306	return c
47307}
47308
47309// Header returns an http.Header that can be modified by the caller to
47310// add HTTP headers to the request.
47311func (c *SubaccountsInsertCall) Header() http.Header {
47312	if c.header_ == nil {
47313		c.header_ = make(http.Header)
47314	}
47315	return c.header_
47316}
47317
47318func (c *SubaccountsInsertCall) doRequest(alt string) (*http.Response, error) {
47319	reqHeaders := make(http.Header)
47320	for k, v := range c.header_ {
47321		reqHeaders[k] = v
47322	}
47323	reqHeaders.Set("User-Agent", c.s.userAgent())
47324	var body io.Reader = nil
47325	body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
47326	if err != nil {
47327		return nil, err
47328	}
47329	reqHeaders.Set("Content-Type", "application/json")
47330	c.urlParams_.Set("alt", alt)
47331	c.urlParams_.Set("prettyPrint", "false")
47332	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47333	urls += "?" + c.urlParams_.Encode()
47334	req, err := http.NewRequest("POST", urls, body)
47335	if err != nil {
47336		return nil, err
47337	}
47338	req.Header = reqHeaders
47339	googleapi.Expand(req.URL, map[string]string{
47340		"profileId": strconv.FormatInt(c.profileId, 10),
47341	})
47342	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47343}
47344
47345// Do executes the "dfareporting.subaccounts.insert" call.
47346// Exactly one of *Subaccount or error will be non-nil. Any non-2xx
47347// status code is an error. Response headers are in either
47348// *Subaccount.ServerResponse.Header or (if a response was returned at
47349// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
47350// to check whether the returned error was because
47351// http.StatusNotModified was returned.
47352func (c *SubaccountsInsertCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47353	gensupport.SetOptions(c.urlParams_, opts...)
47354	res, err := c.doRequest("json")
47355	if res != nil && res.StatusCode == http.StatusNotModified {
47356		if res.Body != nil {
47357			res.Body.Close()
47358		}
47359		return nil, &googleapi.Error{
47360			Code:   res.StatusCode,
47361			Header: res.Header,
47362		}
47363	}
47364	if err != nil {
47365		return nil, err
47366	}
47367	defer googleapi.CloseBody(res)
47368	if err := googleapi.CheckResponse(res); err != nil {
47369		return nil, err
47370	}
47371	ret := &Subaccount{
47372		ServerResponse: googleapi.ServerResponse{
47373			Header:         res.Header,
47374			HTTPStatusCode: res.StatusCode,
47375		},
47376	}
47377	target := &ret
47378	if err := gensupport.DecodeResponse(target, res); err != nil {
47379		return nil, err
47380	}
47381	return ret, nil
47382	// {
47383	//   "description": "Inserts a new subaccount.",
47384	//   "httpMethod": "POST",
47385	//   "id": "dfareporting.subaccounts.insert",
47386	//   "parameterOrder": [
47387	//     "profileId"
47388	//   ],
47389	//   "parameters": {
47390	//     "profileId": {
47391	//       "description": "User profile ID associated with this request.",
47392	//       "format": "int64",
47393	//       "location": "path",
47394	//       "required": true,
47395	//       "type": "string"
47396	//     }
47397	//   },
47398	//   "path": "userprofiles/{profileId}/subaccounts",
47399	//   "request": {
47400	//     "$ref": "Subaccount"
47401	//   },
47402	//   "response": {
47403	//     "$ref": "Subaccount"
47404	//   },
47405	//   "scopes": [
47406	//     "https://www.googleapis.com/auth/dfatrafficking"
47407	//   ]
47408	// }
47409
47410}
47411
47412// method id "dfareporting.subaccounts.list":
47413
47414type SubaccountsListCall struct {
47415	s            *Service
47416	profileId    int64
47417	urlParams_   gensupport.URLParams
47418	ifNoneMatch_ string
47419	ctx_         context.Context
47420	header_      http.Header
47421}
47422
47423// List: Gets a list of subaccounts, possibly filtered. This method
47424// supports paging.
47425func (r *SubaccountsService) List(profileId int64) *SubaccountsListCall {
47426	c := &SubaccountsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47427	c.profileId = profileId
47428	return c
47429}
47430
47431// Ids sets the optional parameter "ids": Select only subaccounts with
47432// these IDs.
47433func (c *SubaccountsListCall) Ids(ids ...int64) *SubaccountsListCall {
47434	var ids_ []string
47435	for _, v := range ids {
47436		ids_ = append(ids_, fmt.Sprint(v))
47437	}
47438	c.urlParams_.SetMulti("ids", ids_)
47439	return c
47440}
47441
47442// MaxResults sets the optional parameter "maxResults": Maximum number
47443// of results to return.
47444func (c *SubaccountsListCall) MaxResults(maxResults int64) *SubaccountsListCall {
47445	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
47446	return c
47447}
47448
47449// PageToken sets the optional parameter "pageToken": Value of the
47450// nextPageToken from the previous result page.
47451func (c *SubaccountsListCall) PageToken(pageToken string) *SubaccountsListCall {
47452	c.urlParams_.Set("pageToken", pageToken)
47453	return c
47454}
47455
47456// SearchString sets the optional parameter "searchString": Allows
47457// searching for objects by name or ID. Wildcards (*) are allowed. For
47458// example, "subaccount*2015" will return objects with names like
47459// "subaccount June 2015", "subaccount April 2015", or simply
47460// "subaccount 2015". Most of the searches also add wildcards implicitly
47461// at the start and the end of the search string. For example, a search
47462// string of "subaccount" will match objects with name "my subaccount",
47463// "subaccount 2015", or simply "subaccount".
47464func (c *SubaccountsListCall) SearchString(searchString string) *SubaccountsListCall {
47465	c.urlParams_.Set("searchString", searchString)
47466	return c
47467}
47468
47469// SortField sets the optional parameter "sortField": Field by which to
47470// sort the list.
47471//
47472// Possible values:
47473//   "ID" (default)
47474//   "NAME"
47475func (c *SubaccountsListCall) SortField(sortField string) *SubaccountsListCall {
47476	c.urlParams_.Set("sortField", sortField)
47477	return c
47478}
47479
47480// SortOrder sets the optional parameter "sortOrder": Order of sorted
47481// results.
47482//
47483// Possible values:
47484//   "ASCENDING" (default)
47485//   "DESCENDING"
47486func (c *SubaccountsListCall) SortOrder(sortOrder string) *SubaccountsListCall {
47487	c.urlParams_.Set("sortOrder", sortOrder)
47488	return c
47489}
47490
47491// Fields allows partial responses to be retrieved. See
47492// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47493// for more information.
47494func (c *SubaccountsListCall) Fields(s ...googleapi.Field) *SubaccountsListCall {
47495	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47496	return c
47497}
47498
47499// IfNoneMatch sets the optional parameter which makes the operation
47500// fail if the object's ETag matches the given value. This is useful for
47501// getting updates only after the object has changed since the last
47502// request. Use googleapi.IsNotModified to check whether the response
47503// error from Do is the result of In-None-Match.
47504func (c *SubaccountsListCall) IfNoneMatch(entityTag string) *SubaccountsListCall {
47505	c.ifNoneMatch_ = entityTag
47506	return c
47507}
47508
47509// Context sets the context to be used in this call's Do method. Any
47510// pending HTTP request will be aborted if the provided context is
47511// canceled.
47512func (c *SubaccountsListCall) Context(ctx context.Context) *SubaccountsListCall {
47513	c.ctx_ = ctx
47514	return c
47515}
47516
47517// Header returns an http.Header that can be modified by the caller to
47518// add HTTP headers to the request.
47519func (c *SubaccountsListCall) Header() http.Header {
47520	if c.header_ == nil {
47521		c.header_ = make(http.Header)
47522	}
47523	return c.header_
47524}
47525
47526func (c *SubaccountsListCall) doRequest(alt string) (*http.Response, error) {
47527	reqHeaders := make(http.Header)
47528	for k, v := range c.header_ {
47529		reqHeaders[k] = v
47530	}
47531	reqHeaders.Set("User-Agent", c.s.userAgent())
47532	if c.ifNoneMatch_ != "" {
47533		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47534	}
47535	var body io.Reader = nil
47536	c.urlParams_.Set("alt", alt)
47537	c.urlParams_.Set("prettyPrint", "false")
47538	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47539	urls += "?" + c.urlParams_.Encode()
47540	req, err := http.NewRequest("GET", urls, body)
47541	if err != nil {
47542		return nil, err
47543	}
47544	req.Header = reqHeaders
47545	googleapi.Expand(req.URL, map[string]string{
47546		"profileId": strconv.FormatInt(c.profileId, 10),
47547	})
47548	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47549}
47550
47551// Do executes the "dfareporting.subaccounts.list" call.
47552// Exactly one of *SubaccountsListResponse or error will be non-nil. Any
47553// non-2xx status code is an error. Response headers are in either
47554// *SubaccountsListResponse.ServerResponse.Header or (if a response was
47555// returned at all) in error.(*googleapi.Error).Header. Use
47556// googleapi.IsNotModified to check whether the returned error was
47557// because http.StatusNotModified was returned.
47558func (c *SubaccountsListCall) Do(opts ...googleapi.CallOption) (*SubaccountsListResponse, error) {
47559	gensupport.SetOptions(c.urlParams_, opts...)
47560	res, err := c.doRequest("json")
47561	if res != nil && res.StatusCode == http.StatusNotModified {
47562		if res.Body != nil {
47563			res.Body.Close()
47564		}
47565		return nil, &googleapi.Error{
47566			Code:   res.StatusCode,
47567			Header: res.Header,
47568		}
47569	}
47570	if err != nil {
47571		return nil, err
47572	}
47573	defer googleapi.CloseBody(res)
47574	if err := googleapi.CheckResponse(res); err != nil {
47575		return nil, err
47576	}
47577	ret := &SubaccountsListResponse{
47578		ServerResponse: googleapi.ServerResponse{
47579			Header:         res.Header,
47580			HTTPStatusCode: res.StatusCode,
47581		},
47582	}
47583	target := &ret
47584	if err := gensupport.DecodeResponse(target, res); err != nil {
47585		return nil, err
47586	}
47587	return ret, nil
47588	// {
47589	//   "description": "Gets a list of subaccounts, possibly filtered. This method supports paging.",
47590	//   "httpMethod": "GET",
47591	//   "id": "dfareporting.subaccounts.list",
47592	//   "parameterOrder": [
47593	//     "profileId"
47594	//   ],
47595	//   "parameters": {
47596	//     "ids": {
47597	//       "description": "Select only subaccounts with these IDs.",
47598	//       "format": "int64",
47599	//       "location": "query",
47600	//       "repeated": true,
47601	//       "type": "string"
47602	//     },
47603	//     "maxResults": {
47604	//       "default": "1000",
47605	//       "description": "Maximum number of results to return.",
47606	//       "format": "int32",
47607	//       "location": "query",
47608	//       "maximum": "1000",
47609	//       "minimum": "0",
47610	//       "type": "integer"
47611	//     },
47612	//     "pageToken": {
47613	//       "description": "Value of the nextPageToken from the previous result page.",
47614	//       "location": "query",
47615	//       "type": "string"
47616	//     },
47617	//     "profileId": {
47618	//       "description": "User profile ID associated with this request.",
47619	//       "format": "int64",
47620	//       "location": "path",
47621	//       "required": true,
47622	//       "type": "string"
47623	//     },
47624	//     "searchString": {
47625	//       "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\".",
47626	//       "location": "query",
47627	//       "type": "string"
47628	//     },
47629	//     "sortField": {
47630	//       "default": "ID",
47631	//       "description": "Field by which to sort the list.",
47632	//       "enum": [
47633	//         "ID",
47634	//         "NAME"
47635	//       ],
47636	//       "enumDescriptions": [
47637	//         "",
47638	//         ""
47639	//       ],
47640	//       "location": "query",
47641	//       "type": "string"
47642	//     },
47643	//     "sortOrder": {
47644	//       "default": "ASCENDING",
47645	//       "description": "Order of sorted results.",
47646	//       "enum": [
47647	//         "ASCENDING",
47648	//         "DESCENDING"
47649	//       ],
47650	//       "enumDescriptions": [
47651	//         "",
47652	//         ""
47653	//       ],
47654	//       "location": "query",
47655	//       "type": "string"
47656	//     }
47657	//   },
47658	//   "path": "userprofiles/{profileId}/subaccounts",
47659	//   "response": {
47660	//     "$ref": "SubaccountsListResponse"
47661	//   },
47662	//   "scopes": [
47663	//     "https://www.googleapis.com/auth/dfatrafficking"
47664	//   ]
47665	// }
47666
47667}
47668
47669// Pages invokes f for each page of results.
47670// A non-nil error returned from f will halt the iteration.
47671// The provided context supersedes any context provided to the Context method.
47672func (c *SubaccountsListCall) Pages(ctx context.Context, f func(*SubaccountsListResponse) error) error {
47673	c.ctx_ = ctx
47674	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
47675	for {
47676		x, err := c.Do()
47677		if err != nil {
47678			return err
47679		}
47680		if err := f(x); err != nil {
47681			return err
47682		}
47683		if x.NextPageToken == "" {
47684			return nil
47685		}
47686		c.PageToken(x.NextPageToken)
47687	}
47688}
47689
47690// method id "dfareporting.subaccounts.patch":
47691
47692type SubaccountsPatchCall struct {
47693	s          *Service
47694	profileId  int64
47695	subaccount *Subaccount
47696	urlParams_ gensupport.URLParams
47697	ctx_       context.Context
47698	header_    http.Header
47699}
47700
47701// Patch: Updates an existing subaccount. This method supports patch
47702// semantics.
47703func (r *SubaccountsService) Patch(profileId int64, id int64, subaccount *Subaccount) *SubaccountsPatchCall {
47704	c := &SubaccountsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47705	c.profileId = profileId
47706	c.urlParams_.Set("id", fmt.Sprint(id))
47707	c.subaccount = subaccount
47708	return c
47709}
47710
47711// Fields allows partial responses to be retrieved. See
47712// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47713// for more information.
47714func (c *SubaccountsPatchCall) Fields(s ...googleapi.Field) *SubaccountsPatchCall {
47715	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47716	return c
47717}
47718
47719// Context sets the context to be used in this call's Do method. Any
47720// pending HTTP request will be aborted if the provided context is
47721// canceled.
47722func (c *SubaccountsPatchCall) Context(ctx context.Context) *SubaccountsPatchCall {
47723	c.ctx_ = ctx
47724	return c
47725}
47726
47727// Header returns an http.Header that can be modified by the caller to
47728// add HTTP headers to the request.
47729func (c *SubaccountsPatchCall) Header() http.Header {
47730	if c.header_ == nil {
47731		c.header_ = make(http.Header)
47732	}
47733	return c.header_
47734}
47735
47736func (c *SubaccountsPatchCall) doRequest(alt string) (*http.Response, error) {
47737	reqHeaders := make(http.Header)
47738	for k, v := range c.header_ {
47739		reqHeaders[k] = v
47740	}
47741	reqHeaders.Set("User-Agent", c.s.userAgent())
47742	var body io.Reader = nil
47743	body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
47744	if err != nil {
47745		return nil, err
47746	}
47747	reqHeaders.Set("Content-Type", "application/json")
47748	c.urlParams_.Set("alt", alt)
47749	c.urlParams_.Set("prettyPrint", "false")
47750	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47751	urls += "?" + c.urlParams_.Encode()
47752	req, err := http.NewRequest("PATCH", urls, body)
47753	if err != nil {
47754		return nil, err
47755	}
47756	req.Header = reqHeaders
47757	googleapi.Expand(req.URL, map[string]string{
47758		"profileId": strconv.FormatInt(c.profileId, 10),
47759	})
47760	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47761}
47762
47763// Do executes the "dfareporting.subaccounts.patch" call.
47764// Exactly one of *Subaccount or error will be non-nil. Any non-2xx
47765// status code is an error. Response headers are in either
47766// *Subaccount.ServerResponse.Header or (if a response was returned at
47767// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
47768// to check whether the returned error was because
47769// http.StatusNotModified was returned.
47770func (c *SubaccountsPatchCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47771	gensupport.SetOptions(c.urlParams_, opts...)
47772	res, err := c.doRequest("json")
47773	if res != nil && res.StatusCode == http.StatusNotModified {
47774		if res.Body != nil {
47775			res.Body.Close()
47776		}
47777		return nil, &googleapi.Error{
47778			Code:   res.StatusCode,
47779			Header: res.Header,
47780		}
47781	}
47782	if err != nil {
47783		return nil, err
47784	}
47785	defer googleapi.CloseBody(res)
47786	if err := googleapi.CheckResponse(res); err != nil {
47787		return nil, err
47788	}
47789	ret := &Subaccount{
47790		ServerResponse: googleapi.ServerResponse{
47791			Header:         res.Header,
47792			HTTPStatusCode: res.StatusCode,
47793		},
47794	}
47795	target := &ret
47796	if err := gensupport.DecodeResponse(target, res); err != nil {
47797		return nil, err
47798	}
47799	return ret, nil
47800	// {
47801	//   "description": "Updates an existing subaccount. This method supports patch semantics.",
47802	//   "httpMethod": "PATCH",
47803	//   "id": "dfareporting.subaccounts.patch",
47804	//   "parameterOrder": [
47805	//     "profileId",
47806	//     "id"
47807	//   ],
47808	//   "parameters": {
47809	//     "id": {
47810	//       "description": "Subaccount ID.",
47811	//       "format": "int64",
47812	//       "location": "query",
47813	//       "required": true,
47814	//       "type": "string"
47815	//     },
47816	//     "profileId": {
47817	//       "description": "User profile ID associated with this request.",
47818	//       "format": "int64",
47819	//       "location": "path",
47820	//       "required": true,
47821	//       "type": "string"
47822	//     }
47823	//   },
47824	//   "path": "userprofiles/{profileId}/subaccounts",
47825	//   "request": {
47826	//     "$ref": "Subaccount"
47827	//   },
47828	//   "response": {
47829	//     "$ref": "Subaccount"
47830	//   },
47831	//   "scopes": [
47832	//     "https://www.googleapis.com/auth/dfatrafficking"
47833	//   ]
47834	// }
47835
47836}
47837
47838// method id "dfareporting.subaccounts.update":
47839
47840type SubaccountsUpdateCall struct {
47841	s          *Service
47842	profileId  int64
47843	subaccount *Subaccount
47844	urlParams_ gensupport.URLParams
47845	ctx_       context.Context
47846	header_    http.Header
47847}
47848
47849// Update: Updates an existing subaccount.
47850func (r *SubaccountsService) Update(profileId int64, subaccount *Subaccount) *SubaccountsUpdateCall {
47851	c := &SubaccountsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47852	c.profileId = profileId
47853	c.subaccount = subaccount
47854	return c
47855}
47856
47857// Fields allows partial responses to be retrieved. See
47858// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47859// for more information.
47860func (c *SubaccountsUpdateCall) Fields(s ...googleapi.Field) *SubaccountsUpdateCall {
47861	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47862	return c
47863}
47864
47865// Context sets the context to be used in this call's Do method. Any
47866// pending HTTP request will be aborted if the provided context is
47867// canceled.
47868func (c *SubaccountsUpdateCall) Context(ctx context.Context) *SubaccountsUpdateCall {
47869	c.ctx_ = ctx
47870	return c
47871}
47872
47873// Header returns an http.Header that can be modified by the caller to
47874// add HTTP headers to the request.
47875func (c *SubaccountsUpdateCall) Header() http.Header {
47876	if c.header_ == nil {
47877		c.header_ = make(http.Header)
47878	}
47879	return c.header_
47880}
47881
47882func (c *SubaccountsUpdateCall) doRequest(alt string) (*http.Response, error) {
47883	reqHeaders := make(http.Header)
47884	for k, v := range c.header_ {
47885		reqHeaders[k] = v
47886	}
47887	reqHeaders.Set("User-Agent", c.s.userAgent())
47888	var body io.Reader = nil
47889	body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
47890	if err != nil {
47891		return nil, err
47892	}
47893	reqHeaders.Set("Content-Type", "application/json")
47894	c.urlParams_.Set("alt", alt)
47895	c.urlParams_.Set("prettyPrint", "false")
47896	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47897	urls += "?" + c.urlParams_.Encode()
47898	req, err := http.NewRequest("PUT", urls, body)
47899	if err != nil {
47900		return nil, err
47901	}
47902	req.Header = reqHeaders
47903	googleapi.Expand(req.URL, map[string]string{
47904		"profileId": strconv.FormatInt(c.profileId, 10),
47905	})
47906	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47907}
47908
47909// Do executes the "dfareporting.subaccounts.update" call.
47910// Exactly one of *Subaccount or error will be non-nil. Any non-2xx
47911// status code is an error. Response headers are in either
47912// *Subaccount.ServerResponse.Header or (if a response was returned at
47913// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
47914// to check whether the returned error was because
47915// http.StatusNotModified was returned.
47916func (c *SubaccountsUpdateCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47917	gensupport.SetOptions(c.urlParams_, opts...)
47918	res, err := c.doRequest("json")
47919	if res != nil && res.StatusCode == http.StatusNotModified {
47920		if res.Body != nil {
47921			res.Body.Close()
47922		}
47923		return nil, &googleapi.Error{
47924			Code:   res.StatusCode,
47925			Header: res.Header,
47926		}
47927	}
47928	if err != nil {
47929		return nil, err
47930	}
47931	defer googleapi.CloseBody(res)
47932	if err := googleapi.CheckResponse(res); err != nil {
47933		return nil, err
47934	}
47935	ret := &Subaccount{
47936		ServerResponse: googleapi.ServerResponse{
47937			Header:         res.Header,
47938			HTTPStatusCode: res.StatusCode,
47939		},
47940	}
47941	target := &ret
47942	if err := gensupport.DecodeResponse(target, res); err != nil {
47943		return nil, err
47944	}
47945	return ret, nil
47946	// {
47947	//   "description": "Updates an existing subaccount.",
47948	//   "httpMethod": "PUT",
47949	//   "id": "dfareporting.subaccounts.update",
47950	//   "parameterOrder": [
47951	//     "profileId"
47952	//   ],
47953	//   "parameters": {
47954	//     "profileId": {
47955	//       "description": "User profile ID associated with this request.",
47956	//       "format": "int64",
47957	//       "location": "path",
47958	//       "required": true,
47959	//       "type": "string"
47960	//     }
47961	//   },
47962	//   "path": "userprofiles/{profileId}/subaccounts",
47963	//   "request": {
47964	//     "$ref": "Subaccount"
47965	//   },
47966	//   "response": {
47967	//     "$ref": "Subaccount"
47968	//   },
47969	//   "scopes": [
47970	//     "https://www.googleapis.com/auth/dfatrafficking"
47971	//   ]
47972	// }
47973
47974}
47975
47976// method id "dfareporting.targetableRemarketingLists.get":
47977
47978type TargetableRemarketingListsGetCall struct {
47979	s            *Service
47980	profileId    int64
47981	id           int64
47982	urlParams_   gensupport.URLParams
47983	ifNoneMatch_ string
47984	ctx_         context.Context
47985	header_      http.Header
47986}
47987
47988// Get: Gets one remarketing list by ID.
47989func (r *TargetableRemarketingListsService) Get(profileId int64, id int64) *TargetableRemarketingListsGetCall {
47990	c := &TargetableRemarketingListsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47991	c.profileId = profileId
47992	c.id = id
47993	return c
47994}
47995
47996// Fields allows partial responses to be retrieved. See
47997// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47998// for more information.
47999func (c *TargetableRemarketingListsGetCall) Fields(s ...googleapi.Field) *TargetableRemarketingListsGetCall {
48000	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48001	return c
48002}
48003
48004// IfNoneMatch sets the optional parameter which makes the operation
48005// fail if the object's ETag matches the given value. This is useful for
48006// getting updates only after the object has changed since the last
48007// request. Use googleapi.IsNotModified to check whether the response
48008// error from Do is the result of In-None-Match.
48009func (c *TargetableRemarketingListsGetCall) IfNoneMatch(entityTag string) *TargetableRemarketingListsGetCall {
48010	c.ifNoneMatch_ = entityTag
48011	return c
48012}
48013
48014// Context sets the context to be used in this call's Do method. Any
48015// pending HTTP request will be aborted if the provided context is
48016// canceled.
48017func (c *TargetableRemarketingListsGetCall) Context(ctx context.Context) *TargetableRemarketingListsGetCall {
48018	c.ctx_ = ctx
48019	return c
48020}
48021
48022// Header returns an http.Header that can be modified by the caller to
48023// add HTTP headers to the request.
48024func (c *TargetableRemarketingListsGetCall) Header() http.Header {
48025	if c.header_ == nil {
48026		c.header_ = make(http.Header)
48027	}
48028	return c.header_
48029}
48030
48031func (c *TargetableRemarketingListsGetCall) doRequest(alt string) (*http.Response, error) {
48032	reqHeaders := make(http.Header)
48033	for k, v := range c.header_ {
48034		reqHeaders[k] = v
48035	}
48036	reqHeaders.Set("User-Agent", c.s.userAgent())
48037	if c.ifNoneMatch_ != "" {
48038		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48039	}
48040	var body io.Reader = nil
48041	c.urlParams_.Set("alt", alt)
48042	c.urlParams_.Set("prettyPrint", "false")
48043	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetableRemarketingLists/{id}")
48044	urls += "?" + c.urlParams_.Encode()
48045	req, err := http.NewRequest("GET", urls, body)
48046	if err != nil {
48047		return nil, err
48048	}
48049	req.Header = reqHeaders
48050	googleapi.Expand(req.URL, map[string]string{
48051		"profileId": strconv.FormatInt(c.profileId, 10),
48052		"id":        strconv.FormatInt(c.id, 10),
48053	})
48054	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48055}
48056
48057// Do executes the "dfareporting.targetableRemarketingLists.get" call.
48058// Exactly one of *TargetableRemarketingList or error will be non-nil.
48059// Any non-2xx status code is an error. Response headers are in either
48060// *TargetableRemarketingList.ServerResponse.Header or (if a response
48061// was returned at all) in error.(*googleapi.Error).Header. Use
48062// googleapi.IsNotModified to check whether the returned error was
48063// because http.StatusNotModified was returned.
48064func (c *TargetableRemarketingListsGetCall) Do(opts ...googleapi.CallOption) (*TargetableRemarketingList, error) {
48065	gensupport.SetOptions(c.urlParams_, opts...)
48066	res, err := c.doRequest("json")
48067	if res != nil && res.StatusCode == http.StatusNotModified {
48068		if res.Body != nil {
48069			res.Body.Close()
48070		}
48071		return nil, &googleapi.Error{
48072			Code:   res.StatusCode,
48073			Header: res.Header,
48074		}
48075	}
48076	if err != nil {
48077		return nil, err
48078	}
48079	defer googleapi.CloseBody(res)
48080	if err := googleapi.CheckResponse(res); err != nil {
48081		return nil, err
48082	}
48083	ret := &TargetableRemarketingList{
48084		ServerResponse: googleapi.ServerResponse{
48085			Header:         res.Header,
48086			HTTPStatusCode: res.StatusCode,
48087		},
48088	}
48089	target := &ret
48090	if err := gensupport.DecodeResponse(target, res); err != nil {
48091		return nil, err
48092	}
48093	return ret, nil
48094	// {
48095	//   "description": "Gets one remarketing list by ID.",
48096	//   "httpMethod": "GET",
48097	//   "id": "dfareporting.targetableRemarketingLists.get",
48098	//   "parameterOrder": [
48099	//     "profileId",
48100	//     "id"
48101	//   ],
48102	//   "parameters": {
48103	//     "id": {
48104	//       "description": "Remarketing list ID.",
48105	//       "format": "int64",
48106	//       "location": "path",
48107	//       "required": true,
48108	//       "type": "string"
48109	//     },
48110	//     "profileId": {
48111	//       "description": "User profile ID associated with this request.",
48112	//       "format": "int64",
48113	//       "location": "path",
48114	//       "required": true,
48115	//       "type": "string"
48116	//     }
48117	//   },
48118	//   "path": "userprofiles/{profileId}/targetableRemarketingLists/{id}",
48119	//   "response": {
48120	//     "$ref": "TargetableRemarketingList"
48121	//   },
48122	//   "scopes": [
48123	//     "https://www.googleapis.com/auth/dfatrafficking"
48124	//   ]
48125	// }
48126
48127}
48128
48129// method id "dfareporting.targetableRemarketingLists.list":
48130
48131type TargetableRemarketingListsListCall struct {
48132	s            *Service
48133	profileId    int64
48134	urlParams_   gensupport.URLParams
48135	ifNoneMatch_ string
48136	ctx_         context.Context
48137	header_      http.Header
48138}
48139
48140// List: Retrieves a list of targetable remarketing lists, possibly
48141// filtered. This method supports paging.
48142func (r *TargetableRemarketingListsService) List(profileId int64, advertiserId int64) *TargetableRemarketingListsListCall {
48143	c := &TargetableRemarketingListsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48144	c.profileId = profileId
48145	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
48146	return c
48147}
48148
48149// Active sets the optional parameter "active": Select only active or
48150// only inactive targetable remarketing lists.
48151func (c *TargetableRemarketingListsListCall) Active(active bool) *TargetableRemarketingListsListCall {
48152	c.urlParams_.Set("active", fmt.Sprint(active))
48153	return c
48154}
48155
48156// MaxResults sets the optional parameter "maxResults": Maximum number
48157// of results to return.
48158func (c *TargetableRemarketingListsListCall) MaxResults(maxResults int64) *TargetableRemarketingListsListCall {
48159	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
48160	return c
48161}
48162
48163// Name sets the optional parameter "name": Allows searching for objects
48164// by name or ID. Wildcards (*) are allowed. For example, "remarketing
48165// list*2015" will return objects with names like "remarketing list June
48166// 2015", "remarketing list April 2015", or simply "remarketing list
48167// 2015". Most of the searches also add wildcards implicitly at the
48168// start and the end of the search string. For example, a search string
48169// of "remarketing list" will match objects with name "my remarketing
48170// list", "remarketing list 2015", or simply "remarketing list".
48171func (c *TargetableRemarketingListsListCall) Name(name string) *TargetableRemarketingListsListCall {
48172	c.urlParams_.Set("name", name)
48173	return c
48174}
48175
48176// PageToken sets the optional parameter "pageToken": Value of the
48177// nextPageToken from the previous result page.
48178func (c *TargetableRemarketingListsListCall) PageToken(pageToken string) *TargetableRemarketingListsListCall {
48179	c.urlParams_.Set("pageToken", pageToken)
48180	return c
48181}
48182
48183// SortField sets the optional parameter "sortField": Field by which to
48184// sort the list.
48185//
48186// Possible values:
48187//   "ID" (default)
48188//   "NAME"
48189func (c *TargetableRemarketingListsListCall) SortField(sortField string) *TargetableRemarketingListsListCall {
48190	c.urlParams_.Set("sortField", sortField)
48191	return c
48192}
48193
48194// SortOrder sets the optional parameter "sortOrder": Order of sorted
48195// results.
48196//
48197// Possible values:
48198//   "ASCENDING" (default)
48199//   "DESCENDING"
48200func (c *TargetableRemarketingListsListCall) SortOrder(sortOrder string) *TargetableRemarketingListsListCall {
48201	c.urlParams_.Set("sortOrder", sortOrder)
48202	return c
48203}
48204
48205// Fields allows partial responses to be retrieved. See
48206// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48207// for more information.
48208func (c *TargetableRemarketingListsListCall) Fields(s ...googleapi.Field) *TargetableRemarketingListsListCall {
48209	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48210	return c
48211}
48212
48213// IfNoneMatch sets the optional parameter which makes the operation
48214// fail if the object's ETag matches the given value. This is useful for
48215// getting updates only after the object has changed since the last
48216// request. Use googleapi.IsNotModified to check whether the response
48217// error from Do is the result of In-None-Match.
48218func (c *TargetableRemarketingListsListCall) IfNoneMatch(entityTag string) *TargetableRemarketingListsListCall {
48219	c.ifNoneMatch_ = entityTag
48220	return c
48221}
48222
48223// Context sets the context to be used in this call's Do method. Any
48224// pending HTTP request will be aborted if the provided context is
48225// canceled.
48226func (c *TargetableRemarketingListsListCall) Context(ctx context.Context) *TargetableRemarketingListsListCall {
48227	c.ctx_ = ctx
48228	return c
48229}
48230
48231// Header returns an http.Header that can be modified by the caller to
48232// add HTTP headers to the request.
48233func (c *TargetableRemarketingListsListCall) Header() http.Header {
48234	if c.header_ == nil {
48235		c.header_ = make(http.Header)
48236	}
48237	return c.header_
48238}
48239
48240func (c *TargetableRemarketingListsListCall) doRequest(alt string) (*http.Response, error) {
48241	reqHeaders := make(http.Header)
48242	for k, v := range c.header_ {
48243		reqHeaders[k] = v
48244	}
48245	reqHeaders.Set("User-Agent", c.s.userAgent())
48246	if c.ifNoneMatch_ != "" {
48247		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48248	}
48249	var body io.Reader = nil
48250	c.urlParams_.Set("alt", alt)
48251	c.urlParams_.Set("prettyPrint", "false")
48252	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetableRemarketingLists")
48253	urls += "?" + c.urlParams_.Encode()
48254	req, err := http.NewRequest("GET", urls, body)
48255	if err != nil {
48256		return nil, err
48257	}
48258	req.Header = reqHeaders
48259	googleapi.Expand(req.URL, map[string]string{
48260		"profileId": strconv.FormatInt(c.profileId, 10),
48261	})
48262	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48263}
48264
48265// Do executes the "dfareporting.targetableRemarketingLists.list" call.
48266// Exactly one of *TargetableRemarketingListsListResponse or error will
48267// be non-nil. Any non-2xx status code is an error. Response headers are
48268// in either
48269// *TargetableRemarketingListsListResponse.ServerResponse.Header or (if
48270// a response was returned at all) in error.(*googleapi.Error).Header.
48271// Use googleapi.IsNotModified to check whether the returned error was
48272// because http.StatusNotModified was returned.
48273func (c *TargetableRemarketingListsListCall) Do(opts ...googleapi.CallOption) (*TargetableRemarketingListsListResponse, error) {
48274	gensupport.SetOptions(c.urlParams_, opts...)
48275	res, err := c.doRequest("json")
48276	if res != nil && res.StatusCode == http.StatusNotModified {
48277		if res.Body != nil {
48278			res.Body.Close()
48279		}
48280		return nil, &googleapi.Error{
48281			Code:   res.StatusCode,
48282			Header: res.Header,
48283		}
48284	}
48285	if err != nil {
48286		return nil, err
48287	}
48288	defer googleapi.CloseBody(res)
48289	if err := googleapi.CheckResponse(res); err != nil {
48290		return nil, err
48291	}
48292	ret := &TargetableRemarketingListsListResponse{
48293		ServerResponse: googleapi.ServerResponse{
48294			Header:         res.Header,
48295			HTTPStatusCode: res.StatusCode,
48296		},
48297	}
48298	target := &ret
48299	if err := gensupport.DecodeResponse(target, res); err != nil {
48300		return nil, err
48301	}
48302	return ret, nil
48303	// {
48304	//   "description": "Retrieves a list of targetable remarketing lists, possibly filtered. This method supports paging.",
48305	//   "httpMethod": "GET",
48306	//   "id": "dfareporting.targetableRemarketingLists.list",
48307	//   "parameterOrder": [
48308	//     "profileId",
48309	//     "advertiserId"
48310	//   ],
48311	//   "parameters": {
48312	//     "active": {
48313	//       "description": "Select only active or only inactive targetable remarketing lists.",
48314	//       "location": "query",
48315	//       "type": "boolean"
48316	//     },
48317	//     "advertiserId": {
48318	//       "description": "Select only targetable remarketing lists targetable by these advertisers.",
48319	//       "format": "int64",
48320	//       "location": "query",
48321	//       "required": true,
48322	//       "type": "string"
48323	//     },
48324	//     "maxResults": {
48325	//       "default": "1000",
48326	//       "description": "Maximum number of results to return.",
48327	//       "format": "int32",
48328	//       "location": "query",
48329	//       "maximum": "1000",
48330	//       "minimum": "0",
48331	//       "type": "integer"
48332	//     },
48333	//     "name": {
48334	//       "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\".",
48335	//       "location": "query",
48336	//       "type": "string"
48337	//     },
48338	//     "pageToken": {
48339	//       "description": "Value of the nextPageToken from the previous result page.",
48340	//       "location": "query",
48341	//       "type": "string"
48342	//     },
48343	//     "profileId": {
48344	//       "description": "User profile ID associated with this request.",
48345	//       "format": "int64",
48346	//       "location": "path",
48347	//       "required": true,
48348	//       "type": "string"
48349	//     },
48350	//     "sortField": {
48351	//       "default": "ID",
48352	//       "description": "Field by which to sort the list.",
48353	//       "enum": [
48354	//         "ID",
48355	//         "NAME"
48356	//       ],
48357	//       "enumDescriptions": [
48358	//         "",
48359	//         ""
48360	//       ],
48361	//       "location": "query",
48362	//       "type": "string"
48363	//     },
48364	//     "sortOrder": {
48365	//       "default": "ASCENDING",
48366	//       "description": "Order of sorted results.",
48367	//       "enum": [
48368	//         "ASCENDING",
48369	//         "DESCENDING"
48370	//       ],
48371	//       "enumDescriptions": [
48372	//         "",
48373	//         ""
48374	//       ],
48375	//       "location": "query",
48376	//       "type": "string"
48377	//     }
48378	//   },
48379	//   "path": "userprofiles/{profileId}/targetableRemarketingLists",
48380	//   "response": {
48381	//     "$ref": "TargetableRemarketingListsListResponse"
48382	//   },
48383	//   "scopes": [
48384	//     "https://www.googleapis.com/auth/dfatrafficking"
48385	//   ]
48386	// }
48387
48388}
48389
48390// Pages invokes f for each page of results.
48391// A non-nil error returned from f will halt the iteration.
48392// The provided context supersedes any context provided to the Context method.
48393func (c *TargetableRemarketingListsListCall) Pages(ctx context.Context, f func(*TargetableRemarketingListsListResponse) error) error {
48394	c.ctx_ = ctx
48395	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
48396	for {
48397		x, err := c.Do()
48398		if err != nil {
48399			return err
48400		}
48401		if err := f(x); err != nil {
48402			return err
48403		}
48404		if x.NextPageToken == "" {
48405			return nil
48406		}
48407		c.PageToken(x.NextPageToken)
48408	}
48409}
48410
48411// method id "dfareporting.targetingTemplates.get":
48412
48413type TargetingTemplatesGetCall struct {
48414	s            *Service
48415	profileId    int64
48416	id           int64
48417	urlParams_   gensupport.URLParams
48418	ifNoneMatch_ string
48419	ctx_         context.Context
48420	header_      http.Header
48421}
48422
48423// Get: Gets one targeting template by ID.
48424func (r *TargetingTemplatesService) Get(profileId int64, id int64) *TargetingTemplatesGetCall {
48425	c := &TargetingTemplatesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48426	c.profileId = profileId
48427	c.id = id
48428	return c
48429}
48430
48431// Fields allows partial responses to be retrieved. See
48432// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48433// for more information.
48434func (c *TargetingTemplatesGetCall) Fields(s ...googleapi.Field) *TargetingTemplatesGetCall {
48435	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48436	return c
48437}
48438
48439// IfNoneMatch sets the optional parameter which makes the operation
48440// fail if the object's ETag matches the given value. This is useful for
48441// getting updates only after the object has changed since the last
48442// request. Use googleapi.IsNotModified to check whether the response
48443// error from Do is the result of In-None-Match.
48444func (c *TargetingTemplatesGetCall) IfNoneMatch(entityTag string) *TargetingTemplatesGetCall {
48445	c.ifNoneMatch_ = entityTag
48446	return c
48447}
48448
48449// Context sets the context to be used in this call's Do method. Any
48450// pending HTTP request will be aborted if the provided context is
48451// canceled.
48452func (c *TargetingTemplatesGetCall) Context(ctx context.Context) *TargetingTemplatesGetCall {
48453	c.ctx_ = ctx
48454	return c
48455}
48456
48457// Header returns an http.Header that can be modified by the caller to
48458// add HTTP headers to the request.
48459func (c *TargetingTemplatesGetCall) Header() http.Header {
48460	if c.header_ == nil {
48461		c.header_ = make(http.Header)
48462	}
48463	return c.header_
48464}
48465
48466func (c *TargetingTemplatesGetCall) doRequest(alt string) (*http.Response, error) {
48467	reqHeaders := make(http.Header)
48468	for k, v := range c.header_ {
48469		reqHeaders[k] = v
48470	}
48471	reqHeaders.Set("User-Agent", c.s.userAgent())
48472	if c.ifNoneMatch_ != "" {
48473		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48474	}
48475	var body io.Reader = nil
48476	c.urlParams_.Set("alt", alt)
48477	c.urlParams_.Set("prettyPrint", "false")
48478	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates/{id}")
48479	urls += "?" + c.urlParams_.Encode()
48480	req, err := http.NewRequest("GET", urls, body)
48481	if err != nil {
48482		return nil, err
48483	}
48484	req.Header = reqHeaders
48485	googleapi.Expand(req.URL, map[string]string{
48486		"profileId": strconv.FormatInt(c.profileId, 10),
48487		"id":        strconv.FormatInt(c.id, 10),
48488	})
48489	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48490}
48491
48492// Do executes the "dfareporting.targetingTemplates.get" call.
48493// Exactly one of *TargetingTemplate or error will be non-nil. Any
48494// non-2xx status code is an error. Response headers are in either
48495// *TargetingTemplate.ServerResponse.Header or (if a response was
48496// returned at all) in error.(*googleapi.Error).Header. Use
48497// googleapi.IsNotModified to check whether the returned error was
48498// because http.StatusNotModified was returned.
48499func (c *TargetingTemplatesGetCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
48500	gensupport.SetOptions(c.urlParams_, opts...)
48501	res, err := c.doRequest("json")
48502	if res != nil && res.StatusCode == http.StatusNotModified {
48503		if res.Body != nil {
48504			res.Body.Close()
48505		}
48506		return nil, &googleapi.Error{
48507			Code:   res.StatusCode,
48508			Header: res.Header,
48509		}
48510	}
48511	if err != nil {
48512		return nil, err
48513	}
48514	defer googleapi.CloseBody(res)
48515	if err := googleapi.CheckResponse(res); err != nil {
48516		return nil, err
48517	}
48518	ret := &TargetingTemplate{
48519		ServerResponse: googleapi.ServerResponse{
48520			Header:         res.Header,
48521			HTTPStatusCode: res.StatusCode,
48522		},
48523	}
48524	target := &ret
48525	if err := gensupport.DecodeResponse(target, res); err != nil {
48526		return nil, err
48527	}
48528	return ret, nil
48529	// {
48530	//   "description": "Gets one targeting template by ID.",
48531	//   "httpMethod": "GET",
48532	//   "id": "dfareporting.targetingTemplates.get",
48533	//   "parameterOrder": [
48534	//     "profileId",
48535	//     "id"
48536	//   ],
48537	//   "parameters": {
48538	//     "id": {
48539	//       "description": "Targeting template ID.",
48540	//       "format": "int64",
48541	//       "location": "path",
48542	//       "required": true,
48543	//       "type": "string"
48544	//     },
48545	//     "profileId": {
48546	//       "description": "User profile ID associated with this request.",
48547	//       "format": "int64",
48548	//       "location": "path",
48549	//       "required": true,
48550	//       "type": "string"
48551	//     }
48552	//   },
48553	//   "path": "userprofiles/{profileId}/targetingTemplates/{id}",
48554	//   "response": {
48555	//     "$ref": "TargetingTemplate"
48556	//   },
48557	//   "scopes": [
48558	//     "https://www.googleapis.com/auth/dfatrafficking"
48559	//   ]
48560	// }
48561
48562}
48563
48564// method id "dfareporting.targetingTemplates.insert":
48565
48566type TargetingTemplatesInsertCall struct {
48567	s                 *Service
48568	profileId         int64
48569	targetingtemplate *TargetingTemplate
48570	urlParams_        gensupport.URLParams
48571	ctx_              context.Context
48572	header_           http.Header
48573}
48574
48575// Insert: Inserts a new targeting template.
48576func (r *TargetingTemplatesService) Insert(profileId int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesInsertCall {
48577	c := &TargetingTemplatesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48578	c.profileId = profileId
48579	c.targetingtemplate = targetingtemplate
48580	return c
48581}
48582
48583// Fields allows partial responses to be retrieved. See
48584// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48585// for more information.
48586func (c *TargetingTemplatesInsertCall) Fields(s ...googleapi.Field) *TargetingTemplatesInsertCall {
48587	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48588	return c
48589}
48590
48591// Context sets the context to be used in this call's Do method. Any
48592// pending HTTP request will be aborted if the provided context is
48593// canceled.
48594func (c *TargetingTemplatesInsertCall) Context(ctx context.Context) *TargetingTemplatesInsertCall {
48595	c.ctx_ = ctx
48596	return c
48597}
48598
48599// Header returns an http.Header that can be modified by the caller to
48600// add HTTP headers to the request.
48601func (c *TargetingTemplatesInsertCall) Header() http.Header {
48602	if c.header_ == nil {
48603		c.header_ = make(http.Header)
48604	}
48605	return c.header_
48606}
48607
48608func (c *TargetingTemplatesInsertCall) doRequest(alt string) (*http.Response, error) {
48609	reqHeaders := make(http.Header)
48610	for k, v := range c.header_ {
48611		reqHeaders[k] = v
48612	}
48613	reqHeaders.Set("User-Agent", c.s.userAgent())
48614	var body io.Reader = nil
48615	body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
48616	if err != nil {
48617		return nil, err
48618	}
48619	reqHeaders.Set("Content-Type", "application/json")
48620	c.urlParams_.Set("alt", alt)
48621	c.urlParams_.Set("prettyPrint", "false")
48622	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
48623	urls += "?" + c.urlParams_.Encode()
48624	req, err := http.NewRequest("POST", urls, body)
48625	if err != nil {
48626		return nil, err
48627	}
48628	req.Header = reqHeaders
48629	googleapi.Expand(req.URL, map[string]string{
48630		"profileId": strconv.FormatInt(c.profileId, 10),
48631	})
48632	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48633}
48634
48635// Do executes the "dfareporting.targetingTemplates.insert" call.
48636// Exactly one of *TargetingTemplate or error will be non-nil. Any
48637// non-2xx status code is an error. Response headers are in either
48638// *TargetingTemplate.ServerResponse.Header or (if a response was
48639// returned at all) in error.(*googleapi.Error).Header. Use
48640// googleapi.IsNotModified to check whether the returned error was
48641// because http.StatusNotModified was returned.
48642func (c *TargetingTemplatesInsertCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
48643	gensupport.SetOptions(c.urlParams_, opts...)
48644	res, err := c.doRequest("json")
48645	if res != nil && res.StatusCode == http.StatusNotModified {
48646		if res.Body != nil {
48647			res.Body.Close()
48648		}
48649		return nil, &googleapi.Error{
48650			Code:   res.StatusCode,
48651			Header: res.Header,
48652		}
48653	}
48654	if err != nil {
48655		return nil, err
48656	}
48657	defer googleapi.CloseBody(res)
48658	if err := googleapi.CheckResponse(res); err != nil {
48659		return nil, err
48660	}
48661	ret := &TargetingTemplate{
48662		ServerResponse: googleapi.ServerResponse{
48663			Header:         res.Header,
48664			HTTPStatusCode: res.StatusCode,
48665		},
48666	}
48667	target := &ret
48668	if err := gensupport.DecodeResponse(target, res); err != nil {
48669		return nil, err
48670	}
48671	return ret, nil
48672	// {
48673	//   "description": "Inserts a new targeting template.",
48674	//   "httpMethod": "POST",
48675	//   "id": "dfareporting.targetingTemplates.insert",
48676	//   "parameterOrder": [
48677	//     "profileId"
48678	//   ],
48679	//   "parameters": {
48680	//     "profileId": {
48681	//       "description": "User profile ID associated with this request.",
48682	//       "format": "int64",
48683	//       "location": "path",
48684	//       "required": true,
48685	//       "type": "string"
48686	//     }
48687	//   },
48688	//   "path": "userprofiles/{profileId}/targetingTemplates",
48689	//   "request": {
48690	//     "$ref": "TargetingTemplate"
48691	//   },
48692	//   "response": {
48693	//     "$ref": "TargetingTemplate"
48694	//   },
48695	//   "scopes": [
48696	//     "https://www.googleapis.com/auth/dfatrafficking"
48697	//   ]
48698	// }
48699
48700}
48701
48702// method id "dfareporting.targetingTemplates.list":
48703
48704type TargetingTemplatesListCall struct {
48705	s            *Service
48706	profileId    int64
48707	urlParams_   gensupport.URLParams
48708	ifNoneMatch_ string
48709	ctx_         context.Context
48710	header_      http.Header
48711}
48712
48713// List: Retrieves a list of targeting templates, optionally filtered.
48714// This method supports paging.
48715func (r *TargetingTemplatesService) List(profileId int64) *TargetingTemplatesListCall {
48716	c := &TargetingTemplatesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48717	c.profileId = profileId
48718	return c
48719}
48720
48721// AdvertiserId sets the optional parameter "advertiserId": Select only
48722// targeting templates with this advertiser ID.
48723func (c *TargetingTemplatesListCall) AdvertiserId(advertiserId int64) *TargetingTemplatesListCall {
48724	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
48725	return c
48726}
48727
48728// Ids sets the optional parameter "ids": Select only targeting
48729// templates with these IDs.
48730func (c *TargetingTemplatesListCall) Ids(ids ...int64) *TargetingTemplatesListCall {
48731	var ids_ []string
48732	for _, v := range ids {
48733		ids_ = append(ids_, fmt.Sprint(v))
48734	}
48735	c.urlParams_.SetMulti("ids", ids_)
48736	return c
48737}
48738
48739// MaxResults sets the optional parameter "maxResults": Maximum number
48740// of results to return.
48741func (c *TargetingTemplatesListCall) MaxResults(maxResults int64) *TargetingTemplatesListCall {
48742	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
48743	return c
48744}
48745
48746// PageToken sets the optional parameter "pageToken": Value of the
48747// nextPageToken from the previous result page.
48748func (c *TargetingTemplatesListCall) PageToken(pageToken string) *TargetingTemplatesListCall {
48749	c.urlParams_.Set("pageToken", pageToken)
48750	return c
48751}
48752
48753// SearchString sets the optional parameter "searchString": Allows
48754// searching for objects by name or ID. Wildcards (*) are allowed. For
48755// example, "template*2015" will return objects with names like
48756// "template June 2015", "template April 2015", or simply "template
48757// 2015". Most of the searches also add wildcards implicitly at the
48758// start and the end of the search string. For example, a search string
48759// of "template" will match objects with name "my template", "template
48760// 2015", or simply "template".
48761func (c *TargetingTemplatesListCall) SearchString(searchString string) *TargetingTemplatesListCall {
48762	c.urlParams_.Set("searchString", searchString)
48763	return c
48764}
48765
48766// SortField sets the optional parameter "sortField": Field by which to
48767// sort the list.
48768//
48769// Possible values:
48770//   "ID" (default)
48771//   "NAME"
48772func (c *TargetingTemplatesListCall) SortField(sortField string) *TargetingTemplatesListCall {
48773	c.urlParams_.Set("sortField", sortField)
48774	return c
48775}
48776
48777// SortOrder sets the optional parameter "sortOrder": Order of sorted
48778// results.
48779//
48780// Possible values:
48781//   "ASCENDING" (default)
48782//   "DESCENDING"
48783func (c *TargetingTemplatesListCall) SortOrder(sortOrder string) *TargetingTemplatesListCall {
48784	c.urlParams_.Set("sortOrder", sortOrder)
48785	return c
48786}
48787
48788// Fields allows partial responses to be retrieved. See
48789// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48790// for more information.
48791func (c *TargetingTemplatesListCall) Fields(s ...googleapi.Field) *TargetingTemplatesListCall {
48792	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48793	return c
48794}
48795
48796// IfNoneMatch sets the optional parameter which makes the operation
48797// fail if the object's ETag matches the given value. This is useful for
48798// getting updates only after the object has changed since the last
48799// request. Use googleapi.IsNotModified to check whether the response
48800// error from Do is the result of In-None-Match.
48801func (c *TargetingTemplatesListCall) IfNoneMatch(entityTag string) *TargetingTemplatesListCall {
48802	c.ifNoneMatch_ = entityTag
48803	return c
48804}
48805
48806// Context sets the context to be used in this call's Do method. Any
48807// pending HTTP request will be aborted if the provided context is
48808// canceled.
48809func (c *TargetingTemplatesListCall) Context(ctx context.Context) *TargetingTemplatesListCall {
48810	c.ctx_ = ctx
48811	return c
48812}
48813
48814// Header returns an http.Header that can be modified by the caller to
48815// add HTTP headers to the request.
48816func (c *TargetingTemplatesListCall) Header() http.Header {
48817	if c.header_ == nil {
48818		c.header_ = make(http.Header)
48819	}
48820	return c.header_
48821}
48822
48823func (c *TargetingTemplatesListCall) doRequest(alt string) (*http.Response, error) {
48824	reqHeaders := make(http.Header)
48825	for k, v := range c.header_ {
48826		reqHeaders[k] = v
48827	}
48828	reqHeaders.Set("User-Agent", c.s.userAgent())
48829	if c.ifNoneMatch_ != "" {
48830		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48831	}
48832	var body io.Reader = nil
48833	c.urlParams_.Set("alt", alt)
48834	c.urlParams_.Set("prettyPrint", "false")
48835	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
48836	urls += "?" + c.urlParams_.Encode()
48837	req, err := http.NewRequest("GET", urls, body)
48838	if err != nil {
48839		return nil, err
48840	}
48841	req.Header = reqHeaders
48842	googleapi.Expand(req.URL, map[string]string{
48843		"profileId": strconv.FormatInt(c.profileId, 10),
48844	})
48845	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48846}
48847
48848// Do executes the "dfareporting.targetingTemplates.list" call.
48849// Exactly one of *TargetingTemplatesListResponse or error will be
48850// non-nil. Any non-2xx status code is an error. Response headers are in
48851// either *TargetingTemplatesListResponse.ServerResponse.Header or (if a
48852// response was returned at all) in error.(*googleapi.Error).Header. Use
48853// googleapi.IsNotModified to check whether the returned error was
48854// because http.StatusNotModified was returned.
48855func (c *TargetingTemplatesListCall) Do(opts ...googleapi.CallOption) (*TargetingTemplatesListResponse, error) {
48856	gensupport.SetOptions(c.urlParams_, opts...)
48857	res, err := c.doRequest("json")
48858	if res != nil && res.StatusCode == http.StatusNotModified {
48859		if res.Body != nil {
48860			res.Body.Close()
48861		}
48862		return nil, &googleapi.Error{
48863			Code:   res.StatusCode,
48864			Header: res.Header,
48865		}
48866	}
48867	if err != nil {
48868		return nil, err
48869	}
48870	defer googleapi.CloseBody(res)
48871	if err := googleapi.CheckResponse(res); err != nil {
48872		return nil, err
48873	}
48874	ret := &TargetingTemplatesListResponse{
48875		ServerResponse: googleapi.ServerResponse{
48876			Header:         res.Header,
48877			HTTPStatusCode: res.StatusCode,
48878		},
48879	}
48880	target := &ret
48881	if err := gensupport.DecodeResponse(target, res); err != nil {
48882		return nil, err
48883	}
48884	return ret, nil
48885	// {
48886	//   "description": "Retrieves a list of targeting templates, optionally filtered. This method supports paging.",
48887	//   "httpMethod": "GET",
48888	//   "id": "dfareporting.targetingTemplates.list",
48889	//   "parameterOrder": [
48890	//     "profileId"
48891	//   ],
48892	//   "parameters": {
48893	//     "advertiserId": {
48894	//       "description": "Select only targeting templates with this advertiser ID.",
48895	//       "format": "int64",
48896	//       "location": "query",
48897	//       "type": "string"
48898	//     },
48899	//     "ids": {
48900	//       "description": "Select only targeting templates with these IDs.",
48901	//       "format": "int64",
48902	//       "location": "query",
48903	//       "repeated": true,
48904	//       "type": "string"
48905	//     },
48906	//     "maxResults": {
48907	//       "default": "1000",
48908	//       "description": "Maximum number of results to return.",
48909	//       "format": "int32",
48910	//       "location": "query",
48911	//       "maximum": "1000",
48912	//       "minimum": "0",
48913	//       "type": "integer"
48914	//     },
48915	//     "pageToken": {
48916	//       "description": "Value of the nextPageToken from the previous result page.",
48917	//       "location": "query",
48918	//       "type": "string"
48919	//     },
48920	//     "profileId": {
48921	//       "description": "User profile ID associated with this request.",
48922	//       "format": "int64",
48923	//       "location": "path",
48924	//       "required": true,
48925	//       "type": "string"
48926	//     },
48927	//     "searchString": {
48928	//       "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\".",
48929	//       "location": "query",
48930	//       "type": "string"
48931	//     },
48932	//     "sortField": {
48933	//       "default": "ID",
48934	//       "description": "Field by which to sort the list.",
48935	//       "enum": [
48936	//         "ID",
48937	//         "NAME"
48938	//       ],
48939	//       "enumDescriptions": [
48940	//         "",
48941	//         ""
48942	//       ],
48943	//       "location": "query",
48944	//       "type": "string"
48945	//     },
48946	//     "sortOrder": {
48947	//       "default": "ASCENDING",
48948	//       "description": "Order of sorted results.",
48949	//       "enum": [
48950	//         "ASCENDING",
48951	//         "DESCENDING"
48952	//       ],
48953	//       "enumDescriptions": [
48954	//         "",
48955	//         ""
48956	//       ],
48957	//       "location": "query",
48958	//       "type": "string"
48959	//     }
48960	//   },
48961	//   "path": "userprofiles/{profileId}/targetingTemplates",
48962	//   "response": {
48963	//     "$ref": "TargetingTemplatesListResponse"
48964	//   },
48965	//   "scopes": [
48966	//     "https://www.googleapis.com/auth/dfatrafficking"
48967	//   ]
48968	// }
48969
48970}
48971
48972// Pages invokes f for each page of results.
48973// A non-nil error returned from f will halt the iteration.
48974// The provided context supersedes any context provided to the Context method.
48975func (c *TargetingTemplatesListCall) Pages(ctx context.Context, f func(*TargetingTemplatesListResponse) error) error {
48976	c.ctx_ = ctx
48977	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
48978	for {
48979		x, err := c.Do()
48980		if err != nil {
48981			return err
48982		}
48983		if err := f(x); err != nil {
48984			return err
48985		}
48986		if x.NextPageToken == "" {
48987			return nil
48988		}
48989		c.PageToken(x.NextPageToken)
48990	}
48991}
48992
48993// method id "dfareporting.targetingTemplates.patch":
48994
48995type TargetingTemplatesPatchCall struct {
48996	s                 *Service
48997	profileId         int64
48998	targetingtemplate *TargetingTemplate
48999	urlParams_        gensupport.URLParams
49000	ctx_              context.Context
49001	header_           http.Header
49002}
49003
49004// Patch: Updates an existing targeting template. This method supports
49005// patch semantics.
49006func (r *TargetingTemplatesService) Patch(profileId int64, id int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesPatchCall {
49007	c := &TargetingTemplatesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49008	c.profileId = profileId
49009	c.urlParams_.Set("id", fmt.Sprint(id))
49010	c.targetingtemplate = targetingtemplate
49011	return c
49012}
49013
49014// Fields allows partial responses to be retrieved. See
49015// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49016// for more information.
49017func (c *TargetingTemplatesPatchCall) Fields(s ...googleapi.Field) *TargetingTemplatesPatchCall {
49018	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49019	return c
49020}
49021
49022// Context sets the context to be used in this call's Do method. Any
49023// pending HTTP request will be aborted if the provided context is
49024// canceled.
49025func (c *TargetingTemplatesPatchCall) Context(ctx context.Context) *TargetingTemplatesPatchCall {
49026	c.ctx_ = ctx
49027	return c
49028}
49029
49030// Header returns an http.Header that can be modified by the caller to
49031// add HTTP headers to the request.
49032func (c *TargetingTemplatesPatchCall) Header() http.Header {
49033	if c.header_ == nil {
49034		c.header_ = make(http.Header)
49035	}
49036	return c.header_
49037}
49038
49039func (c *TargetingTemplatesPatchCall) doRequest(alt string) (*http.Response, error) {
49040	reqHeaders := make(http.Header)
49041	for k, v := range c.header_ {
49042		reqHeaders[k] = v
49043	}
49044	reqHeaders.Set("User-Agent", c.s.userAgent())
49045	var body io.Reader = nil
49046	body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
49047	if err != nil {
49048		return nil, err
49049	}
49050	reqHeaders.Set("Content-Type", "application/json")
49051	c.urlParams_.Set("alt", alt)
49052	c.urlParams_.Set("prettyPrint", "false")
49053	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
49054	urls += "?" + c.urlParams_.Encode()
49055	req, err := http.NewRequest("PATCH", urls, body)
49056	if err != nil {
49057		return nil, err
49058	}
49059	req.Header = reqHeaders
49060	googleapi.Expand(req.URL, map[string]string{
49061		"profileId": strconv.FormatInt(c.profileId, 10),
49062	})
49063	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49064}
49065
49066// Do executes the "dfareporting.targetingTemplates.patch" call.
49067// Exactly one of *TargetingTemplate or error will be non-nil. Any
49068// non-2xx status code is an error. Response headers are in either
49069// *TargetingTemplate.ServerResponse.Header or (if a response was
49070// returned at all) in error.(*googleapi.Error).Header. Use
49071// googleapi.IsNotModified to check whether the returned error was
49072// because http.StatusNotModified was returned.
49073func (c *TargetingTemplatesPatchCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
49074	gensupport.SetOptions(c.urlParams_, opts...)
49075	res, err := c.doRequest("json")
49076	if res != nil && res.StatusCode == http.StatusNotModified {
49077		if res.Body != nil {
49078			res.Body.Close()
49079		}
49080		return nil, &googleapi.Error{
49081			Code:   res.StatusCode,
49082			Header: res.Header,
49083		}
49084	}
49085	if err != nil {
49086		return nil, err
49087	}
49088	defer googleapi.CloseBody(res)
49089	if err := googleapi.CheckResponse(res); err != nil {
49090		return nil, err
49091	}
49092	ret := &TargetingTemplate{
49093		ServerResponse: googleapi.ServerResponse{
49094			Header:         res.Header,
49095			HTTPStatusCode: res.StatusCode,
49096		},
49097	}
49098	target := &ret
49099	if err := gensupport.DecodeResponse(target, res); err != nil {
49100		return nil, err
49101	}
49102	return ret, nil
49103	// {
49104	//   "description": "Updates an existing targeting template. This method supports patch semantics.",
49105	//   "httpMethod": "PATCH",
49106	//   "id": "dfareporting.targetingTemplates.patch",
49107	//   "parameterOrder": [
49108	//     "profileId",
49109	//     "id"
49110	//   ],
49111	//   "parameters": {
49112	//     "id": {
49113	//       "description": "Targeting template ID.",
49114	//       "format": "int64",
49115	//       "location": "query",
49116	//       "required": true,
49117	//       "type": "string"
49118	//     },
49119	//     "profileId": {
49120	//       "description": "User profile ID associated with this request.",
49121	//       "format": "int64",
49122	//       "location": "path",
49123	//       "required": true,
49124	//       "type": "string"
49125	//     }
49126	//   },
49127	//   "path": "userprofiles/{profileId}/targetingTemplates",
49128	//   "request": {
49129	//     "$ref": "TargetingTemplate"
49130	//   },
49131	//   "response": {
49132	//     "$ref": "TargetingTemplate"
49133	//   },
49134	//   "scopes": [
49135	//     "https://www.googleapis.com/auth/dfatrafficking"
49136	//   ]
49137	// }
49138
49139}
49140
49141// method id "dfareporting.targetingTemplates.update":
49142
49143type TargetingTemplatesUpdateCall struct {
49144	s                 *Service
49145	profileId         int64
49146	targetingtemplate *TargetingTemplate
49147	urlParams_        gensupport.URLParams
49148	ctx_              context.Context
49149	header_           http.Header
49150}
49151
49152// Update: Updates an existing targeting template.
49153func (r *TargetingTemplatesService) Update(profileId int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesUpdateCall {
49154	c := &TargetingTemplatesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49155	c.profileId = profileId
49156	c.targetingtemplate = targetingtemplate
49157	return c
49158}
49159
49160// Fields allows partial responses to be retrieved. See
49161// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49162// for more information.
49163func (c *TargetingTemplatesUpdateCall) Fields(s ...googleapi.Field) *TargetingTemplatesUpdateCall {
49164	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49165	return c
49166}
49167
49168// Context sets the context to be used in this call's Do method. Any
49169// pending HTTP request will be aborted if the provided context is
49170// canceled.
49171func (c *TargetingTemplatesUpdateCall) Context(ctx context.Context) *TargetingTemplatesUpdateCall {
49172	c.ctx_ = ctx
49173	return c
49174}
49175
49176// Header returns an http.Header that can be modified by the caller to
49177// add HTTP headers to the request.
49178func (c *TargetingTemplatesUpdateCall) Header() http.Header {
49179	if c.header_ == nil {
49180		c.header_ = make(http.Header)
49181	}
49182	return c.header_
49183}
49184
49185func (c *TargetingTemplatesUpdateCall) doRequest(alt string) (*http.Response, error) {
49186	reqHeaders := make(http.Header)
49187	for k, v := range c.header_ {
49188		reqHeaders[k] = v
49189	}
49190	reqHeaders.Set("User-Agent", c.s.userAgent())
49191	var body io.Reader = nil
49192	body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
49193	if err != nil {
49194		return nil, err
49195	}
49196	reqHeaders.Set("Content-Type", "application/json")
49197	c.urlParams_.Set("alt", alt)
49198	c.urlParams_.Set("prettyPrint", "false")
49199	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
49200	urls += "?" + c.urlParams_.Encode()
49201	req, err := http.NewRequest("PUT", urls, body)
49202	if err != nil {
49203		return nil, err
49204	}
49205	req.Header = reqHeaders
49206	googleapi.Expand(req.URL, map[string]string{
49207		"profileId": strconv.FormatInt(c.profileId, 10),
49208	})
49209	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49210}
49211
49212// Do executes the "dfareporting.targetingTemplates.update" call.
49213// Exactly one of *TargetingTemplate or error will be non-nil. Any
49214// non-2xx status code is an error. Response headers are in either
49215// *TargetingTemplate.ServerResponse.Header or (if a response was
49216// returned at all) in error.(*googleapi.Error).Header. Use
49217// googleapi.IsNotModified to check whether the returned error was
49218// because http.StatusNotModified was returned.
49219func (c *TargetingTemplatesUpdateCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
49220	gensupport.SetOptions(c.urlParams_, opts...)
49221	res, err := c.doRequest("json")
49222	if res != nil && res.StatusCode == http.StatusNotModified {
49223		if res.Body != nil {
49224			res.Body.Close()
49225		}
49226		return nil, &googleapi.Error{
49227			Code:   res.StatusCode,
49228			Header: res.Header,
49229		}
49230	}
49231	if err != nil {
49232		return nil, err
49233	}
49234	defer googleapi.CloseBody(res)
49235	if err := googleapi.CheckResponse(res); err != nil {
49236		return nil, err
49237	}
49238	ret := &TargetingTemplate{
49239		ServerResponse: googleapi.ServerResponse{
49240			Header:         res.Header,
49241			HTTPStatusCode: res.StatusCode,
49242		},
49243	}
49244	target := &ret
49245	if err := gensupport.DecodeResponse(target, res); err != nil {
49246		return nil, err
49247	}
49248	return ret, nil
49249	// {
49250	//   "description": "Updates an existing targeting template.",
49251	//   "httpMethod": "PUT",
49252	//   "id": "dfareporting.targetingTemplates.update",
49253	//   "parameterOrder": [
49254	//     "profileId"
49255	//   ],
49256	//   "parameters": {
49257	//     "profileId": {
49258	//       "description": "User profile ID associated with this request.",
49259	//       "format": "int64",
49260	//       "location": "path",
49261	//       "required": true,
49262	//       "type": "string"
49263	//     }
49264	//   },
49265	//   "path": "userprofiles/{profileId}/targetingTemplates",
49266	//   "request": {
49267	//     "$ref": "TargetingTemplate"
49268	//   },
49269	//   "response": {
49270	//     "$ref": "TargetingTemplate"
49271	//   },
49272	//   "scopes": [
49273	//     "https://www.googleapis.com/auth/dfatrafficking"
49274	//   ]
49275	// }
49276
49277}
49278
49279// method id "dfareporting.userProfiles.get":
49280
49281type UserProfilesGetCall struct {
49282	s            *Service
49283	profileId    int64
49284	urlParams_   gensupport.URLParams
49285	ifNoneMatch_ string
49286	ctx_         context.Context
49287	header_      http.Header
49288}
49289
49290// Get: Gets one user profile by ID.
49291func (r *UserProfilesService) Get(profileId int64) *UserProfilesGetCall {
49292	c := &UserProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49293	c.profileId = profileId
49294	return c
49295}
49296
49297// Fields allows partial responses to be retrieved. See
49298// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49299// for more information.
49300func (c *UserProfilesGetCall) Fields(s ...googleapi.Field) *UserProfilesGetCall {
49301	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49302	return c
49303}
49304
49305// IfNoneMatch sets the optional parameter which makes the operation
49306// fail if the object's ETag matches the given value. This is useful for
49307// getting updates only after the object has changed since the last
49308// request. Use googleapi.IsNotModified to check whether the response
49309// error from Do is the result of In-None-Match.
49310func (c *UserProfilesGetCall) IfNoneMatch(entityTag string) *UserProfilesGetCall {
49311	c.ifNoneMatch_ = entityTag
49312	return c
49313}
49314
49315// Context sets the context to be used in this call's Do method. Any
49316// pending HTTP request will be aborted if the provided context is
49317// canceled.
49318func (c *UserProfilesGetCall) Context(ctx context.Context) *UserProfilesGetCall {
49319	c.ctx_ = ctx
49320	return c
49321}
49322
49323// Header returns an http.Header that can be modified by the caller to
49324// add HTTP headers to the request.
49325func (c *UserProfilesGetCall) Header() http.Header {
49326	if c.header_ == nil {
49327		c.header_ = make(http.Header)
49328	}
49329	return c.header_
49330}
49331
49332func (c *UserProfilesGetCall) doRequest(alt string) (*http.Response, error) {
49333	reqHeaders := make(http.Header)
49334	for k, v := range c.header_ {
49335		reqHeaders[k] = v
49336	}
49337	reqHeaders.Set("User-Agent", c.s.userAgent())
49338	if c.ifNoneMatch_ != "" {
49339		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49340	}
49341	var body io.Reader = nil
49342	c.urlParams_.Set("alt", alt)
49343	c.urlParams_.Set("prettyPrint", "false")
49344	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}")
49345	urls += "?" + c.urlParams_.Encode()
49346	req, err := http.NewRequest("GET", urls, body)
49347	if err != nil {
49348		return nil, err
49349	}
49350	req.Header = reqHeaders
49351	googleapi.Expand(req.URL, map[string]string{
49352		"profileId": strconv.FormatInt(c.profileId, 10),
49353	})
49354	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49355}
49356
49357// Do executes the "dfareporting.userProfiles.get" call.
49358// Exactly one of *UserProfile or error will be non-nil. Any non-2xx
49359// status code is an error. Response headers are in either
49360// *UserProfile.ServerResponse.Header or (if a response was returned at
49361// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
49362// to check whether the returned error was because
49363// http.StatusNotModified was returned.
49364func (c *UserProfilesGetCall) Do(opts ...googleapi.CallOption) (*UserProfile, error) {
49365	gensupport.SetOptions(c.urlParams_, opts...)
49366	res, err := c.doRequest("json")
49367	if res != nil && res.StatusCode == http.StatusNotModified {
49368		if res.Body != nil {
49369			res.Body.Close()
49370		}
49371		return nil, &googleapi.Error{
49372			Code:   res.StatusCode,
49373			Header: res.Header,
49374		}
49375	}
49376	if err != nil {
49377		return nil, err
49378	}
49379	defer googleapi.CloseBody(res)
49380	if err := googleapi.CheckResponse(res); err != nil {
49381		return nil, err
49382	}
49383	ret := &UserProfile{
49384		ServerResponse: googleapi.ServerResponse{
49385			Header:         res.Header,
49386			HTTPStatusCode: res.StatusCode,
49387		},
49388	}
49389	target := &ret
49390	if err := gensupport.DecodeResponse(target, res); err != nil {
49391		return nil, err
49392	}
49393	return ret, nil
49394	// {
49395	//   "description": "Gets one user profile by ID.",
49396	//   "httpMethod": "GET",
49397	//   "id": "dfareporting.userProfiles.get",
49398	//   "parameterOrder": [
49399	//     "profileId"
49400	//   ],
49401	//   "parameters": {
49402	//     "profileId": {
49403	//       "description": "The user profile ID.",
49404	//       "format": "int64",
49405	//       "location": "path",
49406	//       "required": true,
49407	//       "type": "string"
49408	//     }
49409	//   },
49410	//   "path": "userprofiles/{profileId}",
49411	//   "response": {
49412	//     "$ref": "UserProfile"
49413	//   },
49414	//   "scopes": [
49415	//     "https://www.googleapis.com/auth/dfareporting",
49416	//     "https://www.googleapis.com/auth/dfatrafficking"
49417	//   ]
49418	// }
49419
49420}
49421
49422// method id "dfareporting.userProfiles.list":
49423
49424type UserProfilesListCall struct {
49425	s            *Service
49426	urlParams_   gensupport.URLParams
49427	ifNoneMatch_ string
49428	ctx_         context.Context
49429	header_      http.Header
49430}
49431
49432// List: Retrieves list of user profiles for a user.
49433func (r *UserProfilesService) List() *UserProfilesListCall {
49434	c := &UserProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49435	return c
49436}
49437
49438// Fields allows partial responses to be retrieved. See
49439// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49440// for more information.
49441func (c *UserProfilesListCall) Fields(s ...googleapi.Field) *UserProfilesListCall {
49442	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49443	return c
49444}
49445
49446// IfNoneMatch sets the optional parameter which makes the operation
49447// fail if the object's ETag matches the given value. This is useful for
49448// getting updates only after the object has changed since the last
49449// request. Use googleapi.IsNotModified to check whether the response
49450// error from Do is the result of In-None-Match.
49451func (c *UserProfilesListCall) IfNoneMatch(entityTag string) *UserProfilesListCall {
49452	c.ifNoneMatch_ = entityTag
49453	return c
49454}
49455
49456// Context sets the context to be used in this call's Do method. Any
49457// pending HTTP request will be aborted if the provided context is
49458// canceled.
49459func (c *UserProfilesListCall) Context(ctx context.Context) *UserProfilesListCall {
49460	c.ctx_ = ctx
49461	return c
49462}
49463
49464// Header returns an http.Header that can be modified by the caller to
49465// add HTTP headers to the request.
49466func (c *UserProfilesListCall) Header() http.Header {
49467	if c.header_ == nil {
49468		c.header_ = make(http.Header)
49469	}
49470	return c.header_
49471}
49472
49473func (c *UserProfilesListCall) doRequest(alt string) (*http.Response, error) {
49474	reqHeaders := make(http.Header)
49475	for k, v := range c.header_ {
49476		reqHeaders[k] = v
49477	}
49478	reqHeaders.Set("User-Agent", c.s.userAgent())
49479	if c.ifNoneMatch_ != "" {
49480		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49481	}
49482	var body io.Reader = nil
49483	c.urlParams_.Set("alt", alt)
49484	c.urlParams_.Set("prettyPrint", "false")
49485	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles")
49486	urls += "?" + c.urlParams_.Encode()
49487	req, err := http.NewRequest("GET", urls, body)
49488	if err != nil {
49489		return nil, err
49490	}
49491	req.Header = reqHeaders
49492	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49493}
49494
49495// Do executes the "dfareporting.userProfiles.list" call.
49496// Exactly one of *UserProfileList or error will be non-nil. Any non-2xx
49497// status code is an error. Response headers are in either
49498// *UserProfileList.ServerResponse.Header or (if a response was returned
49499// at all) in error.(*googleapi.Error).Header. Use
49500// googleapi.IsNotModified to check whether the returned error was
49501// because http.StatusNotModified was returned.
49502func (c *UserProfilesListCall) Do(opts ...googleapi.CallOption) (*UserProfileList, error) {
49503	gensupport.SetOptions(c.urlParams_, opts...)
49504	res, err := c.doRequest("json")
49505	if res != nil && res.StatusCode == http.StatusNotModified {
49506		if res.Body != nil {
49507			res.Body.Close()
49508		}
49509		return nil, &googleapi.Error{
49510			Code:   res.StatusCode,
49511			Header: res.Header,
49512		}
49513	}
49514	if err != nil {
49515		return nil, err
49516	}
49517	defer googleapi.CloseBody(res)
49518	if err := googleapi.CheckResponse(res); err != nil {
49519		return nil, err
49520	}
49521	ret := &UserProfileList{
49522		ServerResponse: googleapi.ServerResponse{
49523			Header:         res.Header,
49524			HTTPStatusCode: res.StatusCode,
49525		},
49526	}
49527	target := &ret
49528	if err := gensupport.DecodeResponse(target, res); err != nil {
49529		return nil, err
49530	}
49531	return ret, nil
49532	// {
49533	//   "description": "Retrieves list of user profiles for a user.",
49534	//   "httpMethod": "GET",
49535	//   "id": "dfareporting.userProfiles.list",
49536	//   "path": "userprofiles",
49537	//   "response": {
49538	//     "$ref": "UserProfileList"
49539	//   },
49540	//   "scopes": [
49541	//     "https://www.googleapis.com/auth/dfareporting",
49542	//     "https://www.googleapis.com/auth/dfatrafficking"
49543	//   ]
49544	// }
49545
49546}
49547
49548// method id "dfareporting.userRolePermissionGroups.get":
49549
49550type UserRolePermissionGroupsGetCall struct {
49551	s            *Service
49552	profileId    int64
49553	id           int64
49554	urlParams_   gensupport.URLParams
49555	ifNoneMatch_ string
49556	ctx_         context.Context
49557	header_      http.Header
49558}
49559
49560// Get: Gets one user role permission group by ID.
49561func (r *UserRolePermissionGroupsService) Get(profileId int64, id int64) *UserRolePermissionGroupsGetCall {
49562	c := &UserRolePermissionGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49563	c.profileId = profileId
49564	c.id = id
49565	return c
49566}
49567
49568// Fields allows partial responses to be retrieved. See
49569// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49570// for more information.
49571func (c *UserRolePermissionGroupsGetCall) Fields(s ...googleapi.Field) *UserRolePermissionGroupsGetCall {
49572	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49573	return c
49574}
49575
49576// IfNoneMatch sets the optional parameter which makes the operation
49577// fail if the object's ETag matches the given value. This is useful for
49578// getting updates only after the object has changed since the last
49579// request. Use googleapi.IsNotModified to check whether the response
49580// error from Do is the result of In-None-Match.
49581func (c *UserRolePermissionGroupsGetCall) IfNoneMatch(entityTag string) *UserRolePermissionGroupsGetCall {
49582	c.ifNoneMatch_ = entityTag
49583	return c
49584}
49585
49586// Context sets the context to be used in this call's Do method. Any
49587// pending HTTP request will be aborted if the provided context is
49588// canceled.
49589func (c *UserRolePermissionGroupsGetCall) Context(ctx context.Context) *UserRolePermissionGroupsGetCall {
49590	c.ctx_ = ctx
49591	return c
49592}
49593
49594// Header returns an http.Header that can be modified by the caller to
49595// add HTTP headers to the request.
49596func (c *UserRolePermissionGroupsGetCall) Header() http.Header {
49597	if c.header_ == nil {
49598		c.header_ = make(http.Header)
49599	}
49600	return c.header_
49601}
49602
49603func (c *UserRolePermissionGroupsGetCall) doRequest(alt string) (*http.Response, error) {
49604	reqHeaders := make(http.Header)
49605	for k, v := range c.header_ {
49606		reqHeaders[k] = v
49607	}
49608	reqHeaders.Set("User-Agent", c.s.userAgent())
49609	if c.ifNoneMatch_ != "" {
49610		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49611	}
49612	var body io.Reader = nil
49613	c.urlParams_.Set("alt", alt)
49614	c.urlParams_.Set("prettyPrint", "false")
49615	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissionGroups/{id}")
49616	urls += "?" + c.urlParams_.Encode()
49617	req, err := http.NewRequest("GET", urls, body)
49618	if err != nil {
49619		return nil, err
49620	}
49621	req.Header = reqHeaders
49622	googleapi.Expand(req.URL, map[string]string{
49623		"profileId": strconv.FormatInt(c.profileId, 10),
49624		"id":        strconv.FormatInt(c.id, 10),
49625	})
49626	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49627}
49628
49629// Do executes the "dfareporting.userRolePermissionGroups.get" call.
49630// Exactly one of *UserRolePermissionGroup or error will be non-nil. Any
49631// non-2xx status code is an error. Response headers are in either
49632// *UserRolePermissionGroup.ServerResponse.Header or (if a response was
49633// returned at all) in error.(*googleapi.Error).Header. Use
49634// googleapi.IsNotModified to check whether the returned error was
49635// because http.StatusNotModified was returned.
49636func (c *UserRolePermissionGroupsGetCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionGroup, error) {
49637	gensupport.SetOptions(c.urlParams_, opts...)
49638	res, err := c.doRequest("json")
49639	if res != nil && res.StatusCode == http.StatusNotModified {
49640		if res.Body != nil {
49641			res.Body.Close()
49642		}
49643		return nil, &googleapi.Error{
49644			Code:   res.StatusCode,
49645			Header: res.Header,
49646		}
49647	}
49648	if err != nil {
49649		return nil, err
49650	}
49651	defer googleapi.CloseBody(res)
49652	if err := googleapi.CheckResponse(res); err != nil {
49653		return nil, err
49654	}
49655	ret := &UserRolePermissionGroup{
49656		ServerResponse: googleapi.ServerResponse{
49657			Header:         res.Header,
49658			HTTPStatusCode: res.StatusCode,
49659		},
49660	}
49661	target := &ret
49662	if err := gensupport.DecodeResponse(target, res); err != nil {
49663		return nil, err
49664	}
49665	return ret, nil
49666	// {
49667	//   "description": "Gets one user role permission group by ID.",
49668	//   "httpMethod": "GET",
49669	//   "id": "dfareporting.userRolePermissionGroups.get",
49670	//   "parameterOrder": [
49671	//     "profileId",
49672	//     "id"
49673	//   ],
49674	//   "parameters": {
49675	//     "id": {
49676	//       "description": "User role permission group ID.",
49677	//       "format": "int64",
49678	//       "location": "path",
49679	//       "required": true,
49680	//       "type": "string"
49681	//     },
49682	//     "profileId": {
49683	//       "description": "User profile ID associated with this request.",
49684	//       "format": "int64",
49685	//       "location": "path",
49686	//       "required": true,
49687	//       "type": "string"
49688	//     }
49689	//   },
49690	//   "path": "userprofiles/{profileId}/userRolePermissionGroups/{id}",
49691	//   "response": {
49692	//     "$ref": "UserRolePermissionGroup"
49693	//   },
49694	//   "scopes": [
49695	//     "https://www.googleapis.com/auth/dfatrafficking"
49696	//   ]
49697	// }
49698
49699}
49700
49701// method id "dfareporting.userRolePermissionGroups.list":
49702
49703type UserRolePermissionGroupsListCall struct {
49704	s            *Service
49705	profileId    int64
49706	urlParams_   gensupport.URLParams
49707	ifNoneMatch_ string
49708	ctx_         context.Context
49709	header_      http.Header
49710}
49711
49712// List: Gets a list of all supported user role permission groups.
49713func (r *UserRolePermissionGroupsService) List(profileId int64) *UserRolePermissionGroupsListCall {
49714	c := &UserRolePermissionGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49715	c.profileId = profileId
49716	return c
49717}
49718
49719// Fields allows partial responses to be retrieved. See
49720// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49721// for more information.
49722func (c *UserRolePermissionGroupsListCall) Fields(s ...googleapi.Field) *UserRolePermissionGroupsListCall {
49723	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49724	return c
49725}
49726
49727// IfNoneMatch sets the optional parameter which makes the operation
49728// fail if the object's ETag matches the given value. This is useful for
49729// getting updates only after the object has changed since the last
49730// request. Use googleapi.IsNotModified to check whether the response
49731// error from Do is the result of In-None-Match.
49732func (c *UserRolePermissionGroupsListCall) IfNoneMatch(entityTag string) *UserRolePermissionGroupsListCall {
49733	c.ifNoneMatch_ = entityTag
49734	return c
49735}
49736
49737// Context sets the context to be used in this call's Do method. Any
49738// pending HTTP request will be aborted if the provided context is
49739// canceled.
49740func (c *UserRolePermissionGroupsListCall) Context(ctx context.Context) *UserRolePermissionGroupsListCall {
49741	c.ctx_ = ctx
49742	return c
49743}
49744
49745// Header returns an http.Header that can be modified by the caller to
49746// add HTTP headers to the request.
49747func (c *UserRolePermissionGroupsListCall) Header() http.Header {
49748	if c.header_ == nil {
49749		c.header_ = make(http.Header)
49750	}
49751	return c.header_
49752}
49753
49754func (c *UserRolePermissionGroupsListCall) doRequest(alt string) (*http.Response, error) {
49755	reqHeaders := make(http.Header)
49756	for k, v := range c.header_ {
49757		reqHeaders[k] = v
49758	}
49759	reqHeaders.Set("User-Agent", c.s.userAgent())
49760	if c.ifNoneMatch_ != "" {
49761		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49762	}
49763	var body io.Reader = nil
49764	c.urlParams_.Set("alt", alt)
49765	c.urlParams_.Set("prettyPrint", "false")
49766	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissionGroups")
49767	urls += "?" + c.urlParams_.Encode()
49768	req, err := http.NewRequest("GET", urls, body)
49769	if err != nil {
49770		return nil, err
49771	}
49772	req.Header = reqHeaders
49773	googleapi.Expand(req.URL, map[string]string{
49774		"profileId": strconv.FormatInt(c.profileId, 10),
49775	})
49776	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49777}
49778
49779// Do executes the "dfareporting.userRolePermissionGroups.list" call.
49780// Exactly one of *UserRolePermissionGroupsListResponse or error will be
49781// non-nil. Any non-2xx status code is an error. Response headers are in
49782// either *UserRolePermissionGroupsListResponse.ServerResponse.Header or
49783// (if a response was returned at all) in
49784// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
49785// whether the returned error was because http.StatusNotModified was
49786// returned.
49787func (c *UserRolePermissionGroupsListCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionGroupsListResponse, error) {
49788	gensupport.SetOptions(c.urlParams_, opts...)
49789	res, err := c.doRequest("json")
49790	if res != nil && res.StatusCode == http.StatusNotModified {
49791		if res.Body != nil {
49792			res.Body.Close()
49793		}
49794		return nil, &googleapi.Error{
49795			Code:   res.StatusCode,
49796			Header: res.Header,
49797		}
49798	}
49799	if err != nil {
49800		return nil, err
49801	}
49802	defer googleapi.CloseBody(res)
49803	if err := googleapi.CheckResponse(res); err != nil {
49804		return nil, err
49805	}
49806	ret := &UserRolePermissionGroupsListResponse{
49807		ServerResponse: googleapi.ServerResponse{
49808			Header:         res.Header,
49809			HTTPStatusCode: res.StatusCode,
49810		},
49811	}
49812	target := &ret
49813	if err := gensupport.DecodeResponse(target, res); err != nil {
49814		return nil, err
49815	}
49816	return ret, nil
49817	// {
49818	//   "description": "Gets a list of all supported user role permission groups.",
49819	//   "httpMethod": "GET",
49820	//   "id": "dfareporting.userRolePermissionGroups.list",
49821	//   "parameterOrder": [
49822	//     "profileId"
49823	//   ],
49824	//   "parameters": {
49825	//     "profileId": {
49826	//       "description": "User profile ID associated with this request.",
49827	//       "format": "int64",
49828	//       "location": "path",
49829	//       "required": true,
49830	//       "type": "string"
49831	//     }
49832	//   },
49833	//   "path": "userprofiles/{profileId}/userRolePermissionGroups",
49834	//   "response": {
49835	//     "$ref": "UserRolePermissionGroupsListResponse"
49836	//   },
49837	//   "scopes": [
49838	//     "https://www.googleapis.com/auth/dfatrafficking"
49839	//   ]
49840	// }
49841
49842}
49843
49844// method id "dfareporting.userRolePermissions.get":
49845
49846type UserRolePermissionsGetCall struct {
49847	s            *Service
49848	profileId    int64
49849	id           int64
49850	urlParams_   gensupport.URLParams
49851	ifNoneMatch_ string
49852	ctx_         context.Context
49853	header_      http.Header
49854}
49855
49856// Get: Gets one user role permission by ID.
49857func (r *UserRolePermissionsService) Get(profileId int64, id int64) *UserRolePermissionsGetCall {
49858	c := &UserRolePermissionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49859	c.profileId = profileId
49860	c.id = id
49861	return c
49862}
49863
49864// Fields allows partial responses to be retrieved. See
49865// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49866// for more information.
49867func (c *UserRolePermissionsGetCall) Fields(s ...googleapi.Field) *UserRolePermissionsGetCall {
49868	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49869	return c
49870}
49871
49872// IfNoneMatch sets the optional parameter which makes the operation
49873// fail if the object's ETag matches the given value. This is useful for
49874// getting updates only after the object has changed since the last
49875// request. Use googleapi.IsNotModified to check whether the response
49876// error from Do is the result of In-None-Match.
49877func (c *UserRolePermissionsGetCall) IfNoneMatch(entityTag string) *UserRolePermissionsGetCall {
49878	c.ifNoneMatch_ = entityTag
49879	return c
49880}
49881
49882// Context sets the context to be used in this call's Do method. Any
49883// pending HTTP request will be aborted if the provided context is
49884// canceled.
49885func (c *UserRolePermissionsGetCall) Context(ctx context.Context) *UserRolePermissionsGetCall {
49886	c.ctx_ = ctx
49887	return c
49888}
49889
49890// Header returns an http.Header that can be modified by the caller to
49891// add HTTP headers to the request.
49892func (c *UserRolePermissionsGetCall) Header() http.Header {
49893	if c.header_ == nil {
49894		c.header_ = make(http.Header)
49895	}
49896	return c.header_
49897}
49898
49899func (c *UserRolePermissionsGetCall) doRequest(alt string) (*http.Response, error) {
49900	reqHeaders := make(http.Header)
49901	for k, v := range c.header_ {
49902		reqHeaders[k] = v
49903	}
49904	reqHeaders.Set("User-Agent", c.s.userAgent())
49905	if c.ifNoneMatch_ != "" {
49906		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49907	}
49908	var body io.Reader = nil
49909	c.urlParams_.Set("alt", alt)
49910	c.urlParams_.Set("prettyPrint", "false")
49911	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissions/{id}")
49912	urls += "?" + c.urlParams_.Encode()
49913	req, err := http.NewRequest("GET", urls, body)
49914	if err != nil {
49915		return nil, err
49916	}
49917	req.Header = reqHeaders
49918	googleapi.Expand(req.URL, map[string]string{
49919		"profileId": strconv.FormatInt(c.profileId, 10),
49920		"id":        strconv.FormatInt(c.id, 10),
49921	})
49922	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49923}
49924
49925// Do executes the "dfareporting.userRolePermissions.get" call.
49926// Exactly one of *UserRolePermission or error will be non-nil. Any
49927// non-2xx status code is an error. Response headers are in either
49928// *UserRolePermission.ServerResponse.Header or (if a response was
49929// returned at all) in error.(*googleapi.Error).Header. Use
49930// googleapi.IsNotModified to check whether the returned error was
49931// because http.StatusNotModified was returned.
49932func (c *UserRolePermissionsGetCall) Do(opts ...googleapi.CallOption) (*UserRolePermission, error) {
49933	gensupport.SetOptions(c.urlParams_, opts...)
49934	res, err := c.doRequest("json")
49935	if res != nil && res.StatusCode == http.StatusNotModified {
49936		if res.Body != nil {
49937			res.Body.Close()
49938		}
49939		return nil, &googleapi.Error{
49940			Code:   res.StatusCode,
49941			Header: res.Header,
49942		}
49943	}
49944	if err != nil {
49945		return nil, err
49946	}
49947	defer googleapi.CloseBody(res)
49948	if err := googleapi.CheckResponse(res); err != nil {
49949		return nil, err
49950	}
49951	ret := &UserRolePermission{
49952		ServerResponse: googleapi.ServerResponse{
49953			Header:         res.Header,
49954			HTTPStatusCode: res.StatusCode,
49955		},
49956	}
49957	target := &ret
49958	if err := gensupport.DecodeResponse(target, res); err != nil {
49959		return nil, err
49960	}
49961	return ret, nil
49962	// {
49963	//   "description": "Gets one user role permission by ID.",
49964	//   "httpMethod": "GET",
49965	//   "id": "dfareporting.userRolePermissions.get",
49966	//   "parameterOrder": [
49967	//     "profileId",
49968	//     "id"
49969	//   ],
49970	//   "parameters": {
49971	//     "id": {
49972	//       "description": "User role permission ID.",
49973	//       "format": "int64",
49974	//       "location": "path",
49975	//       "required": true,
49976	//       "type": "string"
49977	//     },
49978	//     "profileId": {
49979	//       "description": "User profile ID associated with this request.",
49980	//       "format": "int64",
49981	//       "location": "path",
49982	//       "required": true,
49983	//       "type": "string"
49984	//     }
49985	//   },
49986	//   "path": "userprofiles/{profileId}/userRolePermissions/{id}",
49987	//   "response": {
49988	//     "$ref": "UserRolePermission"
49989	//   },
49990	//   "scopes": [
49991	//     "https://www.googleapis.com/auth/dfatrafficking"
49992	//   ]
49993	// }
49994
49995}
49996
49997// method id "dfareporting.userRolePermissions.list":
49998
49999type UserRolePermissionsListCall struct {
50000	s            *Service
50001	profileId    int64
50002	urlParams_   gensupport.URLParams
50003	ifNoneMatch_ string
50004	ctx_         context.Context
50005	header_      http.Header
50006}
50007
50008// List: Gets a list of user role permissions, possibly filtered.
50009func (r *UserRolePermissionsService) List(profileId int64) *UserRolePermissionsListCall {
50010	c := &UserRolePermissionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50011	c.profileId = profileId
50012	return c
50013}
50014
50015// Ids sets the optional parameter "ids": Select only user role
50016// permissions with these IDs.
50017func (c *UserRolePermissionsListCall) Ids(ids ...int64) *UserRolePermissionsListCall {
50018	var ids_ []string
50019	for _, v := range ids {
50020		ids_ = append(ids_, fmt.Sprint(v))
50021	}
50022	c.urlParams_.SetMulti("ids", ids_)
50023	return c
50024}
50025
50026// Fields allows partial responses to be retrieved. See
50027// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50028// for more information.
50029func (c *UserRolePermissionsListCall) Fields(s ...googleapi.Field) *UserRolePermissionsListCall {
50030	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50031	return c
50032}
50033
50034// IfNoneMatch sets the optional parameter which makes the operation
50035// fail if the object's ETag matches the given value. This is useful for
50036// getting updates only after the object has changed since the last
50037// request. Use googleapi.IsNotModified to check whether the response
50038// error from Do is the result of In-None-Match.
50039func (c *UserRolePermissionsListCall) IfNoneMatch(entityTag string) *UserRolePermissionsListCall {
50040	c.ifNoneMatch_ = entityTag
50041	return c
50042}
50043
50044// Context sets the context to be used in this call's Do method. Any
50045// pending HTTP request will be aborted if the provided context is
50046// canceled.
50047func (c *UserRolePermissionsListCall) Context(ctx context.Context) *UserRolePermissionsListCall {
50048	c.ctx_ = ctx
50049	return c
50050}
50051
50052// Header returns an http.Header that can be modified by the caller to
50053// add HTTP headers to the request.
50054func (c *UserRolePermissionsListCall) Header() http.Header {
50055	if c.header_ == nil {
50056		c.header_ = make(http.Header)
50057	}
50058	return c.header_
50059}
50060
50061func (c *UserRolePermissionsListCall) doRequest(alt string) (*http.Response, error) {
50062	reqHeaders := make(http.Header)
50063	for k, v := range c.header_ {
50064		reqHeaders[k] = v
50065	}
50066	reqHeaders.Set("User-Agent", c.s.userAgent())
50067	if c.ifNoneMatch_ != "" {
50068		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50069	}
50070	var body io.Reader = nil
50071	c.urlParams_.Set("alt", alt)
50072	c.urlParams_.Set("prettyPrint", "false")
50073	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissions")
50074	urls += "?" + c.urlParams_.Encode()
50075	req, err := http.NewRequest("GET", urls, body)
50076	if err != nil {
50077		return nil, err
50078	}
50079	req.Header = reqHeaders
50080	googleapi.Expand(req.URL, map[string]string{
50081		"profileId": strconv.FormatInt(c.profileId, 10),
50082	})
50083	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50084}
50085
50086// Do executes the "dfareporting.userRolePermissions.list" call.
50087// Exactly one of *UserRolePermissionsListResponse or error will be
50088// non-nil. Any non-2xx status code is an error. Response headers are in
50089// either *UserRolePermissionsListResponse.ServerResponse.Header or (if
50090// a response was returned at all) in error.(*googleapi.Error).Header.
50091// Use googleapi.IsNotModified to check whether the returned error was
50092// because http.StatusNotModified was returned.
50093func (c *UserRolePermissionsListCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionsListResponse, error) {
50094	gensupport.SetOptions(c.urlParams_, opts...)
50095	res, err := c.doRequest("json")
50096	if res != nil && res.StatusCode == http.StatusNotModified {
50097		if res.Body != nil {
50098			res.Body.Close()
50099		}
50100		return nil, &googleapi.Error{
50101			Code:   res.StatusCode,
50102			Header: res.Header,
50103		}
50104	}
50105	if err != nil {
50106		return nil, err
50107	}
50108	defer googleapi.CloseBody(res)
50109	if err := googleapi.CheckResponse(res); err != nil {
50110		return nil, err
50111	}
50112	ret := &UserRolePermissionsListResponse{
50113		ServerResponse: googleapi.ServerResponse{
50114			Header:         res.Header,
50115			HTTPStatusCode: res.StatusCode,
50116		},
50117	}
50118	target := &ret
50119	if err := gensupport.DecodeResponse(target, res); err != nil {
50120		return nil, err
50121	}
50122	return ret, nil
50123	// {
50124	//   "description": "Gets a list of user role permissions, possibly filtered.",
50125	//   "httpMethod": "GET",
50126	//   "id": "dfareporting.userRolePermissions.list",
50127	//   "parameterOrder": [
50128	//     "profileId"
50129	//   ],
50130	//   "parameters": {
50131	//     "ids": {
50132	//       "description": "Select only user role permissions with these IDs.",
50133	//       "format": "int64",
50134	//       "location": "query",
50135	//       "repeated": true,
50136	//       "type": "string"
50137	//     },
50138	//     "profileId": {
50139	//       "description": "User profile ID associated with this request.",
50140	//       "format": "int64",
50141	//       "location": "path",
50142	//       "required": true,
50143	//       "type": "string"
50144	//     }
50145	//   },
50146	//   "path": "userprofiles/{profileId}/userRolePermissions",
50147	//   "response": {
50148	//     "$ref": "UserRolePermissionsListResponse"
50149	//   },
50150	//   "scopes": [
50151	//     "https://www.googleapis.com/auth/dfatrafficking"
50152	//   ]
50153	// }
50154
50155}
50156
50157// method id "dfareporting.userRoles.delete":
50158
50159type UserRolesDeleteCall struct {
50160	s          *Service
50161	profileId  int64
50162	id         int64
50163	urlParams_ gensupport.URLParams
50164	ctx_       context.Context
50165	header_    http.Header
50166}
50167
50168// Delete: Deletes an existing user role.
50169func (r *UserRolesService) Delete(profileId int64, id int64) *UserRolesDeleteCall {
50170	c := &UserRolesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50171	c.profileId = profileId
50172	c.id = id
50173	return c
50174}
50175
50176// Fields allows partial responses to be retrieved. See
50177// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50178// for more information.
50179func (c *UserRolesDeleteCall) Fields(s ...googleapi.Field) *UserRolesDeleteCall {
50180	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50181	return c
50182}
50183
50184// Context sets the context to be used in this call's Do method. Any
50185// pending HTTP request will be aborted if the provided context is
50186// canceled.
50187func (c *UserRolesDeleteCall) Context(ctx context.Context) *UserRolesDeleteCall {
50188	c.ctx_ = ctx
50189	return c
50190}
50191
50192// Header returns an http.Header that can be modified by the caller to
50193// add HTTP headers to the request.
50194func (c *UserRolesDeleteCall) Header() http.Header {
50195	if c.header_ == nil {
50196		c.header_ = make(http.Header)
50197	}
50198	return c.header_
50199}
50200
50201func (c *UserRolesDeleteCall) doRequest(alt string) (*http.Response, error) {
50202	reqHeaders := make(http.Header)
50203	for k, v := range c.header_ {
50204		reqHeaders[k] = v
50205	}
50206	reqHeaders.Set("User-Agent", c.s.userAgent())
50207	var body io.Reader = nil
50208	c.urlParams_.Set("alt", alt)
50209	c.urlParams_.Set("prettyPrint", "false")
50210	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles/{id}")
50211	urls += "?" + c.urlParams_.Encode()
50212	req, err := http.NewRequest("DELETE", urls, body)
50213	if err != nil {
50214		return nil, err
50215	}
50216	req.Header = reqHeaders
50217	googleapi.Expand(req.URL, map[string]string{
50218		"profileId": strconv.FormatInt(c.profileId, 10),
50219		"id":        strconv.FormatInt(c.id, 10),
50220	})
50221	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50222}
50223
50224// Do executes the "dfareporting.userRoles.delete" call.
50225func (c *UserRolesDeleteCall) Do(opts ...googleapi.CallOption) error {
50226	gensupport.SetOptions(c.urlParams_, opts...)
50227	res, err := c.doRequest("json")
50228	if err != nil {
50229		return err
50230	}
50231	defer googleapi.CloseBody(res)
50232	if err := googleapi.CheckResponse(res); err != nil {
50233		return err
50234	}
50235	return nil
50236	// {
50237	//   "description": "Deletes an existing user role.",
50238	//   "httpMethod": "DELETE",
50239	//   "id": "dfareporting.userRoles.delete",
50240	//   "parameterOrder": [
50241	//     "profileId",
50242	//     "id"
50243	//   ],
50244	//   "parameters": {
50245	//     "id": {
50246	//       "description": "User role ID.",
50247	//       "format": "int64",
50248	//       "location": "path",
50249	//       "required": true,
50250	//       "type": "string"
50251	//     },
50252	//     "profileId": {
50253	//       "description": "User profile ID associated with this request.",
50254	//       "format": "int64",
50255	//       "location": "path",
50256	//       "required": true,
50257	//       "type": "string"
50258	//     }
50259	//   },
50260	//   "path": "userprofiles/{profileId}/userRoles/{id}",
50261	//   "scopes": [
50262	//     "https://www.googleapis.com/auth/dfatrafficking"
50263	//   ]
50264	// }
50265
50266}
50267
50268// method id "dfareporting.userRoles.get":
50269
50270type UserRolesGetCall struct {
50271	s            *Service
50272	profileId    int64
50273	id           int64
50274	urlParams_   gensupport.URLParams
50275	ifNoneMatch_ string
50276	ctx_         context.Context
50277	header_      http.Header
50278}
50279
50280// Get: Gets one user role by ID.
50281func (r *UserRolesService) Get(profileId int64, id int64) *UserRolesGetCall {
50282	c := &UserRolesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50283	c.profileId = profileId
50284	c.id = id
50285	return c
50286}
50287
50288// Fields allows partial responses to be retrieved. See
50289// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50290// for more information.
50291func (c *UserRolesGetCall) Fields(s ...googleapi.Field) *UserRolesGetCall {
50292	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50293	return c
50294}
50295
50296// IfNoneMatch sets the optional parameter which makes the operation
50297// fail if the object's ETag matches the given value. This is useful for
50298// getting updates only after the object has changed since the last
50299// request. Use googleapi.IsNotModified to check whether the response
50300// error from Do is the result of In-None-Match.
50301func (c *UserRolesGetCall) IfNoneMatch(entityTag string) *UserRolesGetCall {
50302	c.ifNoneMatch_ = entityTag
50303	return c
50304}
50305
50306// Context sets the context to be used in this call's Do method. Any
50307// pending HTTP request will be aborted if the provided context is
50308// canceled.
50309func (c *UserRolesGetCall) Context(ctx context.Context) *UserRolesGetCall {
50310	c.ctx_ = ctx
50311	return c
50312}
50313
50314// Header returns an http.Header that can be modified by the caller to
50315// add HTTP headers to the request.
50316func (c *UserRolesGetCall) Header() http.Header {
50317	if c.header_ == nil {
50318		c.header_ = make(http.Header)
50319	}
50320	return c.header_
50321}
50322
50323func (c *UserRolesGetCall) doRequest(alt string) (*http.Response, error) {
50324	reqHeaders := make(http.Header)
50325	for k, v := range c.header_ {
50326		reqHeaders[k] = v
50327	}
50328	reqHeaders.Set("User-Agent", c.s.userAgent())
50329	if c.ifNoneMatch_ != "" {
50330		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50331	}
50332	var body io.Reader = nil
50333	c.urlParams_.Set("alt", alt)
50334	c.urlParams_.Set("prettyPrint", "false")
50335	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles/{id}")
50336	urls += "?" + c.urlParams_.Encode()
50337	req, err := http.NewRequest("GET", urls, body)
50338	if err != nil {
50339		return nil, err
50340	}
50341	req.Header = reqHeaders
50342	googleapi.Expand(req.URL, map[string]string{
50343		"profileId": strconv.FormatInt(c.profileId, 10),
50344		"id":        strconv.FormatInt(c.id, 10),
50345	})
50346	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50347}
50348
50349// Do executes the "dfareporting.userRoles.get" call.
50350// Exactly one of *UserRole or error will be non-nil. Any non-2xx status
50351// code is an error. Response headers are in either
50352// *UserRole.ServerResponse.Header or (if a response was returned at
50353// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
50354// to check whether the returned error was because
50355// http.StatusNotModified was returned.
50356func (c *UserRolesGetCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50357	gensupport.SetOptions(c.urlParams_, opts...)
50358	res, err := c.doRequest("json")
50359	if res != nil && res.StatusCode == http.StatusNotModified {
50360		if res.Body != nil {
50361			res.Body.Close()
50362		}
50363		return nil, &googleapi.Error{
50364			Code:   res.StatusCode,
50365			Header: res.Header,
50366		}
50367	}
50368	if err != nil {
50369		return nil, err
50370	}
50371	defer googleapi.CloseBody(res)
50372	if err := googleapi.CheckResponse(res); err != nil {
50373		return nil, err
50374	}
50375	ret := &UserRole{
50376		ServerResponse: googleapi.ServerResponse{
50377			Header:         res.Header,
50378			HTTPStatusCode: res.StatusCode,
50379		},
50380	}
50381	target := &ret
50382	if err := gensupport.DecodeResponse(target, res); err != nil {
50383		return nil, err
50384	}
50385	return ret, nil
50386	// {
50387	//   "description": "Gets one user role by ID.",
50388	//   "httpMethod": "GET",
50389	//   "id": "dfareporting.userRoles.get",
50390	//   "parameterOrder": [
50391	//     "profileId",
50392	//     "id"
50393	//   ],
50394	//   "parameters": {
50395	//     "id": {
50396	//       "description": "User role ID.",
50397	//       "format": "int64",
50398	//       "location": "path",
50399	//       "required": true,
50400	//       "type": "string"
50401	//     },
50402	//     "profileId": {
50403	//       "description": "User profile ID associated with this request.",
50404	//       "format": "int64",
50405	//       "location": "path",
50406	//       "required": true,
50407	//       "type": "string"
50408	//     }
50409	//   },
50410	//   "path": "userprofiles/{profileId}/userRoles/{id}",
50411	//   "response": {
50412	//     "$ref": "UserRole"
50413	//   },
50414	//   "scopes": [
50415	//     "https://www.googleapis.com/auth/dfatrafficking"
50416	//   ]
50417	// }
50418
50419}
50420
50421// method id "dfareporting.userRoles.insert":
50422
50423type UserRolesInsertCall struct {
50424	s          *Service
50425	profileId  int64
50426	userrole   *UserRole
50427	urlParams_ gensupport.URLParams
50428	ctx_       context.Context
50429	header_    http.Header
50430}
50431
50432// Insert: Inserts a new user role.
50433func (r *UserRolesService) Insert(profileId int64, userrole *UserRole) *UserRolesInsertCall {
50434	c := &UserRolesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50435	c.profileId = profileId
50436	c.userrole = userrole
50437	return c
50438}
50439
50440// Fields allows partial responses to be retrieved. See
50441// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50442// for more information.
50443func (c *UserRolesInsertCall) Fields(s ...googleapi.Field) *UserRolesInsertCall {
50444	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50445	return c
50446}
50447
50448// Context sets the context to be used in this call's Do method. Any
50449// pending HTTP request will be aborted if the provided context is
50450// canceled.
50451func (c *UserRolesInsertCall) Context(ctx context.Context) *UserRolesInsertCall {
50452	c.ctx_ = ctx
50453	return c
50454}
50455
50456// Header returns an http.Header that can be modified by the caller to
50457// add HTTP headers to the request.
50458func (c *UserRolesInsertCall) Header() http.Header {
50459	if c.header_ == nil {
50460		c.header_ = make(http.Header)
50461	}
50462	return c.header_
50463}
50464
50465func (c *UserRolesInsertCall) doRequest(alt string) (*http.Response, error) {
50466	reqHeaders := make(http.Header)
50467	for k, v := range c.header_ {
50468		reqHeaders[k] = v
50469	}
50470	reqHeaders.Set("User-Agent", c.s.userAgent())
50471	var body io.Reader = nil
50472	body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
50473	if err != nil {
50474		return nil, err
50475	}
50476	reqHeaders.Set("Content-Type", "application/json")
50477	c.urlParams_.Set("alt", alt)
50478	c.urlParams_.Set("prettyPrint", "false")
50479	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
50480	urls += "?" + c.urlParams_.Encode()
50481	req, err := http.NewRequest("POST", urls, body)
50482	if err != nil {
50483		return nil, err
50484	}
50485	req.Header = reqHeaders
50486	googleapi.Expand(req.URL, map[string]string{
50487		"profileId": strconv.FormatInt(c.profileId, 10),
50488	})
50489	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50490}
50491
50492// Do executes the "dfareporting.userRoles.insert" call.
50493// Exactly one of *UserRole or error will be non-nil. Any non-2xx status
50494// code is an error. Response headers are in either
50495// *UserRole.ServerResponse.Header or (if a response was returned at
50496// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
50497// to check whether the returned error was because
50498// http.StatusNotModified was returned.
50499func (c *UserRolesInsertCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50500	gensupport.SetOptions(c.urlParams_, opts...)
50501	res, err := c.doRequest("json")
50502	if res != nil && res.StatusCode == http.StatusNotModified {
50503		if res.Body != nil {
50504			res.Body.Close()
50505		}
50506		return nil, &googleapi.Error{
50507			Code:   res.StatusCode,
50508			Header: res.Header,
50509		}
50510	}
50511	if err != nil {
50512		return nil, err
50513	}
50514	defer googleapi.CloseBody(res)
50515	if err := googleapi.CheckResponse(res); err != nil {
50516		return nil, err
50517	}
50518	ret := &UserRole{
50519		ServerResponse: googleapi.ServerResponse{
50520			Header:         res.Header,
50521			HTTPStatusCode: res.StatusCode,
50522		},
50523	}
50524	target := &ret
50525	if err := gensupport.DecodeResponse(target, res); err != nil {
50526		return nil, err
50527	}
50528	return ret, nil
50529	// {
50530	//   "description": "Inserts a new user role.",
50531	//   "httpMethod": "POST",
50532	//   "id": "dfareporting.userRoles.insert",
50533	//   "parameterOrder": [
50534	//     "profileId"
50535	//   ],
50536	//   "parameters": {
50537	//     "profileId": {
50538	//       "description": "User profile ID associated with this request.",
50539	//       "format": "int64",
50540	//       "location": "path",
50541	//       "required": true,
50542	//       "type": "string"
50543	//     }
50544	//   },
50545	//   "path": "userprofiles/{profileId}/userRoles",
50546	//   "request": {
50547	//     "$ref": "UserRole"
50548	//   },
50549	//   "response": {
50550	//     "$ref": "UserRole"
50551	//   },
50552	//   "scopes": [
50553	//     "https://www.googleapis.com/auth/dfatrafficking"
50554	//   ]
50555	// }
50556
50557}
50558
50559// method id "dfareporting.userRoles.list":
50560
50561type UserRolesListCall struct {
50562	s            *Service
50563	profileId    int64
50564	urlParams_   gensupport.URLParams
50565	ifNoneMatch_ string
50566	ctx_         context.Context
50567	header_      http.Header
50568}
50569
50570// List: Retrieves a list of user roles, possibly filtered. This method
50571// supports paging.
50572func (r *UserRolesService) List(profileId int64) *UserRolesListCall {
50573	c := &UserRolesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50574	c.profileId = profileId
50575	return c
50576}
50577
50578// AccountUserRoleOnly sets the optional parameter
50579// "accountUserRoleOnly": Select only account level user roles not
50580// associated with any specific subaccount.
50581func (c *UserRolesListCall) AccountUserRoleOnly(accountUserRoleOnly bool) *UserRolesListCall {
50582	c.urlParams_.Set("accountUserRoleOnly", fmt.Sprint(accountUserRoleOnly))
50583	return c
50584}
50585
50586// Ids sets the optional parameter "ids": Select only user roles with
50587// the specified IDs.
50588func (c *UserRolesListCall) Ids(ids ...int64) *UserRolesListCall {
50589	var ids_ []string
50590	for _, v := range ids {
50591		ids_ = append(ids_, fmt.Sprint(v))
50592	}
50593	c.urlParams_.SetMulti("ids", ids_)
50594	return c
50595}
50596
50597// MaxResults sets the optional parameter "maxResults": Maximum number
50598// of results to return.
50599func (c *UserRolesListCall) MaxResults(maxResults int64) *UserRolesListCall {
50600	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
50601	return c
50602}
50603
50604// PageToken sets the optional parameter "pageToken": Value of the
50605// nextPageToken from the previous result page.
50606func (c *UserRolesListCall) PageToken(pageToken string) *UserRolesListCall {
50607	c.urlParams_.Set("pageToken", pageToken)
50608	return c
50609}
50610
50611// SearchString sets the optional parameter "searchString": Allows
50612// searching for objects by name or ID. Wildcards (*) are allowed. For
50613// example, "userrole*2015" will return objects with names like
50614// "userrole June 2015", "userrole April 2015", or simply "userrole
50615// 2015". Most of the searches also add wildcards implicitly at the
50616// start and the end of the search string. For example, a search string
50617// of "userrole" will match objects with name "my userrole", "userrole
50618// 2015", or simply "userrole".
50619func (c *UserRolesListCall) SearchString(searchString string) *UserRolesListCall {
50620	c.urlParams_.Set("searchString", searchString)
50621	return c
50622}
50623
50624// SortField sets the optional parameter "sortField": Field by which to
50625// sort the list.
50626//
50627// Possible values:
50628//   "ID" (default)
50629//   "NAME"
50630func (c *UserRolesListCall) SortField(sortField string) *UserRolesListCall {
50631	c.urlParams_.Set("sortField", sortField)
50632	return c
50633}
50634
50635// SortOrder sets the optional parameter "sortOrder": Order of sorted
50636// results.
50637//
50638// Possible values:
50639//   "ASCENDING" (default)
50640//   "DESCENDING"
50641func (c *UserRolesListCall) SortOrder(sortOrder string) *UserRolesListCall {
50642	c.urlParams_.Set("sortOrder", sortOrder)
50643	return c
50644}
50645
50646// SubaccountId sets the optional parameter "subaccountId": Select only
50647// user roles that belong to this subaccount.
50648func (c *UserRolesListCall) SubaccountId(subaccountId int64) *UserRolesListCall {
50649	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
50650	return c
50651}
50652
50653// Fields allows partial responses to be retrieved. See
50654// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50655// for more information.
50656func (c *UserRolesListCall) Fields(s ...googleapi.Field) *UserRolesListCall {
50657	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50658	return c
50659}
50660
50661// IfNoneMatch sets the optional parameter which makes the operation
50662// fail if the object's ETag matches the given value. This is useful for
50663// getting updates only after the object has changed since the last
50664// request. Use googleapi.IsNotModified to check whether the response
50665// error from Do is the result of In-None-Match.
50666func (c *UserRolesListCall) IfNoneMatch(entityTag string) *UserRolesListCall {
50667	c.ifNoneMatch_ = entityTag
50668	return c
50669}
50670
50671// Context sets the context to be used in this call's Do method. Any
50672// pending HTTP request will be aborted if the provided context is
50673// canceled.
50674func (c *UserRolesListCall) Context(ctx context.Context) *UserRolesListCall {
50675	c.ctx_ = ctx
50676	return c
50677}
50678
50679// Header returns an http.Header that can be modified by the caller to
50680// add HTTP headers to the request.
50681func (c *UserRolesListCall) Header() http.Header {
50682	if c.header_ == nil {
50683		c.header_ = make(http.Header)
50684	}
50685	return c.header_
50686}
50687
50688func (c *UserRolesListCall) doRequest(alt string) (*http.Response, error) {
50689	reqHeaders := make(http.Header)
50690	for k, v := range c.header_ {
50691		reqHeaders[k] = v
50692	}
50693	reqHeaders.Set("User-Agent", c.s.userAgent())
50694	if c.ifNoneMatch_ != "" {
50695		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50696	}
50697	var body io.Reader = nil
50698	c.urlParams_.Set("alt", alt)
50699	c.urlParams_.Set("prettyPrint", "false")
50700	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
50701	urls += "?" + c.urlParams_.Encode()
50702	req, err := http.NewRequest("GET", urls, body)
50703	if err != nil {
50704		return nil, err
50705	}
50706	req.Header = reqHeaders
50707	googleapi.Expand(req.URL, map[string]string{
50708		"profileId": strconv.FormatInt(c.profileId, 10),
50709	})
50710	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50711}
50712
50713// Do executes the "dfareporting.userRoles.list" call.
50714// Exactly one of *UserRolesListResponse or error will be non-nil. Any
50715// non-2xx status code is an error. Response headers are in either
50716// *UserRolesListResponse.ServerResponse.Header or (if a response was
50717// returned at all) in error.(*googleapi.Error).Header. Use
50718// googleapi.IsNotModified to check whether the returned error was
50719// because http.StatusNotModified was returned.
50720func (c *UserRolesListCall) Do(opts ...googleapi.CallOption) (*UserRolesListResponse, error) {
50721	gensupport.SetOptions(c.urlParams_, opts...)
50722	res, err := c.doRequest("json")
50723	if res != nil && res.StatusCode == http.StatusNotModified {
50724		if res.Body != nil {
50725			res.Body.Close()
50726		}
50727		return nil, &googleapi.Error{
50728			Code:   res.StatusCode,
50729			Header: res.Header,
50730		}
50731	}
50732	if err != nil {
50733		return nil, err
50734	}
50735	defer googleapi.CloseBody(res)
50736	if err := googleapi.CheckResponse(res); err != nil {
50737		return nil, err
50738	}
50739	ret := &UserRolesListResponse{
50740		ServerResponse: googleapi.ServerResponse{
50741			Header:         res.Header,
50742			HTTPStatusCode: res.StatusCode,
50743		},
50744	}
50745	target := &ret
50746	if err := gensupport.DecodeResponse(target, res); err != nil {
50747		return nil, err
50748	}
50749	return ret, nil
50750	// {
50751	//   "description": "Retrieves a list of user roles, possibly filtered. This method supports paging.",
50752	//   "httpMethod": "GET",
50753	//   "id": "dfareporting.userRoles.list",
50754	//   "parameterOrder": [
50755	//     "profileId"
50756	//   ],
50757	//   "parameters": {
50758	//     "accountUserRoleOnly": {
50759	//       "description": "Select only account level user roles not associated with any specific subaccount.",
50760	//       "location": "query",
50761	//       "type": "boolean"
50762	//     },
50763	//     "ids": {
50764	//       "description": "Select only user roles with the specified IDs.",
50765	//       "format": "int64",
50766	//       "location": "query",
50767	//       "repeated": true,
50768	//       "type": "string"
50769	//     },
50770	//     "maxResults": {
50771	//       "default": "1000",
50772	//       "description": "Maximum number of results to return.",
50773	//       "format": "int32",
50774	//       "location": "query",
50775	//       "maximum": "1000",
50776	//       "minimum": "0",
50777	//       "type": "integer"
50778	//     },
50779	//     "pageToken": {
50780	//       "description": "Value of the nextPageToken from the previous result page.",
50781	//       "location": "query",
50782	//       "type": "string"
50783	//     },
50784	//     "profileId": {
50785	//       "description": "User profile ID associated with this request.",
50786	//       "format": "int64",
50787	//       "location": "path",
50788	//       "required": true,
50789	//       "type": "string"
50790	//     },
50791	//     "searchString": {
50792	//       "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\".",
50793	//       "location": "query",
50794	//       "type": "string"
50795	//     },
50796	//     "sortField": {
50797	//       "default": "ID",
50798	//       "description": "Field by which to sort the list.",
50799	//       "enum": [
50800	//         "ID",
50801	//         "NAME"
50802	//       ],
50803	//       "enumDescriptions": [
50804	//         "",
50805	//         ""
50806	//       ],
50807	//       "location": "query",
50808	//       "type": "string"
50809	//     },
50810	//     "sortOrder": {
50811	//       "default": "ASCENDING",
50812	//       "description": "Order of sorted results.",
50813	//       "enum": [
50814	//         "ASCENDING",
50815	//         "DESCENDING"
50816	//       ],
50817	//       "enumDescriptions": [
50818	//         "",
50819	//         ""
50820	//       ],
50821	//       "location": "query",
50822	//       "type": "string"
50823	//     },
50824	//     "subaccountId": {
50825	//       "description": "Select only user roles that belong to this subaccount.",
50826	//       "format": "int64",
50827	//       "location": "query",
50828	//       "type": "string"
50829	//     }
50830	//   },
50831	//   "path": "userprofiles/{profileId}/userRoles",
50832	//   "response": {
50833	//     "$ref": "UserRolesListResponse"
50834	//   },
50835	//   "scopes": [
50836	//     "https://www.googleapis.com/auth/dfatrafficking"
50837	//   ]
50838	// }
50839
50840}
50841
50842// Pages invokes f for each page of results.
50843// A non-nil error returned from f will halt the iteration.
50844// The provided context supersedes any context provided to the Context method.
50845func (c *UserRolesListCall) Pages(ctx context.Context, f func(*UserRolesListResponse) error) error {
50846	c.ctx_ = ctx
50847	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
50848	for {
50849		x, err := c.Do()
50850		if err != nil {
50851			return err
50852		}
50853		if err := f(x); err != nil {
50854			return err
50855		}
50856		if x.NextPageToken == "" {
50857			return nil
50858		}
50859		c.PageToken(x.NextPageToken)
50860	}
50861}
50862
50863// method id "dfareporting.userRoles.patch":
50864
50865type UserRolesPatchCall struct {
50866	s          *Service
50867	profileId  int64
50868	userrole   *UserRole
50869	urlParams_ gensupport.URLParams
50870	ctx_       context.Context
50871	header_    http.Header
50872}
50873
50874// Patch: Updates an existing user role. This method supports patch
50875// semantics.
50876func (r *UserRolesService) Patch(profileId int64, id int64, userrole *UserRole) *UserRolesPatchCall {
50877	c := &UserRolesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50878	c.profileId = profileId
50879	c.urlParams_.Set("id", fmt.Sprint(id))
50880	c.userrole = userrole
50881	return c
50882}
50883
50884// Fields allows partial responses to be retrieved. See
50885// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50886// for more information.
50887func (c *UserRolesPatchCall) Fields(s ...googleapi.Field) *UserRolesPatchCall {
50888	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50889	return c
50890}
50891
50892// Context sets the context to be used in this call's Do method. Any
50893// pending HTTP request will be aborted if the provided context is
50894// canceled.
50895func (c *UserRolesPatchCall) Context(ctx context.Context) *UserRolesPatchCall {
50896	c.ctx_ = ctx
50897	return c
50898}
50899
50900// Header returns an http.Header that can be modified by the caller to
50901// add HTTP headers to the request.
50902func (c *UserRolesPatchCall) Header() http.Header {
50903	if c.header_ == nil {
50904		c.header_ = make(http.Header)
50905	}
50906	return c.header_
50907}
50908
50909func (c *UserRolesPatchCall) doRequest(alt string) (*http.Response, error) {
50910	reqHeaders := make(http.Header)
50911	for k, v := range c.header_ {
50912		reqHeaders[k] = v
50913	}
50914	reqHeaders.Set("User-Agent", c.s.userAgent())
50915	var body io.Reader = nil
50916	body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
50917	if err != nil {
50918		return nil, err
50919	}
50920	reqHeaders.Set("Content-Type", "application/json")
50921	c.urlParams_.Set("alt", alt)
50922	c.urlParams_.Set("prettyPrint", "false")
50923	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
50924	urls += "?" + c.urlParams_.Encode()
50925	req, err := http.NewRequest("PATCH", urls, body)
50926	if err != nil {
50927		return nil, err
50928	}
50929	req.Header = reqHeaders
50930	googleapi.Expand(req.URL, map[string]string{
50931		"profileId": strconv.FormatInt(c.profileId, 10),
50932	})
50933	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50934}
50935
50936// Do executes the "dfareporting.userRoles.patch" call.
50937// Exactly one of *UserRole or error will be non-nil. Any non-2xx status
50938// code is an error. Response headers are in either
50939// *UserRole.ServerResponse.Header or (if a response was returned at
50940// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
50941// to check whether the returned error was because
50942// http.StatusNotModified was returned.
50943func (c *UserRolesPatchCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50944	gensupport.SetOptions(c.urlParams_, opts...)
50945	res, err := c.doRequest("json")
50946	if res != nil && res.StatusCode == http.StatusNotModified {
50947		if res.Body != nil {
50948			res.Body.Close()
50949		}
50950		return nil, &googleapi.Error{
50951			Code:   res.StatusCode,
50952			Header: res.Header,
50953		}
50954	}
50955	if err != nil {
50956		return nil, err
50957	}
50958	defer googleapi.CloseBody(res)
50959	if err := googleapi.CheckResponse(res); err != nil {
50960		return nil, err
50961	}
50962	ret := &UserRole{
50963		ServerResponse: googleapi.ServerResponse{
50964			Header:         res.Header,
50965			HTTPStatusCode: res.StatusCode,
50966		},
50967	}
50968	target := &ret
50969	if err := gensupport.DecodeResponse(target, res); err != nil {
50970		return nil, err
50971	}
50972	return ret, nil
50973	// {
50974	//   "description": "Updates an existing user role. This method supports patch semantics.",
50975	//   "httpMethod": "PATCH",
50976	//   "id": "dfareporting.userRoles.patch",
50977	//   "parameterOrder": [
50978	//     "profileId",
50979	//     "id"
50980	//   ],
50981	//   "parameters": {
50982	//     "id": {
50983	//       "description": "User role ID.",
50984	//       "format": "int64",
50985	//       "location": "query",
50986	//       "required": true,
50987	//       "type": "string"
50988	//     },
50989	//     "profileId": {
50990	//       "description": "User profile ID associated with this request.",
50991	//       "format": "int64",
50992	//       "location": "path",
50993	//       "required": true,
50994	//       "type": "string"
50995	//     }
50996	//   },
50997	//   "path": "userprofiles/{profileId}/userRoles",
50998	//   "request": {
50999	//     "$ref": "UserRole"
51000	//   },
51001	//   "response": {
51002	//     "$ref": "UserRole"
51003	//   },
51004	//   "scopes": [
51005	//     "https://www.googleapis.com/auth/dfatrafficking"
51006	//   ]
51007	// }
51008
51009}
51010
51011// method id "dfareporting.userRoles.update":
51012
51013type UserRolesUpdateCall struct {
51014	s          *Service
51015	profileId  int64
51016	userrole   *UserRole
51017	urlParams_ gensupport.URLParams
51018	ctx_       context.Context
51019	header_    http.Header
51020}
51021
51022// Update: Updates an existing user role.
51023func (r *UserRolesService) Update(profileId int64, userrole *UserRole) *UserRolesUpdateCall {
51024	c := &UserRolesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51025	c.profileId = profileId
51026	c.userrole = userrole
51027	return c
51028}
51029
51030// Fields allows partial responses to be retrieved. See
51031// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51032// for more information.
51033func (c *UserRolesUpdateCall) Fields(s ...googleapi.Field) *UserRolesUpdateCall {
51034	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51035	return c
51036}
51037
51038// Context sets the context to be used in this call's Do method. Any
51039// pending HTTP request will be aborted if the provided context is
51040// canceled.
51041func (c *UserRolesUpdateCall) Context(ctx context.Context) *UserRolesUpdateCall {
51042	c.ctx_ = ctx
51043	return c
51044}
51045
51046// Header returns an http.Header that can be modified by the caller to
51047// add HTTP headers to the request.
51048func (c *UserRolesUpdateCall) Header() http.Header {
51049	if c.header_ == nil {
51050		c.header_ = make(http.Header)
51051	}
51052	return c.header_
51053}
51054
51055func (c *UserRolesUpdateCall) doRequest(alt string) (*http.Response, error) {
51056	reqHeaders := make(http.Header)
51057	for k, v := range c.header_ {
51058		reqHeaders[k] = v
51059	}
51060	reqHeaders.Set("User-Agent", c.s.userAgent())
51061	var body io.Reader = nil
51062	body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
51063	if err != nil {
51064		return nil, err
51065	}
51066	reqHeaders.Set("Content-Type", "application/json")
51067	c.urlParams_.Set("alt", alt)
51068	c.urlParams_.Set("prettyPrint", "false")
51069	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
51070	urls += "?" + c.urlParams_.Encode()
51071	req, err := http.NewRequest("PUT", urls, body)
51072	if err != nil {
51073		return nil, err
51074	}
51075	req.Header = reqHeaders
51076	googleapi.Expand(req.URL, map[string]string{
51077		"profileId": strconv.FormatInt(c.profileId, 10),
51078	})
51079	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51080}
51081
51082// Do executes the "dfareporting.userRoles.update" call.
51083// Exactly one of *UserRole or error will be non-nil. Any non-2xx status
51084// code is an error. Response headers are in either
51085// *UserRole.ServerResponse.Header or (if a response was returned at
51086// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
51087// to check whether the returned error was because
51088// http.StatusNotModified was returned.
51089func (c *UserRolesUpdateCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
51090	gensupport.SetOptions(c.urlParams_, opts...)
51091	res, err := c.doRequest("json")
51092	if res != nil && res.StatusCode == http.StatusNotModified {
51093		if res.Body != nil {
51094			res.Body.Close()
51095		}
51096		return nil, &googleapi.Error{
51097			Code:   res.StatusCode,
51098			Header: res.Header,
51099		}
51100	}
51101	if err != nil {
51102		return nil, err
51103	}
51104	defer googleapi.CloseBody(res)
51105	if err := googleapi.CheckResponse(res); err != nil {
51106		return nil, err
51107	}
51108	ret := &UserRole{
51109		ServerResponse: googleapi.ServerResponse{
51110			Header:         res.Header,
51111			HTTPStatusCode: res.StatusCode,
51112		},
51113	}
51114	target := &ret
51115	if err := gensupport.DecodeResponse(target, res); err != nil {
51116		return nil, err
51117	}
51118	return ret, nil
51119	// {
51120	//   "description": "Updates an existing user role.",
51121	//   "httpMethod": "PUT",
51122	//   "id": "dfareporting.userRoles.update",
51123	//   "parameterOrder": [
51124	//     "profileId"
51125	//   ],
51126	//   "parameters": {
51127	//     "profileId": {
51128	//       "description": "User profile ID associated with this request.",
51129	//       "format": "int64",
51130	//       "location": "path",
51131	//       "required": true,
51132	//       "type": "string"
51133	//     }
51134	//   },
51135	//   "path": "userprofiles/{profileId}/userRoles",
51136	//   "request": {
51137	//     "$ref": "UserRole"
51138	//   },
51139	//   "response": {
51140	//     "$ref": "UserRole"
51141	//   },
51142	//   "scopes": [
51143	//     "https://www.googleapis.com/auth/dfatrafficking"
51144	//   ]
51145	// }
51146
51147}
51148
51149// method id "dfareporting.videoFormats.get":
51150
51151type VideoFormatsGetCall struct {
51152	s            *Service
51153	profileId    int64
51154	id           int64
51155	urlParams_   gensupport.URLParams
51156	ifNoneMatch_ string
51157	ctx_         context.Context
51158	header_      http.Header
51159}
51160
51161// Get: Gets one video format by ID.
51162func (r *VideoFormatsService) Get(profileId int64, id int64) *VideoFormatsGetCall {
51163	c := &VideoFormatsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51164	c.profileId = profileId
51165	c.id = id
51166	return c
51167}
51168
51169// Fields allows partial responses to be retrieved. See
51170// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51171// for more information.
51172func (c *VideoFormatsGetCall) Fields(s ...googleapi.Field) *VideoFormatsGetCall {
51173	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51174	return c
51175}
51176
51177// IfNoneMatch sets the optional parameter which makes the operation
51178// fail if the object's ETag matches the given value. This is useful for
51179// getting updates only after the object has changed since the last
51180// request. Use googleapi.IsNotModified to check whether the response
51181// error from Do is the result of In-None-Match.
51182func (c *VideoFormatsGetCall) IfNoneMatch(entityTag string) *VideoFormatsGetCall {
51183	c.ifNoneMatch_ = entityTag
51184	return c
51185}
51186
51187// Context sets the context to be used in this call's Do method. Any
51188// pending HTTP request will be aborted if the provided context is
51189// canceled.
51190func (c *VideoFormatsGetCall) Context(ctx context.Context) *VideoFormatsGetCall {
51191	c.ctx_ = ctx
51192	return c
51193}
51194
51195// Header returns an http.Header that can be modified by the caller to
51196// add HTTP headers to the request.
51197func (c *VideoFormatsGetCall) Header() http.Header {
51198	if c.header_ == nil {
51199		c.header_ = make(http.Header)
51200	}
51201	return c.header_
51202}
51203
51204func (c *VideoFormatsGetCall) doRequest(alt string) (*http.Response, error) {
51205	reqHeaders := make(http.Header)
51206	for k, v := range c.header_ {
51207		reqHeaders[k] = v
51208	}
51209	reqHeaders.Set("User-Agent", c.s.userAgent())
51210	if c.ifNoneMatch_ != "" {
51211		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51212	}
51213	var body io.Reader = nil
51214	c.urlParams_.Set("alt", alt)
51215	c.urlParams_.Set("prettyPrint", "false")
51216	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/videoFormats/{id}")
51217	urls += "?" + c.urlParams_.Encode()
51218	req, err := http.NewRequest("GET", urls, body)
51219	if err != nil {
51220		return nil, err
51221	}
51222	req.Header = reqHeaders
51223	googleapi.Expand(req.URL, map[string]string{
51224		"profileId": strconv.FormatInt(c.profileId, 10),
51225		"id":        strconv.FormatInt(c.id, 10),
51226	})
51227	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51228}
51229
51230// Do executes the "dfareporting.videoFormats.get" call.
51231// Exactly one of *VideoFormat or error will be non-nil. Any non-2xx
51232// status code is an error. Response headers are in either
51233// *VideoFormat.ServerResponse.Header or (if a response was returned at
51234// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
51235// to check whether the returned error was because
51236// http.StatusNotModified was returned.
51237func (c *VideoFormatsGetCall) Do(opts ...googleapi.CallOption) (*VideoFormat, error) {
51238	gensupport.SetOptions(c.urlParams_, opts...)
51239	res, err := c.doRequest("json")
51240	if res != nil && res.StatusCode == http.StatusNotModified {
51241		if res.Body != nil {
51242			res.Body.Close()
51243		}
51244		return nil, &googleapi.Error{
51245			Code:   res.StatusCode,
51246			Header: res.Header,
51247		}
51248	}
51249	if err != nil {
51250		return nil, err
51251	}
51252	defer googleapi.CloseBody(res)
51253	if err := googleapi.CheckResponse(res); err != nil {
51254		return nil, err
51255	}
51256	ret := &VideoFormat{
51257		ServerResponse: googleapi.ServerResponse{
51258			Header:         res.Header,
51259			HTTPStatusCode: res.StatusCode,
51260		},
51261	}
51262	target := &ret
51263	if err := gensupport.DecodeResponse(target, res); err != nil {
51264		return nil, err
51265	}
51266	return ret, nil
51267	// {
51268	//   "description": "Gets one video format by ID.",
51269	//   "httpMethod": "GET",
51270	//   "id": "dfareporting.videoFormats.get",
51271	//   "parameterOrder": [
51272	//     "profileId",
51273	//     "id"
51274	//   ],
51275	//   "parameters": {
51276	//     "id": {
51277	//       "description": "Video format ID.",
51278	//       "format": "int32",
51279	//       "location": "path",
51280	//       "required": true,
51281	//       "type": "integer"
51282	//     },
51283	//     "profileId": {
51284	//       "description": "User profile ID associated with this request.",
51285	//       "format": "int64",
51286	//       "location": "path",
51287	//       "required": true,
51288	//       "type": "string"
51289	//     }
51290	//   },
51291	//   "path": "userprofiles/{profileId}/videoFormats/{id}",
51292	//   "response": {
51293	//     "$ref": "VideoFormat"
51294	//   },
51295	//   "scopes": [
51296	//     "https://www.googleapis.com/auth/dfatrafficking"
51297	//   ]
51298	// }
51299
51300}
51301
51302// method id "dfareporting.videoFormats.list":
51303
51304type VideoFormatsListCall struct {
51305	s            *Service
51306	profileId    int64
51307	urlParams_   gensupport.URLParams
51308	ifNoneMatch_ string
51309	ctx_         context.Context
51310	header_      http.Header
51311}
51312
51313// List: Lists available video formats.
51314func (r *VideoFormatsService) List(profileId int64) *VideoFormatsListCall {
51315	c := &VideoFormatsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51316	c.profileId = profileId
51317	return c
51318}
51319
51320// Fields allows partial responses to be retrieved. See
51321// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51322// for more information.
51323func (c *VideoFormatsListCall) Fields(s ...googleapi.Field) *VideoFormatsListCall {
51324	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51325	return c
51326}
51327
51328// IfNoneMatch sets the optional parameter which makes the operation
51329// fail if the object's ETag matches the given value. This is useful for
51330// getting updates only after the object has changed since the last
51331// request. Use googleapi.IsNotModified to check whether the response
51332// error from Do is the result of In-None-Match.
51333func (c *VideoFormatsListCall) IfNoneMatch(entityTag string) *VideoFormatsListCall {
51334	c.ifNoneMatch_ = entityTag
51335	return c
51336}
51337
51338// Context sets the context to be used in this call's Do method. Any
51339// pending HTTP request will be aborted if the provided context is
51340// canceled.
51341func (c *VideoFormatsListCall) Context(ctx context.Context) *VideoFormatsListCall {
51342	c.ctx_ = ctx
51343	return c
51344}
51345
51346// Header returns an http.Header that can be modified by the caller to
51347// add HTTP headers to the request.
51348func (c *VideoFormatsListCall) Header() http.Header {
51349	if c.header_ == nil {
51350		c.header_ = make(http.Header)
51351	}
51352	return c.header_
51353}
51354
51355func (c *VideoFormatsListCall) doRequest(alt string) (*http.Response, error) {
51356	reqHeaders := make(http.Header)
51357	for k, v := range c.header_ {
51358		reqHeaders[k] = v
51359	}
51360	reqHeaders.Set("User-Agent", c.s.userAgent())
51361	if c.ifNoneMatch_ != "" {
51362		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51363	}
51364	var body io.Reader = nil
51365	c.urlParams_.Set("alt", alt)
51366	c.urlParams_.Set("prettyPrint", "false")
51367	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/videoFormats")
51368	urls += "?" + c.urlParams_.Encode()
51369	req, err := http.NewRequest("GET", urls, body)
51370	if err != nil {
51371		return nil, err
51372	}
51373	req.Header = reqHeaders
51374	googleapi.Expand(req.URL, map[string]string{
51375		"profileId": strconv.FormatInt(c.profileId, 10),
51376	})
51377	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51378}
51379
51380// Do executes the "dfareporting.videoFormats.list" call.
51381// Exactly one of *VideoFormatsListResponse or error will be non-nil.
51382// Any non-2xx status code is an error. Response headers are in either
51383// *VideoFormatsListResponse.ServerResponse.Header or (if a response was
51384// returned at all) in error.(*googleapi.Error).Header. Use
51385// googleapi.IsNotModified to check whether the returned error was
51386// because http.StatusNotModified was returned.
51387func (c *VideoFormatsListCall) Do(opts ...googleapi.CallOption) (*VideoFormatsListResponse, error) {
51388	gensupport.SetOptions(c.urlParams_, opts...)
51389	res, err := c.doRequest("json")
51390	if res != nil && res.StatusCode == http.StatusNotModified {
51391		if res.Body != nil {
51392			res.Body.Close()
51393		}
51394		return nil, &googleapi.Error{
51395			Code:   res.StatusCode,
51396			Header: res.Header,
51397		}
51398	}
51399	if err != nil {
51400		return nil, err
51401	}
51402	defer googleapi.CloseBody(res)
51403	if err := googleapi.CheckResponse(res); err != nil {
51404		return nil, err
51405	}
51406	ret := &VideoFormatsListResponse{
51407		ServerResponse: googleapi.ServerResponse{
51408			Header:         res.Header,
51409			HTTPStatusCode: res.StatusCode,
51410		},
51411	}
51412	target := &ret
51413	if err := gensupport.DecodeResponse(target, res); err != nil {
51414		return nil, err
51415	}
51416	return ret, nil
51417	// {
51418	//   "description": "Lists available video formats.",
51419	//   "httpMethod": "GET",
51420	//   "id": "dfareporting.videoFormats.list",
51421	//   "parameterOrder": [
51422	//     "profileId"
51423	//   ],
51424	//   "parameters": {
51425	//     "profileId": {
51426	//       "description": "User profile ID associated with this request.",
51427	//       "format": "int64",
51428	//       "location": "path",
51429	//       "required": true,
51430	//       "type": "string"
51431	//     }
51432	//   },
51433	//   "path": "userprofiles/{profileId}/videoFormats",
51434	//   "response": {
51435	//     "$ref": "VideoFormatsListResponse"
51436	//   },
51437	//   "scopes": [
51438	//     "https://www.googleapis.com/auth/dfatrafficking"
51439	//   ]
51440	// }
51441
51442}
51443