-
Notifications
You must be signed in to change notification settings - Fork 1.1k
/
Copy pathpartners-gen.go
7353 lines (6607 loc) · 280 KB
/
partners-gen.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Copyright 2019 Google LLC.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// Code generated file. DO NOT EDIT.
// Package partners provides access to the Google Partners API.
//
// For product documentation, see: https://developers.google.com/partners/
//
// Creating a client
//
// Usage example:
//
// import "google.golang.org/api/partners/v2"
// ...
// ctx := context.Background()
// partnersService, err := partners.NewService(ctx)
//
// In this example, Google Application Default Credentials are used for authentication.
//
// For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
//
// Other authentication options
//
// To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
//
// partnersService, err := partners.NewService(ctx, option.WithAPIKey("AIza..."))
//
// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
//
// config := &oauth2.Config{...}
// // ...
// token, err := config.Exchange(ctx, ...)
// partnersService, err := partners.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
//
// See https://godoc.org/google.golang.org/api/option/ for details on options.
package partners // import "google.golang.org/api/partners/v2"
import (
"bytes"
"context"
"encoding/json"
"errors"
"fmt"
"io"
"net/http"
"net/url"
"strconv"
"strings"
gensupport "google.golang.org/api/gensupport"
googleapi "google.golang.org/api/googleapi"
option "google.golang.org/api/option"
htransport "google.golang.org/api/transport/http"
)
// Always reference these packages, just in case the auto-generated code
// below doesn't.
var _ = bytes.NewBuffer
var _ = strconv.Itoa
var _ = fmt.Sprintf
var _ = json.NewDecoder
var _ = io.Copy
var _ = url.Parse
var _ = gensupport.MarshalJSON
var _ = googleapi.Version
var _ = errors.New
var _ = strings.Replace
var _ = context.Canceled
const apiId = "partners:v2"
const apiName = "partners"
const apiVersion = "v2"
const basePath = "https://partners.googleapis.com/"
// NewService creates a new Service.
func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
client, endpoint, err := htransport.NewClient(ctx, opts...)
if err != nil {
return nil, err
}
s, err := New(client)
if err != nil {
return nil, err
}
if endpoint != "" {
s.BasePath = endpoint
}
return s, nil
}
// New creates a new Service. It uses the provided http.Client for requests.
//
// Deprecated: please use NewService instead.
// To provide a custom HTTP client, use option.WithHTTPClient.
// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
func New(client *http.Client) (*Service, error) {
if client == nil {
return nil, errors.New("client is nil")
}
s := &Service{client: client, BasePath: basePath}
s.Analytics = NewAnalyticsService(s)
s.ClientMessages = NewClientMessagesService(s)
s.Companies = NewCompaniesService(s)
s.Leads = NewLeadsService(s)
s.Offers = NewOffersService(s)
s.UserEvents = NewUserEventsService(s)
s.UserStates = NewUserStatesService(s)
s.Users = NewUsersService(s)
s.V2 = NewV2Service(s)
return s, nil
}
type Service struct {
client *http.Client
BasePath string // API endpoint base URL
UserAgent string // optional additional User-Agent fragment
Analytics *AnalyticsService
ClientMessages *ClientMessagesService
Companies *CompaniesService
Leads *LeadsService
Offers *OffersService
UserEvents *UserEventsService
UserStates *UserStatesService
Users *UsersService
V2 *V2Service
}
func (s *Service) userAgent() string {
if s.UserAgent == "" {
return googleapi.UserAgent
}
return googleapi.UserAgent + " " + s.UserAgent
}
func NewAnalyticsService(s *Service) *AnalyticsService {
rs := &AnalyticsService{s: s}
return rs
}
type AnalyticsService struct {
s *Service
}
func NewClientMessagesService(s *Service) *ClientMessagesService {
rs := &ClientMessagesService{s: s}
return rs
}
type ClientMessagesService struct {
s *Service
}
func NewCompaniesService(s *Service) *CompaniesService {
rs := &CompaniesService{s: s}
rs.Leads = NewCompaniesLeadsService(s)
return rs
}
type CompaniesService struct {
s *Service
Leads *CompaniesLeadsService
}
func NewCompaniesLeadsService(s *Service) *CompaniesLeadsService {
rs := &CompaniesLeadsService{s: s}
return rs
}
type CompaniesLeadsService struct {
s *Service
}
func NewLeadsService(s *Service) *LeadsService {
rs := &LeadsService{s: s}
return rs
}
type LeadsService struct {
s *Service
}
func NewOffersService(s *Service) *OffersService {
rs := &OffersService{s: s}
rs.History = NewOffersHistoryService(s)
return rs
}
type OffersService struct {
s *Service
History *OffersHistoryService
}
func NewOffersHistoryService(s *Service) *OffersHistoryService {
rs := &OffersHistoryService{s: s}
return rs
}
type OffersHistoryService struct {
s *Service
}
func NewUserEventsService(s *Service) *UserEventsService {
rs := &UserEventsService{s: s}
return rs
}
type UserEventsService struct {
s *Service
}
func NewUserStatesService(s *Service) *UserStatesService {
rs := &UserStatesService{s: s}
return rs
}
type UserStatesService struct {
s *Service
}
func NewUsersService(s *Service) *UsersService {
rs := &UsersService{s: s}
return rs
}
type UsersService struct {
s *Service
}
func NewV2Service(s *Service) *V2Service {
rs := &V2Service{s: s}
return rs
}
type V2Service struct {
s *Service
}
// AdWordsManagerAccountInfo: Information about a particular AdWords
// Manager Account.
// Read more at https://support.google.com/adwords/answer/6139186
type AdWordsManagerAccountInfo struct {
// CustomerName: Name of the customer this account represents.
CustomerName string `json:"customerName,omitempty"`
// Id: The AdWords Manager Account id.
Id int64 `json:"id,omitempty,string"`
// ForceSendFields is a list of field names (e.g. "CustomerName") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "CustomerName") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AdWordsManagerAccountInfo) MarshalJSON() ([]byte, error) {
type NoMethod AdWordsManagerAccountInfo
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// Analytics: Analytics data for a `Company` within a single day.
type Analytics struct {
// Contacts: Instances of users contacting the `Company`
// on the specified date.
Contacts *AnalyticsDataPoint `json:"contacts,omitempty"`
// EventDate: Date on which these events occurred.
EventDate *Date `json:"eventDate,omitempty"`
// ProfileViews: Instances of users viewing the `Company` profile
// on the specified date.
ProfileViews *AnalyticsDataPoint `json:"profileViews,omitempty"`
// SearchViews: Instances of users seeing the `Company` in Google
// Partners Search results
// on the specified date.
SearchViews *AnalyticsDataPoint `json:"searchViews,omitempty"`
// ForceSendFields is a list of field names (e.g. "Contacts") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Contacts") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *Analytics) MarshalJSON() ([]byte, error) {
type NoMethod Analytics
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// AnalyticsDataPoint: Details of the analytics events for a `Company`
// within a single day.
type AnalyticsDataPoint struct {
// EventCount: Number of times the type of event occurred.
// Meaning depends on context (e.g. profile views, contacts, etc.).
EventCount int64 `json:"eventCount,omitempty"`
// EventLocations: Location information of where these events occurred.
EventLocations []*LatLng `json:"eventLocations,omitempty"`
// ForceSendFields is a list of field names (e.g. "EventCount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "EventCount") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AnalyticsDataPoint) MarshalJSON() ([]byte, error) {
type NoMethod AnalyticsDataPoint
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// AnalyticsSummary: Analytics aggregated data for a `Company` for a
// given date range.
type AnalyticsSummary struct {
// ContactsCount: Aggregated number of times users contacted the
// `Company`
// for given date range.
ContactsCount int64 `json:"contactsCount,omitempty"`
// ProfileViewsCount: Aggregated number of profile views for the
// `Company` for given date range.
ProfileViewsCount int64 `json:"profileViewsCount,omitempty"`
// SearchViewsCount: Aggregated number of times users saw the
// `Company`
// in Google Partners Search results for given date range.
SearchViewsCount int64 `json:"searchViewsCount,omitempty"`
// ForceSendFields is a list of field names (e.g. "ContactsCount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ContactsCount") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AnalyticsSummary) MarshalJSON() ([]byte, error) {
type NoMethod AnalyticsSummary
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// AvailableOffer: Available Offers to be distributed.
type AvailableOffer struct {
// Available: The number of codes for this offer that are available for
// distribution.
Available int64 `json:"available,omitempty"`
// CountryOfferInfos: Offer info by country.
CountryOfferInfos []*CountryOfferInfo `json:"countryOfferInfos,omitempty"`
// Description: Description of the offer.
Description string `json:"description,omitempty"`
// Id: ID of this offer.
Id int64 `json:"id,omitempty,string"`
// MaxAccountAge: The maximum age of an account [in days] to be
// eligible.
MaxAccountAge int64 `json:"maxAccountAge,omitempty"`
// Name: Name of the offer.
Name string `json:"name,omitempty"`
// OfferLevel: Level of this offer.
//
// Possible values:
// "OFFER_LEVEL_UNSPECIFIED" - Unset.
// "OFFER_LEVEL_DENY_PROBLEM" - Users/Agencies that have no offers
// because of a problem.
// "OFFER_LEVEL_DENY_CONTRACT" - Users/Agencies that have no offers
// due to contractural agreements.
// "OFFER_LEVEL_MANUAL" - Users/Agencies that have a
// manually-configured limit.
// "OFFER_LEVEL_LIMIT_0" - Some Agencies don't get any offers.
// "OFFER_LEVEL_LIMIT_5" - Basic level gets 5 per month.
// "OFFER_LEVEL_LIMIT_15" - Agencies with adequate AHI and spend get
// 15/month.
// "OFFER_LEVEL_LIMIT_50" - Badged partners (even in grace) get 50 per
// month.
OfferLevel string `json:"offerLevel,omitempty"`
// OfferType: Type of offer.
//
// Possible values:
// "OFFER_TYPE_UNSPECIFIED" - Unset.
// "OFFER_TYPE_SPEND_X_GET_Y" - AdWords spend X get Y.
// "OFFER_TYPE_VIDEO" - Youtube video.
// "OFFER_TYPE_SPEND_MATCH" - Spend Match up to Y.
OfferType string `json:"offerType,omitempty"`
// QualifiedCustomer: Customers who qualify for this offer.
QualifiedCustomer []*OfferCustomer `json:"qualifiedCustomer,omitempty"`
// QualifiedCustomersComplete: Whether or not the list of qualified
// customers is definitely complete.
QualifiedCustomersComplete bool `json:"qualifiedCustomersComplete,omitempty"`
// ShowSpecialOfferCopy: Should special text be shown on the offers
// page.
ShowSpecialOfferCopy bool `json:"showSpecialOfferCopy,omitempty"`
// Terms: Terms of the offer.
Terms string `json:"terms,omitempty"`
// ForceSendFields is a list of field names (e.g. "Available") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Available") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AvailableOffer) MarshalJSON() ([]byte, error) {
type NoMethod AvailableOffer
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// Certification: A user's information on a specific certification.
type Certification struct {
// Achieved: Whether this certification has been achieved.
Achieved bool `json:"achieved,omitempty"`
// CertificationType: The type of certification, the area of expertise.
//
// Possible values:
// "CERTIFICATION_TYPE_UNSPECIFIED" - Unchosen.
// "CT_ADWORDS" - AdWords certified.
// "CT_YOUTUBE" - YouTube certified.
// "CT_VIDEOADS" - VideoAds certified.
// "CT_ANALYTICS" - Analytics certified.
// "CT_DOUBLECLICK" - DoubleClick certified.
// "CT_SHOPPING" - Shopping certified.
// "CT_MOBILE" - Mobile certified.
// "CT_DIGITAL_SALES" - Digital sales certified.
// "CT_ADWORDS_SEARCH" - AdWords Search certified.
// "CT_ADWORDS_DISPLAY" - AdWords Display certified.
// "CT_MOBILE_SITES" - Mobile Sites certified.
CertificationType string `json:"certificationType,omitempty"`
// Expiration: Date this certification is due to expire.
Expiration string `json:"expiration,omitempty"`
// LastAchieved: The date the user last achieved certification.
LastAchieved string `json:"lastAchieved,omitempty"`
// Warning: Whether this certification is in the state of warning.
Warning bool `json:"warning,omitempty"`
// ForceSendFields is a list of field names (e.g. "Achieved") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Achieved") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *Certification) MarshalJSON() ([]byte, error) {
type NoMethod Certification
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// CertificationExamStatus: Status for a Google Partners certification
// exam.
type CertificationExamStatus struct {
// NumberUsersPass: The number of people who have passed the
// certification exam.
NumberUsersPass int64 `json:"numberUsersPass,omitempty"`
// Type: The type of certification exam.
//
// Possible values:
// "CERTIFICATION_EXAM_TYPE_UNSPECIFIED" - Unchosen.
// "CET_ADWORDS_FUNDAMENTALS" - Adwords Fundamentals exam.
// "CET_ADWORDS_ADVANCED_SEARCH" - AdWords advanced search exam.
// "CET_ADWORDS_ADVANCED_DISPLAY" - AdWords advanced display exam.
// "CET_VIDEO_ADS" - VideoAds exam.
// "CET_DOUBLECLICK" - DoubleClick exam.
// "CET_ANALYTICS" - Analytics exam.
// "CET_SHOPPING" - Shopping exam.
// "CET_MOBILE" - Mobile exam.
// "CET_DIGITAL_SALES" - Digital Sales exam.
// "CET_MOBILE_SITES" - Mobile Sites exam.
Type string `json:"type,omitempty"`
// ForceSendFields is a list of field names (e.g. "NumberUsersPass") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "NumberUsersPass") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *CertificationExamStatus) MarshalJSON() ([]byte, error) {
type NoMethod CertificationExamStatus
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// CertificationStatus: Google Partners certification status.
type CertificationStatus struct {
// ExamStatuses: List of certification exam statuses.
ExamStatuses []*CertificationExamStatus `json:"examStatuses,omitempty"`
// IsCertified: Whether certification is passing.
IsCertified bool `json:"isCertified,omitempty"`
// Type: The type of the certification.
//
// Possible values:
// "CERTIFICATION_TYPE_UNSPECIFIED" - Unchosen.
// "CT_ADWORDS" - AdWords certified.
// "CT_YOUTUBE" - YouTube certified.
// "CT_VIDEOADS" - VideoAds certified.
// "CT_ANALYTICS" - Analytics certified.
// "CT_DOUBLECLICK" - DoubleClick certified.
// "CT_SHOPPING" - Shopping certified.
// "CT_MOBILE" - Mobile certified.
// "CT_DIGITAL_SALES" - Digital sales certified.
// "CT_ADWORDS_SEARCH" - AdWords Search certified.
// "CT_ADWORDS_DISPLAY" - AdWords Display certified.
// "CT_MOBILE_SITES" - Mobile Sites certified.
Type string `json:"type,omitempty"`
// UserCount: Number of people who are certified,
UserCount int64 `json:"userCount,omitempty"`
// ForceSendFields is a list of field names (e.g. "ExamStatuses") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "ExamStatuses") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *CertificationStatus) MarshalJSON() ([]byte, error) {
type NoMethod CertificationStatus
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// Company: A company resource in the Google Partners API. Once
// certified, it qualifies
// for being searched by advertisers.
type Company struct {
// AdditionalWebsites: URL of the company's additional websites used to
// verify the dynamic badges.
// These are stored as full URLs as entered by the user, but only the
// TLD will
// be used for the actual verification.
AdditionalWebsites []string `json:"additionalWebsites,omitempty"`
// AutoApprovalEmailDomains: Email domains that allow users with a
// matching email address to get
// auto-approved for associating with this company.
AutoApprovalEmailDomains []string `json:"autoApprovalEmailDomains,omitempty"`
// BadgeAuthorityInAwn: Whether the company's badge authority is in AWN
BadgeAuthorityInAwn bool `json:"badgeAuthorityInAwn,omitempty"`
// BadgeTier: Partner badge tier
//
// Possible values:
// "BADGE_TIER_NONE" - Tier badge is not set.
// "BADGE_TIER_REGULAR" - Agency has regular partner badge.
// "BADGE_TIER_PREMIER" - Agency has premier badge.
BadgeTier string `json:"badgeTier,omitempty"`
// CertificationStatuses: The list of Google Partners certification
// statuses for the company.
CertificationStatuses []*CertificationStatus `json:"certificationStatuses,omitempty"`
// CompanyTypes: Company type labels listed on the company's profile.
//
// Possible values:
// "COMPANY_TYPE_UNSPECIFIED" - Unchosen.
// "FULL_SERVICE_AGENCY" - Handles all aspects of the advertising
// process.
// "MEDIA_AGENCY" - Focuses solely on an advertiser's media placement.
// "CREATIVE_AGENCY" - Plans/executes advertising campaigns.
// "CDIGITAL_AGENCY" - Like a
// FULL_SERVICE_AGENCY,
// but specializing in digital.
// "SEM_SEO" - Increases visibility in search engine result pages.
// "PERFORMANCE_MARKETING" - Drives promotional efforts for immediate
// impact.
// "ADVERTISING_TOOL_DEVELOPMENT" - Focuses on bid management,
// conversion, reporting.
// "PR" - Establishes favorable relationship with public through
// low/no-cost
// communications.
// "SELF_MANAGED" - Does not manage other company's accounts, manages
// own marketing programs.
// "RESELLER" - Full-service AdWords account management for local
// businesses.
CompanyTypes []string `json:"companyTypes,omitempty"`
// ConvertedMinMonthlyBudget: The minimum monthly budget that the
// company accepts for partner business,
// converted to the requested currency code.
ConvertedMinMonthlyBudget *Money `json:"convertedMinMonthlyBudget,omitempty"`
// Id: The ID of the company.
Id string `json:"id,omitempty"`
// Industries: Industries the company can help with.
//
// Possible values:
// "INDUSTRY_UNSPECIFIED" - Unchosen.
// "I_AUTOMOTIVE" - The automotive industry.
// "I_BUSINESS_TO_BUSINESS" - The business-to-business industry.
// "I_CONSUMER_PACKAGED_GOODS" - The consumer packaged goods industry.
// "I_EDUCATION" - The education industry.
// "I_FINANCE" - The finance industry.
// "I_HEALTHCARE" - The healthcare industry.
// "I_MEDIA_AND_ENTERTAINMENT" - The media and entertainment industry.
// "I_RETAIL" - The retail industry.
// "I_TECHNOLOGY" - The technology industry.
// "I_TRAVEL" - The travel industry.
Industries []string `json:"industries,omitempty"`
// LocalizedInfos: The list of localized info for the company.
LocalizedInfos []*LocalizedCompanyInfo `json:"localizedInfos,omitempty"`
// Locations: The list of all company locations.
// If set, must include the
// primary_location
// in the list.
Locations []*Location `json:"locations,omitempty"`
// Name: The name of the company.
Name string `json:"name,omitempty"`
// OriginalMinMonthlyBudget: The unconverted minimum monthly budget that
// the company accepts for partner
// business.
OriginalMinMonthlyBudget *Money `json:"originalMinMonthlyBudget,omitempty"`
// PrimaryAdwordsManagerAccountId: The Primary AdWords Manager Account
// id.
PrimaryAdwordsManagerAccountId int64 `json:"primaryAdwordsManagerAccountId,omitempty,string"`
// PrimaryLanguageCode: The primary language code of the company, as
// defined by
// <a href="https://tools.ietf.org/html/bcp47">BCP 47</a>
// (IETF BCP 47, "Tags for Identifying Languages").
PrimaryLanguageCode string `json:"primaryLanguageCode,omitempty"`
// PrimaryLocation: The primary location of the company.
PrimaryLocation *Location `json:"primaryLocation,omitempty"`
// ProfileStatus: The public viewability status of the company's
// profile.
//
// Possible values:
// "COMPANY_PROFILE_STATUS_UNSPECIFIED" - Unchosen.
// "HIDDEN" - Company profile does not show up publicly.
// "PUBLISHED" - Company profile can only be viewed by the profile's
// URL
// and not by Google Partner Search.
// "SEARCHABLE" - Company profile can be viewed by the profile's
// URL
// and by Google Partner Search.
ProfileStatus string `json:"profileStatus,omitempty"`
// PublicProfile: Basic information from the company's public profile.
PublicProfile *PublicProfile `json:"publicProfile,omitempty"`
// Ranks: Information related to the ranking of the company within the
// list of
// companies.
Ranks []*Rank `json:"ranks,omitempty"`
// Services: Services the company can help with.
//
// Possible values:
// "SERVICE_UNSPECIFIED" - Unchosen.
// "S_ADVANCED_ADWORDS_SUPPORT" - Help with advanced AdWords support.
// "S_ADVERTISING_ON_GOOGLE" - Help with advertising on Google.
// "S_AN_ENHANCED_WEBSITE" - Help with an enhanced website.
// "S_AN_ONLINE_MARKETING_PLAN" - Help with an online marketing plan.
// "S_MOBILE_AND_VIDEO_ADS" - Help with mobile and video ads.
// "S_MOBILE_WEBSITE_SERVICES" - Help with mobile websites.
Services []string `json:"services,omitempty"`
// SpecializationStatus: The list of Google Partners specialization
// statuses for the company.
SpecializationStatus []*SpecializationStatus `json:"specializationStatus,omitempty"`
// WebsiteUrl: URL of the company's website.
WebsiteUrl string `json:"websiteUrl,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "AdditionalWebsites")
// to unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "AdditionalWebsites") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *Company) MarshalJSON() ([]byte, error) {
type NoMethod Company
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// CompanyRelation: A CompanyRelation resource representing information
// about a user's
// affiliation and standing with a company in Partners.
type CompanyRelation struct {
// Address: The primary address for this company.
Address string `json:"address,omitempty"`
// BadgeTier: Whether the company is a Partner.
//
// Possible values:
// "BADGE_TIER_NONE" - Tier badge is not set.
// "BADGE_TIER_REGULAR" - Agency has regular partner badge.
// "BADGE_TIER_PREMIER" - Agency has premier badge.
BadgeTier string `json:"badgeTier,omitempty"`
// CompanyAdmin: Indicates if the user is an admin for this company.
CompanyAdmin bool `json:"companyAdmin,omitempty"`
// CompanyId: The ID of the company. There may be no id if this is
// a
// pending company.5
CompanyId string `json:"companyId,omitempty"`
// CreationTime: The timestamp of when affiliation was
// requested.
// @OutputOnly
CreationTime string `json:"creationTime,omitempty"`
// InternalCompanyId: The internal company ID.
// Only available for a whitelisted set of api clients.
InternalCompanyId string `json:"internalCompanyId,omitempty"`
// IsPending: The flag that indicates if the company is pending
// verification.
IsPending bool `json:"isPending,omitempty"`
// LogoUrl: A URL to a profile photo, e.g. a G+ profile photo.
LogoUrl string `json:"logoUrl,omitempty"`
// ManagerAccount: The AdWords manager account # associated this
// company.
ManagerAccount int64 `json:"managerAccount,omitempty,string"`
// Name: The name (in the company's primary language) for the company.
Name string `json:"name,omitempty"`
// PhoneNumber: The phone number for the company's primary address.
PhoneNumber string `json:"phoneNumber,omitempty"`
// PrimaryAddress: The primary location of the company.
PrimaryAddress *Location `json:"primaryAddress,omitempty"`
// PrimaryCountryCode: The primary country code of the company.
PrimaryCountryCode string `json:"primaryCountryCode,omitempty"`
// PrimaryLanguageCode: The primary language code of the company.
PrimaryLanguageCode string `json:"primaryLanguageCode,omitempty"`
// ResolvedTimestamp: The timestamp when the user was
// approved.
// @OutputOnly
ResolvedTimestamp string `json:"resolvedTimestamp,omitempty"`
// Segment: The segment the company is classified as.
//
// Possible values:
// "COMPANY_SEGMENT_UNKNOWN" - Default segment indicates an unknown.
// "COMPANY_SEGMENT_NAL" - Segment representing a selected group of
// Partners
// "COMPANY_SEGMENT_PSP" - Segment representing Premier SMB Partners,
// an AdWords partnership program.
// "COMPANY_SEGMENT_PPSP" - A segment of Premier SMB Partners that
// have relationship with Google.
Segment []string `json:"segment,omitempty"`
// SpecializationStatus: The list of Google Partners specialization
// statuses for the company.
SpecializationStatus []*SpecializationStatus `json:"specializationStatus,omitempty"`
// State: The state of relationship, in terms of approvals.
//
// Possible values:
// "USER_COMPANY_REATION_STATE_NONE_SPECIFIED" - Default unspecified
// value.
// "USER_COMPANY_RELATION_STATE_AWAIT_EMAIL" - User has filled in a
// request to be associated with an company.
// Now waiting email confirmation.
// "USER_COMPANY_RELATION_STATE_AWAIT_ADMIN" - Pending approval from
// company.
// Email confirmation will not approve this one.
// "USER_COMPANY_RELATION_STATE_APPROVED" - Approved by company.
State string `json:"state,omitempty"`
// Website: The website URL for this company.
Website string `json:"website,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Address") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Address") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *CompanyRelation) MarshalJSON() ([]byte, error) {
type NoMethod CompanyRelation
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// CountryOfferInfo: Offer info by country.
type CountryOfferInfo struct {
// GetYAmount: (localized) Get Y amount for that country's offer.
GetYAmount string `json:"getYAmount,omitempty"`
// OfferCountryCode: Country code for which offer codes may be
// requested.
OfferCountryCode string `json:"offerCountryCode,omitempty"`
// OfferType: Type of offer country is eligible for.
//
// Possible values:
// "OFFER_TYPE_UNSPECIFIED" - Unset.
// "OFFER_TYPE_SPEND_X_GET_Y" - AdWords spend X get Y.
// "OFFER_TYPE_VIDEO" - Youtube video.
// "OFFER_TYPE_SPEND_MATCH" - Spend Match up to Y.
OfferType string `json:"offerType,omitempty"`
// SpendXAmount: (localized) Spend X amount for that country's offer.
SpendXAmount string `json:"spendXAmount,omitempty"`
// ForceSendFields is a list of field names (e.g. "GetYAmount") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "GetYAmount") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *CountryOfferInfo) MarshalJSON() ([]byte, error) {
type NoMethod CountryOfferInfo
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// CreateLeadRequest: Request message for CreateLead.
type CreateLeadRequest struct {
// Lead: The lead resource. The `LeadType` must not be
// `LEAD_TYPE_UNSPECIFIED`
// and either `email` or `phone_number` must be provided.
Lead *Lead `json:"lead,omitempty"`
// RecaptchaChallenge: <a
// href="https://www.google.com/recaptcha/">reCaptcha</a> challenge
// info.
RecaptchaChallenge *RecaptchaChallenge `json:"recaptchaChallenge,omitempty"`
// RequestMetadata: Current request metadata.
RequestMetadata *RequestMetadata `json:"requestMetadata,omitempty"`
// ForceSendFields is a list of field names (e.g. "Lead") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the