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 package androidpublisher
52
53 import (
54 "bytes"
55 "context"
56 "encoding/json"
57 "errors"
58 "fmt"
59 "io"
60 "net/http"
61 "net/url"
62 "strconv"
63 "strings"
64
65 googleapi "google.golang.org/api/googleapi"
66 internal "google.golang.org/api/internal"
67 gensupport "google.golang.org/api/internal/gensupport"
68 option "google.golang.org/api/option"
69 internaloption "google.golang.org/api/option/internaloption"
70 htransport "google.golang.org/api/transport/http"
71 )
72
73
74
75 var _ = bytes.NewBuffer
76 var _ = strconv.Itoa
77 var _ = fmt.Sprintf
78 var _ = json.NewDecoder
79 var _ = io.Copy
80 var _ = url.Parse
81 var _ = gensupport.MarshalJSON
82 var _ = googleapi.Version
83 var _ = errors.New
84 var _ = strings.Replace
85 var _ = context.Canceled
86 var _ = internaloption.WithDefaultEndpoint
87 var _ = internal.Version
88
89 const apiId = "androidpublisher:v3"
90 const apiName = "androidpublisher"
91 const apiVersion = "v3"
92 const basePath = "https://androidpublisher.googleapis.com/"
93 const basePathTemplate = "https://androidpublisher.UNIVERSE_DOMAIN/"
94 const mtlsBasePath = "https://androidpublisher.mtls.googleapis.com/"
95
96
97 const (
98
99 AndroidpublisherScope = "https://www.googleapis.com/auth/androidpublisher"
100 )
101
102
103 func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
104 scopesOption := internaloption.WithDefaultScopes(
105 "https://www.googleapis.com/auth/androidpublisher",
106 )
107
108 opts = append([]option.ClientOption{scopesOption}, opts...)
109 opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
110 opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate))
111 opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
112 opts = append(opts, internaloption.EnableNewAuthLibrary())
113 client, endpoint, err := htransport.NewClient(ctx, opts...)
114 if err != nil {
115 return nil, err
116 }
117 s, err := New(client)
118 if err != nil {
119 return nil, err
120 }
121 if endpoint != "" {
122 s.BasePath = endpoint
123 }
124 return s, nil
125 }
126
127
128
129
130
131
132 func New(client *http.Client) (*Service, error) {
133 if client == nil {
134 return nil, errors.New("client is nil")
135 }
136 s := &Service{client: client, BasePath: basePath}
137 s.Applications = NewApplicationsService(s)
138 s.Apprecovery = NewApprecoveryService(s)
139 s.Edits = NewEditsService(s)
140 s.Externaltransactions = NewExternaltransactionsService(s)
141 s.Generatedapks = NewGeneratedapksService(s)
142 s.Grants = NewGrantsService(s)
143 s.Inappproducts = NewInappproductsService(s)
144 s.Internalappsharingartifacts = NewInternalappsharingartifactsService(s)
145 s.Monetization = NewMonetizationService(s)
146 s.Orders = NewOrdersService(s)
147 s.Purchases = NewPurchasesService(s)
148 s.Reviews = NewReviewsService(s)
149 s.Systemapks = NewSystemapksService(s)
150 s.Users = NewUsersService(s)
151 return s, nil
152 }
153
154 type Service struct {
155 client *http.Client
156 BasePath string
157 UserAgent string
158
159 Applications *ApplicationsService
160
161 Apprecovery *ApprecoveryService
162
163 Edits *EditsService
164
165 Externaltransactions *ExternaltransactionsService
166
167 Generatedapks *GeneratedapksService
168
169 Grants *GrantsService
170
171 Inappproducts *InappproductsService
172
173 Internalappsharingartifacts *InternalappsharingartifactsService
174
175 Monetization *MonetizationService
176
177 Orders *OrdersService
178
179 Purchases *PurchasesService
180
181 Reviews *ReviewsService
182
183 Systemapks *SystemapksService
184
185 Users *UsersService
186 }
187
188 func (s *Service) userAgent() string {
189 if s.UserAgent == "" {
190 return googleapi.UserAgent
191 }
192 return googleapi.UserAgent + " " + s.UserAgent
193 }
194
195 func NewApplicationsService(s *Service) *ApplicationsService {
196 rs := &ApplicationsService{s: s}
197 rs.DeviceTierConfigs = NewApplicationsDeviceTierConfigsService(s)
198 return rs
199 }
200
201 type ApplicationsService struct {
202 s *Service
203
204 DeviceTierConfigs *ApplicationsDeviceTierConfigsService
205 }
206
207 func NewApplicationsDeviceTierConfigsService(s *Service) *ApplicationsDeviceTierConfigsService {
208 rs := &ApplicationsDeviceTierConfigsService{s: s}
209 return rs
210 }
211
212 type ApplicationsDeviceTierConfigsService struct {
213 s *Service
214 }
215
216 func NewApprecoveryService(s *Service) *ApprecoveryService {
217 rs := &ApprecoveryService{s: s}
218 return rs
219 }
220
221 type ApprecoveryService struct {
222 s *Service
223 }
224
225 func NewEditsService(s *Service) *EditsService {
226 rs := &EditsService{s: s}
227 rs.Apks = NewEditsApksService(s)
228 rs.Bundles = NewEditsBundlesService(s)
229 rs.Countryavailability = NewEditsCountryavailabilityService(s)
230 rs.Deobfuscationfiles = NewEditsDeobfuscationfilesService(s)
231 rs.Details = NewEditsDetailsService(s)
232 rs.Expansionfiles = NewEditsExpansionfilesService(s)
233 rs.Images = NewEditsImagesService(s)
234 rs.Listings = NewEditsListingsService(s)
235 rs.Testers = NewEditsTestersService(s)
236 rs.Tracks = NewEditsTracksService(s)
237 return rs
238 }
239
240 type EditsService struct {
241 s *Service
242
243 Apks *EditsApksService
244
245 Bundles *EditsBundlesService
246
247 Countryavailability *EditsCountryavailabilityService
248
249 Deobfuscationfiles *EditsDeobfuscationfilesService
250
251 Details *EditsDetailsService
252
253 Expansionfiles *EditsExpansionfilesService
254
255 Images *EditsImagesService
256
257 Listings *EditsListingsService
258
259 Testers *EditsTestersService
260
261 Tracks *EditsTracksService
262 }
263
264 func NewEditsApksService(s *Service) *EditsApksService {
265 rs := &EditsApksService{s: s}
266 return rs
267 }
268
269 type EditsApksService struct {
270 s *Service
271 }
272
273 func NewEditsBundlesService(s *Service) *EditsBundlesService {
274 rs := &EditsBundlesService{s: s}
275 return rs
276 }
277
278 type EditsBundlesService struct {
279 s *Service
280 }
281
282 func NewEditsCountryavailabilityService(s *Service) *EditsCountryavailabilityService {
283 rs := &EditsCountryavailabilityService{s: s}
284 return rs
285 }
286
287 type EditsCountryavailabilityService struct {
288 s *Service
289 }
290
291 func NewEditsDeobfuscationfilesService(s *Service) *EditsDeobfuscationfilesService {
292 rs := &EditsDeobfuscationfilesService{s: s}
293 return rs
294 }
295
296 type EditsDeobfuscationfilesService struct {
297 s *Service
298 }
299
300 func NewEditsDetailsService(s *Service) *EditsDetailsService {
301 rs := &EditsDetailsService{s: s}
302 return rs
303 }
304
305 type EditsDetailsService struct {
306 s *Service
307 }
308
309 func NewEditsExpansionfilesService(s *Service) *EditsExpansionfilesService {
310 rs := &EditsExpansionfilesService{s: s}
311 return rs
312 }
313
314 type EditsExpansionfilesService struct {
315 s *Service
316 }
317
318 func NewEditsImagesService(s *Service) *EditsImagesService {
319 rs := &EditsImagesService{s: s}
320 return rs
321 }
322
323 type EditsImagesService struct {
324 s *Service
325 }
326
327 func NewEditsListingsService(s *Service) *EditsListingsService {
328 rs := &EditsListingsService{s: s}
329 return rs
330 }
331
332 type EditsListingsService struct {
333 s *Service
334 }
335
336 func NewEditsTestersService(s *Service) *EditsTestersService {
337 rs := &EditsTestersService{s: s}
338 return rs
339 }
340
341 type EditsTestersService struct {
342 s *Service
343 }
344
345 func NewEditsTracksService(s *Service) *EditsTracksService {
346 rs := &EditsTracksService{s: s}
347 return rs
348 }
349
350 type EditsTracksService struct {
351 s *Service
352 }
353
354 func NewExternaltransactionsService(s *Service) *ExternaltransactionsService {
355 rs := &ExternaltransactionsService{s: s}
356 return rs
357 }
358
359 type ExternaltransactionsService struct {
360 s *Service
361 }
362
363 func NewGeneratedapksService(s *Service) *GeneratedapksService {
364 rs := &GeneratedapksService{s: s}
365 return rs
366 }
367
368 type GeneratedapksService struct {
369 s *Service
370 }
371
372 func NewGrantsService(s *Service) *GrantsService {
373 rs := &GrantsService{s: s}
374 return rs
375 }
376
377 type GrantsService struct {
378 s *Service
379 }
380
381 func NewInappproductsService(s *Service) *InappproductsService {
382 rs := &InappproductsService{s: s}
383 return rs
384 }
385
386 type InappproductsService struct {
387 s *Service
388 }
389
390 func NewInternalappsharingartifactsService(s *Service) *InternalappsharingartifactsService {
391 rs := &InternalappsharingartifactsService{s: s}
392 return rs
393 }
394
395 type InternalappsharingartifactsService struct {
396 s *Service
397 }
398
399 func NewMonetizationService(s *Service) *MonetizationService {
400 rs := &MonetizationService{s: s}
401 rs.Subscriptions = NewMonetizationSubscriptionsService(s)
402 return rs
403 }
404
405 type MonetizationService struct {
406 s *Service
407
408 Subscriptions *MonetizationSubscriptionsService
409 }
410
411 func NewMonetizationSubscriptionsService(s *Service) *MonetizationSubscriptionsService {
412 rs := &MonetizationSubscriptionsService{s: s}
413 rs.BasePlans = NewMonetizationSubscriptionsBasePlansService(s)
414 return rs
415 }
416
417 type MonetizationSubscriptionsService struct {
418 s *Service
419
420 BasePlans *MonetizationSubscriptionsBasePlansService
421 }
422
423 func NewMonetizationSubscriptionsBasePlansService(s *Service) *MonetizationSubscriptionsBasePlansService {
424 rs := &MonetizationSubscriptionsBasePlansService{s: s}
425 rs.Offers = NewMonetizationSubscriptionsBasePlansOffersService(s)
426 return rs
427 }
428
429 type MonetizationSubscriptionsBasePlansService struct {
430 s *Service
431
432 Offers *MonetizationSubscriptionsBasePlansOffersService
433 }
434
435 func NewMonetizationSubscriptionsBasePlansOffersService(s *Service) *MonetizationSubscriptionsBasePlansOffersService {
436 rs := &MonetizationSubscriptionsBasePlansOffersService{s: s}
437 return rs
438 }
439
440 type MonetizationSubscriptionsBasePlansOffersService struct {
441 s *Service
442 }
443
444 func NewOrdersService(s *Service) *OrdersService {
445 rs := &OrdersService{s: s}
446 return rs
447 }
448
449 type OrdersService struct {
450 s *Service
451 }
452
453 func NewPurchasesService(s *Service) *PurchasesService {
454 rs := &PurchasesService{s: s}
455 rs.Products = NewPurchasesProductsService(s)
456 rs.Subscriptions = NewPurchasesSubscriptionsService(s)
457 rs.Subscriptionsv2 = NewPurchasesSubscriptionsv2Service(s)
458 rs.Voidedpurchases = NewPurchasesVoidedpurchasesService(s)
459 return rs
460 }
461
462 type PurchasesService struct {
463 s *Service
464
465 Products *PurchasesProductsService
466
467 Subscriptions *PurchasesSubscriptionsService
468
469 Subscriptionsv2 *PurchasesSubscriptionsv2Service
470
471 Voidedpurchases *PurchasesVoidedpurchasesService
472 }
473
474 func NewPurchasesProductsService(s *Service) *PurchasesProductsService {
475 rs := &PurchasesProductsService{s: s}
476 return rs
477 }
478
479 type PurchasesProductsService struct {
480 s *Service
481 }
482
483 func NewPurchasesSubscriptionsService(s *Service) *PurchasesSubscriptionsService {
484 rs := &PurchasesSubscriptionsService{s: s}
485 return rs
486 }
487
488 type PurchasesSubscriptionsService struct {
489 s *Service
490 }
491
492 func NewPurchasesSubscriptionsv2Service(s *Service) *PurchasesSubscriptionsv2Service {
493 rs := &PurchasesSubscriptionsv2Service{s: s}
494 return rs
495 }
496
497 type PurchasesSubscriptionsv2Service struct {
498 s *Service
499 }
500
501 func NewPurchasesVoidedpurchasesService(s *Service) *PurchasesVoidedpurchasesService {
502 rs := &PurchasesVoidedpurchasesService{s: s}
503 return rs
504 }
505
506 type PurchasesVoidedpurchasesService struct {
507 s *Service
508 }
509
510 func NewReviewsService(s *Service) *ReviewsService {
511 rs := &ReviewsService{s: s}
512 return rs
513 }
514
515 type ReviewsService struct {
516 s *Service
517 }
518
519 func NewSystemapksService(s *Service) *SystemapksService {
520 rs := &SystemapksService{s: s}
521 rs.Variants = NewSystemapksVariantsService(s)
522 return rs
523 }
524
525 type SystemapksService struct {
526 s *Service
527
528 Variants *SystemapksVariantsService
529 }
530
531 func NewSystemapksVariantsService(s *Service) *SystemapksVariantsService {
532 rs := &SystemapksVariantsService{s: s}
533 return rs
534 }
535
536 type SystemapksVariantsService struct {
537 s *Service
538 }
539
540 func NewUsersService(s *Service) *UsersService {
541 rs := &UsersService{s: s}
542 return rs
543 }
544
545 type UsersService struct {
546 s *Service
547 }
548
549
550 type Abi struct {
551
552
553
554
555
556
557
558
559
560
561 Alias string `json:"alias,omitempty"`
562
563
564
565
566
567 ForceSendFields []string `json:"-"`
568
569
570
571
572 NullFields []string `json:"-"`
573 }
574
575 func (s *Abi) MarshalJSON() ([]byte, error) {
576 type NoMethod Abi
577 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
578 }
579
580
581 type AbiTargeting struct {
582
583
584 Alternatives []*Abi `json:"alternatives,omitempty"`
585
586 Value []*Abi `json:"value,omitempty"`
587
588
589
590
591
592 ForceSendFields []string `json:"-"`
593
594
595
596
597 NullFields []string `json:"-"`
598 }
599
600 func (s *AbiTargeting) MarshalJSON() ([]byte, error) {
601 type NoMethod AbiTargeting
602 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
603 }
604
605
606
607 type AcquisitionTargetingRule struct {
608
609
610 Scope *TargetingRuleScope `json:"scope,omitempty"`
611
612
613
614
615
616 ForceSendFields []string `json:"-"`
617
618
619
620
621 NullFields []string `json:"-"`
622 }
623
624 func (s *AcquisitionTargetingRule) MarshalJSON() ([]byte, error) {
625 type NoMethod AcquisitionTargetingRule
626 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
627 }
628
629
630 type ActivateBasePlanRequest struct {
631
632 BasePlanId string `json:"basePlanId,omitempty"`
633
634
635
636
637
638
639
640
641
642
643
644
645 LatencyTolerance string `json:"latencyTolerance,omitempty"`
646
647
648 PackageName string `json:"packageName,omitempty"`
649
650
651 ProductId string `json:"productId,omitempty"`
652
653
654
655
656
657 ForceSendFields []string `json:"-"`
658
659
660
661
662 NullFields []string `json:"-"`
663 }
664
665 func (s *ActivateBasePlanRequest) MarshalJSON() ([]byte, error) {
666 type NoMethod ActivateBasePlanRequest
667 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
668 }
669
670
671
672 type ActivateSubscriptionOfferRequest struct {
673
674 BasePlanId string `json:"basePlanId,omitempty"`
675
676
677
678
679
680
681
682
683
684
685
686
687 LatencyTolerance string `json:"latencyTolerance,omitempty"`
688
689 OfferId string `json:"offerId,omitempty"`
690
691
692 PackageName string `json:"packageName,omitempty"`
693
694 ProductId string `json:"productId,omitempty"`
695
696
697
698
699
700 ForceSendFields []string `json:"-"`
701
702
703
704
705 NullFields []string `json:"-"`
706 }
707
708 func (s *ActivateSubscriptionOfferRequest) MarshalJSON() ([]byte, error) {
709 type NoMethod ActivateSubscriptionOfferRequest
710 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
711 }
712
713
714 type AddTargetingRequest struct {
715
716
717 TargetingUpdate *TargetingUpdate `json:"targetingUpdate,omitempty"`
718
719
720
721
722
723 ForceSendFields []string `json:"-"`
724
725
726
727
728 NullFields []string `json:"-"`
729 }
730
731 func (s *AddTargetingRequest) MarshalJSON() ([]byte, error) {
732 type NoMethod AddTargetingRequest
733 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
734 }
735
736
737 type AddTargetingResponse struct {
738
739 googleapi.ServerResponse `json:"-"`
740 }
741
742
743 type AllUsers struct {
744
745 IsAllUsersRequested bool `json:"isAllUsersRequested,omitempty"`
746
747
748
749
750
751 ForceSendFields []string `json:"-"`
752
753
754
755
756 NullFields []string `json:"-"`
757 }
758
759 func (s *AllUsers) MarshalJSON() ([]byte, error) {
760 type NoMethod AllUsers
761 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
762 }
763
764
765
766 type AndroidSdks struct {
767
768
769
770 SdkLevels googleapi.Int64s `json:"sdkLevels,omitempty"`
771
772
773
774
775
776 ForceSendFields []string `json:"-"`
777
778
779
780
781 NullFields []string `json:"-"`
782 }
783
784 func (s *AndroidSdks) MarshalJSON() ([]byte, error) {
785 type NoMethod AndroidSdks
786 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
787 }
788
789
790 type Apk struct {
791
792 Binary *ApkBinary `json:"binary,omitempty"`
793
794 VersionCode int64 `json:"versionCode,omitempty"`
795
796
797 googleapi.ServerResponse `json:"-"`
798
799
800
801
802
803 ForceSendFields []string `json:"-"`
804
805
806
807
808 NullFields []string `json:"-"`
809 }
810
811 func (s *Apk) MarshalJSON() ([]byte, error) {
812 type NoMethod Apk
813 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
814 }
815
816
817 type ApkBinary struct {
818
819
820 Sha1 string `json:"sha1,omitempty"`
821
822
823 Sha256 string `json:"sha256,omitempty"`
824
825
826
827
828
829 ForceSendFields []string `json:"-"`
830
831
832
833
834 NullFields []string `json:"-"`
835 }
836
837 func (s *ApkBinary) MarshalJSON() ([]byte, error) {
838 type NoMethod ApkBinary
839 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
840 }
841
842
843 type ApkDescription struct {
844
845 AssetSliceMetadata *SplitApkMetadata `json:"assetSliceMetadata,omitempty"`
846
847 InstantApkMetadata *SplitApkMetadata `json:"instantApkMetadata,omitempty"`
848
849
850
851 Path string `json:"path,omitempty"`
852
853 SplitApkMetadata *SplitApkMetadata `json:"splitApkMetadata,omitempty"`
854
855 StandaloneApkMetadata *StandaloneApkMetadata `json:"standaloneApkMetadata,omitempty"`
856
857 Targeting *ApkTargeting `json:"targeting,omitempty"`
858
859
860
861
862
863 ForceSendFields []string `json:"-"`
864
865
866
867
868 NullFields []string `json:"-"`
869 }
870
871 func (s *ApkDescription) MarshalJSON() ([]byte, error) {
872 type NoMethod ApkDescription
873 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
874 }
875
876
877 type ApkSet struct {
878
879 ApkDescription []*ApkDescription `json:"apkDescription,omitempty"`
880
881 ModuleMetadata *ModuleMetadata `json:"moduleMetadata,omitempty"`
882
883
884
885
886
887 ForceSendFields []string `json:"-"`
888
889
890
891
892 NullFields []string `json:"-"`
893 }
894
895 func (s *ApkSet) MarshalJSON() ([]byte, error) {
896 type NoMethod ApkSet
897 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
898 }
899
900
901 type ApkTargeting struct {
902
903 AbiTargeting *AbiTargeting `json:"abiTargeting,omitempty"`
904
905 LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
906
907 MultiAbiTargeting *MultiAbiTargeting `json:"multiAbiTargeting,omitempty"`
908
909 ScreenDensityTargeting *ScreenDensityTargeting `json:"screenDensityTargeting,omitempty"`
910
911 SdkVersionTargeting *SdkVersionTargeting `json:"sdkVersionTargeting,omitempty"`
912
913
914 TextureCompressionFormatTargeting *TextureCompressionFormatTargeting `json:"textureCompressionFormatTargeting,omitempty"`
915
916
917
918
919
920 ForceSendFields []string `json:"-"`
921
922
923
924
925 NullFields []string `json:"-"`
926 }
927
928 func (s *ApkTargeting) MarshalJSON() ([]byte, error) {
929 type NoMethod ApkTargeting
930 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
931 }
932
933
934
935 type ApksAddExternallyHostedRequest struct {
936
937
938 ExternallyHostedApk *ExternallyHostedApk `json:"externallyHostedApk,omitempty"`
939
940
941
942
943
944 ForceSendFields []string `json:"-"`
945
946
947
948
949 NullFields []string `json:"-"`
950 }
951
952 func (s *ApksAddExternallyHostedRequest) MarshalJSON() ([]byte, error) {
953 type NoMethod ApksAddExternallyHostedRequest
954 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
955 }
956
957
958
959 type ApksAddExternallyHostedResponse struct {
960
961
962 ExternallyHostedApk *ExternallyHostedApk `json:"externallyHostedApk,omitempty"`
963
964
965 googleapi.ServerResponse `json:"-"`
966
967
968
969
970
971 ForceSendFields []string `json:"-"`
972
973
974
975
976 NullFields []string `json:"-"`
977 }
978
979 func (s *ApksAddExternallyHostedResponse) MarshalJSON() ([]byte, error) {
980 type NoMethod ApksAddExternallyHostedResponse
981 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
982 }
983
984
985 type ApksListResponse struct {
986
987 Apks []*Apk `json:"apks,omitempty"`
988
989 Kind string `json:"kind,omitempty"`
990
991
992 googleapi.ServerResponse `json:"-"`
993
994
995
996
997
998 ForceSendFields []string `json:"-"`
999
1000
1001
1002
1003 NullFields []string `json:"-"`
1004 }
1005
1006 func (s *ApksListResponse) MarshalJSON() ([]byte, error) {
1007 type NoMethod ApksListResponse
1008 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1009 }
1010
1011
1012 type AppDetails struct {
1013
1014 ContactEmail string `json:"contactEmail,omitempty"`
1015
1016 ContactPhone string `json:"contactPhone,omitempty"`
1017
1018 ContactWebsite string `json:"contactWebsite,omitempty"`
1019
1020 DefaultLanguage string `json:"defaultLanguage,omitempty"`
1021
1022
1023 googleapi.ServerResponse `json:"-"`
1024
1025
1026
1027
1028
1029 ForceSendFields []string `json:"-"`
1030
1031
1032
1033
1034 NullFields []string `json:"-"`
1035 }
1036
1037 func (s *AppDetails) MarshalJSON() ([]byte, error) {
1038 type NoMethod AppDetails
1039 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1040 }
1041
1042
1043 type AppEdit struct {
1044
1045
1046 ExpiryTimeSeconds string `json:"expiryTimeSeconds,omitempty"`
1047
1048
1049 Id string `json:"id,omitempty"`
1050
1051
1052 googleapi.ServerResponse `json:"-"`
1053
1054
1055
1056
1057
1058 ForceSendFields []string `json:"-"`
1059
1060
1061
1062
1063 NullFields []string `json:"-"`
1064 }
1065
1066 func (s *AppEdit) MarshalJSON() ([]byte, error) {
1067 type NoMethod AppEdit
1068 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1069 }
1070
1071
1072 type AppRecoveryAction struct {
1073
1074 AppRecoveryId int64 `json:"appRecoveryId,omitempty,string"`
1075
1076
1077 CancelTime string `json:"cancelTime,omitempty"`
1078
1079
1080 CreateTime string `json:"createTime,omitempty"`
1081
1082
1083 DeployTime string `json:"deployTime,omitempty"`
1084
1085
1086
1087 LastUpdateTime string `json:"lastUpdateTime,omitempty"`
1088
1089
1090
1091 RemoteInAppUpdateData *RemoteInAppUpdateData `json:"remoteInAppUpdateData,omitempty"`
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106 Status string `json:"status,omitempty"`
1107
1108
1109 Targeting *Targeting `json:"targeting,omitempty"`
1110
1111
1112 googleapi.ServerResponse `json:"-"`
1113
1114
1115
1116
1117
1118 ForceSendFields []string `json:"-"`
1119
1120
1121
1122
1123 NullFields []string `json:"-"`
1124 }
1125
1126 func (s *AppRecoveryAction) MarshalJSON() ([]byte, error) {
1127 type NoMethod AppRecoveryAction
1128 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1129 }
1130
1131
1132 type AppVersionList struct {
1133
1134 VersionCodes googleapi.Int64s `json:"versionCodes,omitempty"`
1135
1136
1137
1138
1139
1140 ForceSendFields []string `json:"-"`
1141
1142
1143
1144
1145 NullFields []string `json:"-"`
1146 }
1147
1148 func (s *AppVersionList) MarshalJSON() ([]byte, error) {
1149 type NoMethod AppVersionList
1150 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1151 }
1152
1153
1154 type AppVersionRange struct {
1155
1156 VersionCodeEnd int64 `json:"versionCodeEnd,omitempty,string"`
1157
1158 VersionCodeStart int64 `json:"versionCodeStart,omitempty,string"`
1159
1160
1161
1162
1163
1164 ForceSendFields []string `json:"-"`
1165
1166
1167
1168
1169 NullFields []string `json:"-"`
1170 }
1171
1172 func (s *AppVersionRange) MarshalJSON() ([]byte, error) {
1173 type NoMethod AppVersionRange
1174 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1175 }
1176
1177
1178
1179 type ArchiveSubscriptionRequest struct {
1180 }
1181
1182
1183 type AssetModuleMetadata struct {
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195 DeliveryType string `json:"deliveryType,omitempty"`
1196
1197 Name string `json:"name,omitempty"`
1198
1199
1200
1201
1202
1203 ForceSendFields []string `json:"-"`
1204
1205
1206
1207
1208 NullFields []string `json:"-"`
1209 }
1210
1211 func (s *AssetModuleMetadata) MarshalJSON() ([]byte, error) {
1212 type NoMethod AssetModuleMetadata
1213 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1214 }
1215
1216
1217 type AssetSliceSet struct {
1218
1219 ApkDescription []*ApkDescription `json:"apkDescription,omitempty"`
1220
1221 AssetModuleMetadata *AssetModuleMetadata `json:"assetModuleMetadata,omitempty"`
1222
1223
1224
1225
1226
1227 ForceSendFields []string `json:"-"`
1228
1229
1230
1231
1232 NullFields []string `json:"-"`
1233 }
1234
1235 func (s *AssetSliceSet) MarshalJSON() ([]byte, error) {
1236 type NoMethod AssetSliceSet
1237 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1238 }
1239
1240
1241
1242 type AutoRenewingBasePlanType struct {
1243
1244
1245
1246
1247 AccountHoldDuration string `json:"accountHoldDuration,omitempty"`
1248
1249
1250 BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"`
1251
1252
1253
1254
1255 GracePeriodDuration string `json:"gracePeriodDuration,omitempty"`
1256
1257
1258
1259
1260 LegacyCompatible bool `json:"legacyCompatible,omitempty"`
1261
1262
1263
1264
1265
1266
1267 LegacyCompatibleSubscriptionOfferId string `json:"legacyCompatibleSubscriptionOfferId,omitempty"`
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280 ProrationMode string `json:"prorationMode,omitempty"`
1281
1282
1283
1284
1285
1286
1287
1288
1289 ResubscribeState string `json:"resubscribeState,omitempty"`
1290
1291
1292
1293
1294
1295 ForceSendFields []string `json:"-"`
1296
1297
1298
1299
1300 NullFields []string `json:"-"`
1301 }
1302
1303 func (s *AutoRenewingBasePlanType) MarshalJSON() ([]byte, error) {
1304 type NoMethod AutoRenewingBasePlanType
1305 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1306 }
1307
1308
1309 type AutoRenewingPlan struct {
1310
1311
1312 AutoRenewEnabled bool `json:"autoRenewEnabled,omitempty"`
1313
1314
1315 InstallmentDetails *InstallmentPlan `json:"installmentDetails,omitempty"`
1316
1317
1318 PriceChangeDetails *SubscriptionItemPriceChangeDetails `json:"priceChangeDetails,omitempty"`
1319
1320
1321
1322
1323
1324 ForceSendFields []string `json:"-"`
1325
1326
1327
1328
1329 NullFields []string `json:"-"`
1330 }
1331
1332 func (s *AutoRenewingPlan) MarshalJSON() ([]byte, error) {
1333 type NoMethod AutoRenewingPlan
1334 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1335 }
1336
1337
1338 type BasePlan struct {
1339
1340
1341 AutoRenewingBasePlanType *AutoRenewingBasePlanType `json:"autoRenewingBasePlanType,omitempty"`
1342
1343
1344
1345
1346 BasePlanId string `json:"basePlanId,omitempty"`
1347
1348
1349 InstallmentsBasePlanType *InstallmentsBasePlanType `json:"installmentsBasePlanType,omitempty"`
1350
1351
1352
1353 OfferTags []*OfferTag `json:"offerTags,omitempty"`
1354
1355
1356
1357 OtherRegionsConfig *OtherRegionsBasePlanConfig `json:"otherRegionsConfig,omitempty"`
1358
1359
1360 PrepaidBasePlanType *PrepaidBasePlanType `json:"prepaidBasePlanType,omitempty"`
1361
1362 RegionalConfigs []*RegionalBasePlanConfig `json:"regionalConfigs,omitempty"`
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375 State string `json:"state,omitempty"`
1376
1377
1378
1379
1380
1381 ForceSendFields []string `json:"-"`
1382
1383
1384
1385
1386 NullFields []string `json:"-"`
1387 }
1388
1389 func (s *BasePlan) MarshalJSON() ([]byte, error) {
1390 type NoMethod BasePlan
1391 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1392 }
1393
1394
1395
1396 type BatchGetSubscriptionOffersRequest struct {
1397
1398
1399 Requests []*GetSubscriptionOfferRequest `json:"requests,omitempty"`
1400
1401
1402
1403
1404
1405 ForceSendFields []string `json:"-"`
1406
1407
1408
1409
1410 NullFields []string `json:"-"`
1411 }
1412
1413 func (s *BatchGetSubscriptionOffersRequest) MarshalJSON() ([]byte, error) {
1414 type NoMethod BatchGetSubscriptionOffersRequest
1415 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1416 }
1417
1418
1419
1420 type BatchGetSubscriptionOffersResponse struct {
1421 SubscriptionOffers []*SubscriptionOffer `json:"subscriptionOffers,omitempty"`
1422
1423
1424 googleapi.ServerResponse `json:"-"`
1425
1426
1427
1428
1429
1430 ForceSendFields []string `json:"-"`
1431
1432
1433
1434
1435 NullFields []string `json:"-"`
1436 }
1437
1438 func (s *BatchGetSubscriptionOffersResponse) MarshalJSON() ([]byte, error) {
1439 type NoMethod BatchGetSubscriptionOffersResponse
1440 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1441 }
1442
1443
1444
1445 type BatchGetSubscriptionsResponse struct {
1446
1447
1448 Subscriptions []*Subscription `json:"subscriptions,omitempty"`
1449
1450
1451 googleapi.ServerResponse `json:"-"`
1452
1453
1454
1455
1456
1457 ForceSendFields []string `json:"-"`
1458
1459
1460
1461
1462 NullFields []string `json:"-"`
1463 }
1464
1465 func (s *BatchGetSubscriptionsResponse) MarshalJSON() ([]byte, error) {
1466 type NoMethod BatchGetSubscriptionsResponse
1467 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1468 }
1469
1470
1471
1472 type BatchMigrateBasePlanPricesRequest struct {
1473
1474
1475 Requests []*MigrateBasePlanPricesRequest `json:"requests,omitempty"`
1476
1477
1478
1479
1480
1481 ForceSendFields []string `json:"-"`
1482
1483
1484
1485
1486 NullFields []string `json:"-"`
1487 }
1488
1489 func (s *BatchMigrateBasePlanPricesRequest) MarshalJSON() ([]byte, error) {
1490 type NoMethod BatchMigrateBasePlanPricesRequest
1491 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1492 }
1493
1494
1495
1496 type BatchMigrateBasePlanPricesResponse struct {
1497
1498
1499 Responses []*MigrateBasePlanPricesResponse `json:"responses,omitempty"`
1500
1501
1502 googleapi.ServerResponse `json:"-"`
1503
1504
1505
1506
1507
1508 ForceSendFields []string `json:"-"`
1509
1510
1511
1512
1513 NullFields []string `json:"-"`
1514 }
1515
1516 func (s *BatchMigrateBasePlanPricesResponse) MarshalJSON() ([]byte, error) {
1517 type NoMethod BatchMigrateBasePlanPricesResponse
1518 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1519 }
1520
1521
1522
1523 type BatchUpdateBasePlanStatesRequest struct {
1524
1525
1526 Requests []*UpdateBasePlanStateRequest `json:"requests,omitempty"`
1527
1528
1529
1530
1531
1532 ForceSendFields []string `json:"-"`
1533
1534
1535
1536
1537 NullFields []string `json:"-"`
1538 }
1539
1540 func (s *BatchUpdateBasePlanStatesRequest) MarshalJSON() ([]byte, error) {
1541 type NoMethod BatchUpdateBasePlanStatesRequest
1542 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1543 }
1544
1545
1546
1547 type BatchUpdateBasePlanStatesResponse struct {
1548
1549
1550 Subscriptions []*Subscription `json:"subscriptions,omitempty"`
1551
1552
1553 googleapi.ServerResponse `json:"-"`
1554
1555
1556
1557
1558
1559 ForceSendFields []string `json:"-"`
1560
1561
1562
1563
1564 NullFields []string `json:"-"`
1565 }
1566
1567 func (s *BatchUpdateBasePlanStatesResponse) MarshalJSON() ([]byte, error) {
1568 type NoMethod BatchUpdateBasePlanStatesResponse
1569 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1570 }
1571
1572
1573
1574 type BatchUpdateSubscriptionOfferStatesRequest struct {
1575
1576
1577 Requests []*UpdateSubscriptionOfferStateRequest `json:"requests,omitempty"`
1578
1579
1580
1581
1582
1583 ForceSendFields []string `json:"-"`
1584
1585
1586
1587
1588 NullFields []string `json:"-"`
1589 }
1590
1591 func (s *BatchUpdateSubscriptionOfferStatesRequest) MarshalJSON() ([]byte, error) {
1592 type NoMethod BatchUpdateSubscriptionOfferStatesRequest
1593 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1594 }
1595
1596
1597
1598 type BatchUpdateSubscriptionOfferStatesResponse struct {
1599
1600 SubscriptionOffers []*SubscriptionOffer `json:"subscriptionOffers,omitempty"`
1601
1602
1603 googleapi.ServerResponse `json:"-"`
1604
1605
1606
1607
1608
1609 ForceSendFields []string `json:"-"`
1610
1611
1612
1613
1614 NullFields []string `json:"-"`
1615 }
1616
1617 func (s *BatchUpdateSubscriptionOfferStatesResponse) MarshalJSON() ([]byte, error) {
1618 type NoMethod BatchUpdateSubscriptionOfferStatesResponse
1619 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1620 }
1621
1622
1623
1624 type BatchUpdateSubscriptionOffersRequest struct {
1625
1626
1627 Requests []*UpdateSubscriptionOfferRequest `json:"requests,omitempty"`
1628
1629
1630
1631
1632
1633 ForceSendFields []string `json:"-"`
1634
1635
1636
1637
1638 NullFields []string `json:"-"`
1639 }
1640
1641 func (s *BatchUpdateSubscriptionOffersRequest) MarshalJSON() ([]byte, error) {
1642 type NoMethod BatchUpdateSubscriptionOffersRequest
1643 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1644 }
1645
1646
1647
1648 type BatchUpdateSubscriptionOffersResponse struct {
1649
1650 SubscriptionOffers []*SubscriptionOffer `json:"subscriptionOffers,omitempty"`
1651
1652
1653 googleapi.ServerResponse `json:"-"`
1654
1655
1656
1657
1658
1659 ForceSendFields []string `json:"-"`
1660
1661
1662
1663
1664 NullFields []string `json:"-"`
1665 }
1666
1667 func (s *BatchUpdateSubscriptionOffersResponse) MarshalJSON() ([]byte, error) {
1668 type NoMethod BatchUpdateSubscriptionOffersResponse
1669 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1670 }
1671
1672
1673
1674 type BatchUpdateSubscriptionsRequest struct {
1675
1676
1677 Requests []*UpdateSubscriptionRequest `json:"requests,omitempty"`
1678
1679
1680
1681
1682
1683 ForceSendFields []string `json:"-"`
1684
1685
1686
1687
1688 NullFields []string `json:"-"`
1689 }
1690
1691 func (s *BatchUpdateSubscriptionsRequest) MarshalJSON() ([]byte, error) {
1692 type NoMethod BatchUpdateSubscriptionsRequest
1693 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1694 }
1695
1696
1697
1698 type BatchUpdateSubscriptionsResponse struct {
1699
1700 Subscriptions []*Subscription `json:"subscriptions,omitempty"`
1701
1702
1703 googleapi.ServerResponse `json:"-"`
1704
1705
1706
1707
1708
1709 ForceSendFields []string `json:"-"`
1710
1711
1712
1713
1714 NullFields []string `json:"-"`
1715 }
1716
1717 func (s *BatchUpdateSubscriptionsResponse) MarshalJSON() ([]byte, error) {
1718 type NoMethod BatchUpdateSubscriptionsResponse
1719 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1720 }
1721
1722
1723 type Bundle struct {
1724
1725
1726 Sha1 string `json:"sha1,omitempty"`
1727
1728
1729 Sha256 string `json:"sha256,omitempty"`
1730
1731
1732 VersionCode int64 `json:"versionCode,omitempty"`
1733
1734
1735 googleapi.ServerResponse `json:"-"`
1736
1737
1738
1739
1740
1741 ForceSendFields []string `json:"-"`
1742
1743
1744
1745
1746 NullFields []string `json:"-"`
1747 }
1748
1749 func (s *Bundle) MarshalJSON() ([]byte, error) {
1750 type NoMethod Bundle
1751 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1752 }
1753
1754
1755 type BundlesListResponse struct {
1756
1757 Bundles []*Bundle `json:"bundles,omitempty"`
1758
1759 Kind string `json:"kind,omitempty"`
1760
1761
1762 googleapi.ServerResponse `json:"-"`
1763
1764
1765
1766
1767
1768 ForceSendFields []string `json:"-"`
1769
1770
1771
1772
1773 NullFields []string `json:"-"`
1774 }
1775
1776 func (s *BundlesListResponse) MarshalJSON() ([]byte, error) {
1777 type NoMethod BundlesListResponse
1778 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1779 }
1780
1781
1782 type CancelAppRecoveryRequest struct {
1783 }
1784
1785
1786 type CancelAppRecoveryResponse struct {
1787
1788 googleapi.ServerResponse `json:"-"`
1789 }
1790
1791
1792
1793 type CancelSurveyResult struct {
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805 Reason string `json:"reason,omitempty"`
1806
1807
1808 ReasonUserInput string `json:"reasonUserInput,omitempty"`
1809
1810
1811
1812
1813
1814 ForceSendFields []string `json:"-"`
1815
1816
1817
1818
1819 NullFields []string `json:"-"`
1820 }
1821
1822 func (s *CancelSurveyResult) MarshalJSON() ([]byte, error) {
1823 type NoMethod CancelSurveyResult
1824 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1825 }
1826
1827
1828
1829 type CanceledStateContext struct {
1830
1831 DeveloperInitiatedCancellation *DeveloperInitiatedCancellation `json:"developerInitiatedCancellation,omitempty"`
1832
1833 ReplacementCancellation *ReplacementCancellation `json:"replacementCancellation,omitempty"`
1834
1835
1836 SystemInitiatedCancellation *SystemInitiatedCancellation `json:"systemInitiatedCancellation,omitempty"`
1837
1838 UserInitiatedCancellation *UserInitiatedCancellation `json:"userInitiatedCancellation,omitempty"`
1839
1840
1841
1842
1843
1844
1845 ForceSendFields []string `json:"-"`
1846
1847
1848
1849
1850 NullFields []string `json:"-"`
1851 }
1852
1853 func (s *CanceledStateContext) MarshalJSON() ([]byte, error) {
1854 type NoMethod CanceledStateContext
1855 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1856 }
1857
1858
1859 type Comment struct {
1860
1861 DeveloperComment *DeveloperComment `json:"developerComment,omitempty"`
1862
1863 UserComment *UserComment `json:"userComment,omitempty"`
1864
1865
1866
1867
1868
1869 ForceSendFields []string `json:"-"`
1870
1871
1872
1873
1874 NullFields []string `json:"-"`
1875 }
1876
1877 func (s *Comment) MarshalJSON() ([]byte, error) {
1878 type NoMethod Comment
1879 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1880 }
1881
1882
1883 type ConvertRegionPricesRequest struct {
1884
1885 Price *Money `json:"price,omitempty"`
1886
1887
1888
1889
1890
1891 ForceSendFields []string `json:"-"`
1892
1893
1894
1895
1896 NullFields []string `json:"-"`
1897 }
1898
1899 func (s *ConvertRegionPricesRequest) MarshalJSON() ([]byte, error) {
1900 type NoMethod ConvertRegionPricesRequest
1901 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1902 }
1903
1904
1905 type ConvertRegionPricesResponse struct {
1906
1907
1908 ConvertedOtherRegionsPrice *ConvertedOtherRegionsPrice `json:"convertedOtherRegionsPrice,omitempty"`
1909
1910 ConvertedRegionPrices map[string]ConvertedRegionPrice `json:"convertedRegionPrices,omitempty"`
1911
1912
1913 googleapi.ServerResponse `json:"-"`
1914
1915
1916
1917
1918
1919 ForceSendFields []string `json:"-"`
1920
1921
1922
1923
1924 NullFields []string `json:"-"`
1925 }
1926
1927 func (s *ConvertRegionPricesResponse) MarshalJSON() ([]byte, error) {
1928 type NoMethod ConvertRegionPricesResponse
1929 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1930 }
1931
1932
1933 type ConvertedOtherRegionsPrice struct {
1934
1935
1936 EurPrice *Money `json:"eurPrice,omitempty"`
1937
1938
1939 UsdPrice *Money `json:"usdPrice,omitempty"`
1940
1941
1942
1943
1944
1945 ForceSendFields []string `json:"-"`
1946
1947
1948
1949
1950 NullFields []string `json:"-"`
1951 }
1952
1953 func (s *ConvertedOtherRegionsPrice) MarshalJSON() ([]byte, error) {
1954 type NoMethod ConvertedOtherRegionsPrice
1955 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1956 }
1957
1958
1959 type ConvertedRegionPrice struct {
1960
1961 Price *Money `json:"price,omitempty"`
1962
1963 RegionCode string `json:"regionCode,omitempty"`
1964
1965 TaxAmount *Money `json:"taxAmount,omitempty"`
1966
1967
1968
1969
1970
1971 ForceSendFields []string `json:"-"`
1972
1973
1974
1975
1976 NullFields []string `json:"-"`
1977 }
1978
1979 func (s *ConvertedRegionPrice) MarshalJSON() ([]byte, error) {
1980 type NoMethod ConvertedRegionPrice
1981 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
1982 }
1983
1984
1985 type CountryTargeting struct {
1986
1987
1988 Countries []string `json:"countries,omitempty"`
1989
1990
1991 IncludeRestOfWorld bool `json:"includeRestOfWorld,omitempty"`
1992
1993
1994
1995
1996
1997 ForceSendFields []string `json:"-"`
1998
1999
2000
2001
2002 NullFields []string `json:"-"`
2003 }
2004
2005 func (s *CountryTargeting) MarshalJSON() ([]byte, error) {
2006 type NoMethod CountryTargeting
2007 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2008 }
2009
2010
2011 type CreateDraftAppRecoveryRequest struct {
2012
2013
2014
2015 RemoteInAppUpdate *RemoteInAppUpdate `json:"remoteInAppUpdate,omitempty"`
2016
2017
2018 Targeting *Targeting `json:"targeting,omitempty"`
2019
2020
2021
2022
2023
2024 ForceSendFields []string `json:"-"`
2025
2026
2027
2028
2029 NullFields []string `json:"-"`
2030 }
2031
2032 func (s *CreateDraftAppRecoveryRequest) MarshalJSON() ([]byte, error) {
2033 type NoMethod CreateDraftAppRecoveryRequest
2034 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2035 }
2036
2037
2038 type DeactivateBasePlanRequest struct {
2039
2040
2041 BasePlanId string `json:"basePlanId,omitempty"`
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054 LatencyTolerance string `json:"latencyTolerance,omitempty"`
2055
2056
2057 PackageName string `json:"packageName,omitempty"`
2058
2059
2060 ProductId string `json:"productId,omitempty"`
2061
2062
2063
2064
2065
2066 ForceSendFields []string `json:"-"`
2067
2068
2069
2070
2071 NullFields []string `json:"-"`
2072 }
2073
2074 func (s *DeactivateBasePlanRequest) MarshalJSON() ([]byte, error) {
2075 type NoMethod DeactivateBasePlanRequest
2076 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2077 }
2078
2079
2080
2081 type DeactivateSubscriptionOfferRequest struct {
2082
2083 BasePlanId string `json:"basePlanId,omitempty"`
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096 LatencyTolerance string `json:"latencyTolerance,omitempty"`
2097
2098 OfferId string `json:"offerId,omitempty"`
2099
2100
2101 PackageName string `json:"packageName,omitempty"`
2102
2103
2104 ProductId string `json:"productId,omitempty"`
2105
2106
2107
2108
2109
2110 ForceSendFields []string `json:"-"`
2111
2112
2113
2114
2115 NullFields []string `json:"-"`
2116 }
2117
2118 func (s *DeactivateSubscriptionOfferRequest) MarshalJSON() ([]byte, error) {
2119 type NoMethod DeactivateSubscriptionOfferRequest
2120 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2121 }
2122
2123
2124 type DeferredItemReplacement struct {
2125
2126 ProductId string `json:"productId,omitempty"`
2127
2128
2129
2130
2131
2132 ForceSendFields []string `json:"-"`
2133
2134
2135
2136
2137 NullFields []string `json:"-"`
2138 }
2139
2140 func (s *DeferredItemReplacement) MarshalJSON() ([]byte, error) {
2141 type NoMethod DeferredItemReplacement
2142 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2143 }
2144
2145
2146 type DeobfuscationFile struct {
2147
2148
2149
2150
2151
2152
2153 SymbolType string `json:"symbolType,omitempty"`
2154
2155
2156
2157
2158
2159 ForceSendFields []string `json:"-"`
2160
2161
2162
2163
2164 NullFields []string `json:"-"`
2165 }
2166
2167 func (s *DeobfuscationFile) MarshalJSON() ([]byte, error) {
2168 type NoMethod DeobfuscationFile
2169 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2170 }
2171
2172
2173 type DeobfuscationFilesUploadResponse struct {
2174
2175 DeobfuscationFile *DeobfuscationFile `json:"deobfuscationFile,omitempty"`
2176
2177
2178 googleapi.ServerResponse `json:"-"`
2179
2180
2181
2182
2183
2184 ForceSendFields []string `json:"-"`
2185
2186
2187
2188
2189 NullFields []string `json:"-"`
2190 }
2191
2192 func (s *DeobfuscationFilesUploadResponse) MarshalJSON() ([]byte, error) {
2193 type NoMethod DeobfuscationFilesUploadResponse
2194 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2195 }
2196
2197
2198 type DeployAppRecoveryRequest struct {
2199 }
2200
2201
2202 type DeployAppRecoveryResponse struct {
2203
2204 googleapi.ServerResponse `json:"-"`
2205 }
2206
2207
2208
2209 type DeveloperComment struct {
2210
2211 LastModified *Timestamp `json:"lastModified,omitempty"`
2212
2213 Text string `json:"text,omitempty"`
2214
2215
2216
2217
2218
2219 ForceSendFields []string `json:"-"`
2220
2221
2222
2223
2224 NullFields []string `json:"-"`
2225 }
2226
2227 func (s *DeveloperComment) MarshalJSON() ([]byte, error) {
2228 type NoMethod DeveloperComment
2229 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2230 }
2231
2232
2233
2234 type DeveloperInitiatedCancellation struct {
2235 }
2236
2237
2238 type DeviceFeature struct {
2239
2240 FeatureName string `json:"featureName,omitempty"`
2241
2242
2243 FeatureVersion int64 `json:"featureVersion,omitempty"`
2244
2245
2246
2247
2248
2249 ForceSendFields []string `json:"-"`
2250
2251
2252
2253
2254 NullFields []string `json:"-"`
2255 }
2256
2257 func (s *DeviceFeature) MarshalJSON() ([]byte, error) {
2258 type NoMethod DeviceFeature
2259 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2260 }
2261
2262
2263 type DeviceFeatureTargeting struct {
2264
2265 RequiredFeature *DeviceFeature `json:"requiredFeature,omitempty"`
2266
2267
2268
2269
2270
2271 ForceSendFields []string `json:"-"`
2272
2273
2274
2275
2276 NullFields []string `json:"-"`
2277 }
2278
2279 func (s *DeviceFeatureTargeting) MarshalJSON() ([]byte, error) {
2280 type NoMethod DeviceFeatureTargeting
2281 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2282 }
2283
2284
2285
2286
2287 type DeviceGroup struct {
2288
2289
2290 DeviceSelectors []*DeviceSelector `json:"deviceSelectors,omitempty"`
2291
2292 Name string `json:"name,omitempty"`
2293
2294
2295
2296
2297
2298 ForceSendFields []string `json:"-"`
2299
2300
2301
2302
2303 NullFields []string `json:"-"`
2304 }
2305
2306 func (s *DeviceGroup) MarshalJSON() ([]byte, error) {
2307 type NoMethod DeviceGroup
2308 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2309 }
2310
2311
2312 type DeviceId struct {
2313
2314 BuildBrand string `json:"buildBrand,omitempty"`
2315
2316 BuildDevice string `json:"buildDevice,omitempty"`
2317
2318
2319
2320
2321
2322 ForceSendFields []string `json:"-"`
2323
2324
2325
2326
2327 NullFields []string `json:"-"`
2328 }
2329
2330 func (s *DeviceId) MarshalJSON() ([]byte, error) {
2331 type NoMethod DeviceId
2332 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2333 }
2334
2335
2336 type DeviceMetadata struct {
2337
2338 CpuMake string `json:"cpuMake,omitempty"`
2339
2340 CpuModel string `json:"cpuModel,omitempty"`
2341
2342 DeviceClass string `json:"deviceClass,omitempty"`
2343
2344 GlEsVersion int64 `json:"glEsVersion,omitempty"`
2345
2346 Manufacturer string `json:"manufacturer,omitempty"`
2347
2348
2349 NativePlatform string `json:"nativePlatform,omitempty"`
2350
2351 ProductName string `json:"productName,omitempty"`
2352
2353 RamMb int64 `json:"ramMb,omitempty"`
2354
2355 ScreenDensityDpi int64 `json:"screenDensityDpi,omitempty"`
2356
2357 ScreenHeightPx int64 `json:"screenHeightPx,omitempty"`
2358
2359 ScreenWidthPx int64 `json:"screenWidthPx,omitempty"`
2360
2361
2362
2363
2364
2365 ForceSendFields []string `json:"-"`
2366
2367
2368
2369
2370 NullFields []string `json:"-"`
2371 }
2372
2373 func (s *DeviceMetadata) MarshalJSON() ([]byte, error) {
2374 type NoMethod DeviceMetadata
2375 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2376 }
2377
2378
2379 type DeviceRam struct {
2380
2381 MaxBytes int64 `json:"maxBytes,omitempty,string"`
2382
2383 MinBytes int64 `json:"minBytes,omitempty,string"`
2384
2385
2386
2387
2388
2389 ForceSendFields []string `json:"-"`
2390
2391
2392
2393
2394 NullFields []string `json:"-"`
2395 }
2396
2397 func (s *DeviceRam) MarshalJSON() ([]byte, error) {
2398 type NoMethod DeviceRam
2399 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2400 }
2401
2402
2403
2404
2405
2406
2407
2408
2409 type DeviceSelector struct {
2410
2411 DeviceRam *DeviceRam `json:"deviceRam,omitempty"`
2412
2413
2414 ExcludedDeviceIds []*DeviceId `json:"excludedDeviceIds,omitempty"`
2415
2416
2417 ForbiddenSystemFeatures []*SystemFeature `json:"forbiddenSystemFeatures,omitempty"`
2418
2419 IncludedDeviceIds []*DeviceId `json:"includedDeviceIds,omitempty"`
2420
2421
2422 RequiredSystemFeatures []*SystemFeature `json:"requiredSystemFeatures,omitempty"`
2423
2424
2425
2426
2427
2428 ForceSendFields []string `json:"-"`
2429
2430
2431
2432
2433 NullFields []string `json:"-"`
2434 }
2435
2436 func (s *DeviceSelector) MarshalJSON() ([]byte, error) {
2437 type NoMethod DeviceSelector
2438 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2439 }
2440
2441
2442 type DeviceSpec struct {
2443
2444 ScreenDensity int64 `json:"screenDensity,omitempty"`
2445
2446
2447
2448 SupportedAbis []string `json:"supportedAbis,omitempty"`
2449
2450
2451 SupportedLocales []string `json:"supportedLocales,omitempty"`
2452
2453
2454
2455
2456
2457 ForceSendFields []string `json:"-"`
2458
2459
2460
2461
2462 NullFields []string `json:"-"`
2463 }
2464
2465 func (s *DeviceSpec) MarshalJSON() ([]byte, error) {
2466 type NoMethod DeviceSpec
2467 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2468 }
2469
2470
2471
2472 type DeviceTier struct {
2473
2474
2475 DeviceGroupNames []string `json:"deviceGroupNames,omitempty"`
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485 Level int64 `json:"level,omitempty"`
2486
2487
2488
2489
2490
2491 ForceSendFields []string `json:"-"`
2492
2493
2494
2495
2496 NullFields []string `json:"-"`
2497 }
2498
2499 func (s *DeviceTier) MarshalJSON() ([]byte, error) {
2500 type NoMethod DeviceTier
2501 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2502 }
2503
2504
2505
2506 type DeviceTierConfig struct {
2507
2508 DeviceGroups []*DeviceGroup `json:"deviceGroups,omitempty"`
2509
2510 DeviceTierConfigId int64 `json:"deviceTierConfigId,omitempty,string"`
2511
2512 DeviceTierSet *DeviceTierSet `json:"deviceTierSet,omitempty"`
2513
2514 UserCountrySets []*UserCountrySet `json:"userCountrySets,omitempty"`
2515
2516
2517 googleapi.ServerResponse `json:"-"`
2518
2519
2520
2521
2522
2523 ForceSendFields []string `json:"-"`
2524
2525
2526
2527
2528 NullFields []string `json:"-"`
2529 }
2530
2531 func (s *DeviceTierConfig) MarshalJSON() ([]byte, error) {
2532 type NoMethod DeviceTierConfig
2533 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2534 }
2535
2536
2537
2538
2539
2540
2541 type DeviceTierSet struct {
2542
2543 DeviceTiers []*DeviceTier `json:"deviceTiers,omitempty"`
2544
2545
2546
2547
2548
2549 ForceSendFields []string `json:"-"`
2550
2551
2552
2553
2554 NullFields []string `json:"-"`
2555 }
2556
2557 func (s *DeviceTierSet) MarshalJSON() ([]byte, error) {
2558 type NoMethod DeviceTierSet
2559 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2560 }
2561
2562
2563 type ExpansionFile struct {
2564
2565
2566
2567 FileSize int64 `json:"fileSize,omitempty,string"`
2568
2569
2570 ReferencesVersion int64 `json:"referencesVersion,omitempty"`
2571
2572
2573 googleapi.ServerResponse `json:"-"`
2574
2575
2576
2577
2578
2579 ForceSendFields []string `json:"-"`
2580
2581
2582
2583
2584 NullFields []string `json:"-"`
2585 }
2586
2587 func (s *ExpansionFile) MarshalJSON() ([]byte, error) {
2588 type NoMethod ExpansionFile
2589 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2590 }
2591
2592
2593 type ExpansionFilesUploadResponse struct {
2594
2595 ExpansionFile *ExpansionFile `json:"expansionFile,omitempty"`
2596
2597
2598 googleapi.ServerResponse `json:"-"`
2599
2600
2601
2602
2603
2604 ForceSendFields []string `json:"-"`
2605
2606
2607
2608
2609 NullFields []string `json:"-"`
2610 }
2611
2612 func (s *ExpansionFilesUploadResponse) MarshalJSON() ([]byte, error) {
2613 type NoMethod ExpansionFilesUploadResponse
2614 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2615 }
2616
2617
2618
2619 type ExternalAccountIdentifiers struct {
2620
2621
2622
2623 ExternalAccountId string `json:"externalAccountId,omitempty"`
2624
2625
2626
2627
2628
2629
2630 ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"`
2631
2632
2633
2634
2635
2636 ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"`
2637
2638
2639
2640
2641
2642 ForceSendFields []string `json:"-"`
2643
2644
2645
2646
2647 NullFields []string `json:"-"`
2648 }
2649
2650 func (s *ExternalAccountIdentifiers) MarshalJSON() ([]byte, error) {
2651 type NoMethod ExternalAccountIdentifiers
2652 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2653 }
2654
2655
2656 type ExternalSubscription struct {
2657
2658
2659
2660
2661
2662
2663
2664 SubscriptionType string `json:"subscriptionType,omitempty"`
2665
2666
2667
2668
2669
2670 ForceSendFields []string `json:"-"`
2671
2672
2673
2674
2675 NullFields []string `json:"-"`
2676 }
2677
2678 func (s *ExternalSubscription) MarshalJSON() ([]byte, error) {
2679 type NoMethod ExternalSubscription
2680 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2681 }
2682
2683
2684 type ExternalTransaction struct {
2685
2686
2687 CreateTime string `json:"createTime,omitempty"`
2688
2689
2690
2691 CurrentPreTaxAmount *Price `json:"currentPreTaxAmount,omitempty"`
2692
2693
2694
2695 CurrentTaxAmount *Price `json:"currentTaxAmount,omitempty"`
2696
2697
2698
2699 ExternalTransactionId string `json:"externalTransactionId,omitempty"`
2700
2701
2702 OneTimeTransaction *OneTimeExternalTransaction `json:"oneTimeTransaction,omitempty"`
2703
2704
2705
2706 OriginalPreTaxAmount *Price `json:"originalPreTaxAmount,omitempty"`
2707
2708
2709 OriginalTaxAmount *Price `json:"originalTaxAmount,omitempty"`
2710
2711
2712
2713 PackageName string `json:"packageName,omitempty"`
2714
2715
2716 RecurringTransaction *RecurringExternalTransaction `json:"recurringTransaction,omitempty"`
2717
2718
2719 TestPurchase *ExternalTransactionTestPurchase `json:"testPurchase,omitempty"`
2720
2721
2722
2723
2724
2725
2726
2727 TransactionState string `json:"transactionState,omitempty"`
2728
2729 TransactionTime string `json:"transactionTime,omitempty"`
2730
2731 UserTaxAddress *ExternalTransactionAddress `json:"userTaxAddress,omitempty"`
2732
2733
2734 googleapi.ServerResponse `json:"-"`
2735
2736
2737
2738
2739
2740 ForceSendFields []string `json:"-"`
2741
2742
2743
2744
2745 NullFields []string `json:"-"`
2746 }
2747
2748 func (s *ExternalTransaction) MarshalJSON() ([]byte, error) {
2749 type NoMethod ExternalTransaction
2750 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2751 }
2752
2753
2754 type ExternalTransactionAddress struct {
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765 AdministrativeArea string `json:"administrativeArea,omitempty"`
2766
2767
2768 RegionCode string `json:"regionCode,omitempty"`
2769
2770
2771
2772
2773
2774 ForceSendFields []string `json:"-"`
2775
2776
2777
2778
2779 NullFields []string `json:"-"`
2780 }
2781
2782 func (s *ExternalTransactionAddress) MarshalJSON() ([]byte, error) {
2783 type NoMethod ExternalTransactionAddress
2784 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2785 }
2786
2787
2788
2789 type ExternalTransactionTestPurchase struct {
2790 }
2791
2792
2793
2794
2795
2796 type ExternallyHostedApk struct {
2797
2798 ApplicationLabel string `json:"applicationLabel,omitempty"`
2799
2800
2801
2802 CertificateBase64s []string `json:"certificateBase64s,omitempty"`
2803
2804
2805 ExternallyHostedUrl string `json:"externallyHostedUrl,omitempty"`
2806
2807
2808 FileSha1Base64 string `json:"fileSha1Base64,omitempty"`
2809
2810
2811 FileSha256Base64 string `json:"fileSha256Base64,omitempty"`
2812
2813 FileSize int64 `json:"fileSize,omitempty,string"`
2814
2815 IconBase64 string `json:"iconBase64,omitempty"`
2816
2817 MaximumSdk int64 `json:"maximumSdk,omitempty"`
2818
2819 MinimumSdk int64 `json:"minimumSdk,omitempty"`
2820
2821 NativeCodes []string `json:"nativeCodes,omitempty"`
2822
2823 PackageName string `json:"packageName,omitempty"`
2824
2825 UsesFeatures []string `json:"usesFeatures,omitempty"`
2826
2827 UsesPermissions []*UsesPermission `json:"usesPermissions,omitempty"`
2828
2829 VersionCode int64 `json:"versionCode,omitempty"`
2830
2831 VersionName string `json:"versionName,omitempty"`
2832
2833
2834
2835
2836
2837 ForceSendFields []string `json:"-"`
2838
2839
2840
2841
2842 NullFields []string `json:"-"`
2843 }
2844
2845 func (s *ExternallyHostedApk) MarshalJSON() ([]byte, error) {
2846 type NoMethod ExternallyHostedApk
2847 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2848 }
2849
2850
2851 type FullRefund struct {
2852 }
2853
2854
2855 type GeneratedApksListResponse struct {
2856
2857 GeneratedApks []*GeneratedApksPerSigningKey `json:"generatedApks,omitempty"`
2858
2859
2860 googleapi.ServerResponse `json:"-"`
2861
2862
2863
2864
2865
2866 ForceSendFields []string `json:"-"`
2867
2868
2869
2870
2871 NullFields []string `json:"-"`
2872 }
2873
2874 func (s *GeneratedApksListResponse) MarshalJSON() ([]byte, error) {
2875 type NoMethod GeneratedApksListResponse
2876 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2877 }
2878
2879
2880
2881 type GeneratedApksPerSigningKey struct {
2882
2883
2884 CertificateSha256Hash string `json:"certificateSha256Hash,omitempty"`
2885
2886
2887 GeneratedAssetPackSlices []*GeneratedAssetPackSlice `json:"generatedAssetPackSlices,omitempty"`
2888
2889
2890
2891
2892 GeneratedRecoveryModules []*GeneratedRecoveryApk `json:"generatedRecoveryModules,omitempty"`
2893
2894
2895 GeneratedSplitApks []*GeneratedSplitApk `json:"generatedSplitApks,omitempty"`
2896
2897
2898 GeneratedStandaloneApks []*GeneratedStandaloneApk `json:"generatedStandaloneApks,omitempty"`
2899
2900
2901
2902 GeneratedUniversalApk *GeneratedUniversalApk `json:"generatedUniversalApk,omitempty"`
2903
2904 TargetingInfo *TargetingInfo `json:"targetingInfo,omitempty"`
2905
2906
2907
2908
2909
2910 ForceSendFields []string `json:"-"`
2911
2912
2913
2914
2915 NullFields []string `json:"-"`
2916 }
2917
2918 func (s *GeneratedApksPerSigningKey) MarshalJSON() ([]byte, error) {
2919 type NoMethod GeneratedApksPerSigningKey
2920 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2921 }
2922
2923
2924 type GeneratedAssetPackSlice struct {
2925
2926
2927 DownloadId string `json:"downloadId,omitempty"`
2928
2929 ModuleName string `json:"moduleName,omitempty"`
2930
2931 SliceId string `json:"sliceId,omitempty"`
2932
2933 Version int64 `json:"version,omitempty,string"`
2934
2935
2936
2937
2938
2939 ForceSendFields []string `json:"-"`
2940
2941
2942
2943
2944 NullFields []string `json:"-"`
2945 }
2946
2947 func (s *GeneratedAssetPackSlice) MarshalJSON() ([]byte, error) {
2948 type NoMethod GeneratedAssetPackSlice
2949 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2950 }
2951
2952
2953 type GeneratedRecoveryApk struct {
2954
2955
2956 DownloadId string `json:"downloadId,omitempty"`
2957
2958 ModuleName string `json:"moduleName,omitempty"`
2959
2960 RecoveryId int64 `json:"recoveryId,omitempty,string"`
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976 RecoveryStatus string `json:"recoveryStatus,omitempty"`
2977
2978
2979
2980
2981
2982 ForceSendFields []string `json:"-"`
2983
2984
2985
2986
2987 NullFields []string `json:"-"`
2988 }
2989
2990 func (s *GeneratedRecoveryApk) MarshalJSON() ([]byte, error) {
2991 type NoMethod GeneratedRecoveryApk
2992 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
2993 }
2994
2995
2996 type GeneratedSplitApk struct {
2997
2998
2999 DownloadId string `json:"downloadId,omitempty"`
3000
3001 ModuleName string `json:"moduleName,omitempty"`
3002
3003 SplitId string `json:"splitId,omitempty"`
3004
3005 VariantId int64 `json:"variantId,omitempty"`
3006
3007
3008
3009
3010
3011 ForceSendFields []string `json:"-"`
3012
3013
3014
3015
3016 NullFields []string `json:"-"`
3017 }
3018
3019 func (s *GeneratedSplitApk) MarshalJSON() ([]byte, error) {
3020 type NoMethod GeneratedSplitApk
3021 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3022 }
3023
3024
3025 type GeneratedStandaloneApk struct {
3026
3027
3028 DownloadId string `json:"downloadId,omitempty"`
3029
3030 VariantId int64 `json:"variantId,omitempty"`
3031
3032
3033
3034
3035
3036 ForceSendFields []string `json:"-"`
3037
3038
3039
3040
3041 NullFields []string `json:"-"`
3042 }
3043
3044 func (s *GeneratedStandaloneApk) MarshalJSON() ([]byte, error) {
3045 type NoMethod GeneratedStandaloneApk
3046 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3047 }
3048
3049
3050 type GeneratedUniversalApk struct {
3051
3052
3053 DownloadId string `json:"downloadId,omitempty"`
3054
3055
3056
3057
3058
3059 ForceSendFields []string `json:"-"`
3060
3061
3062
3063
3064 NullFields []string `json:"-"`
3065 }
3066
3067 func (s *GeneratedUniversalApk) MarshalJSON() ([]byte, error) {
3068 type NoMethod GeneratedUniversalApk
3069 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3070 }
3071
3072
3073 type GetSubscriptionOfferRequest struct {
3074
3075 BasePlanId string `json:"basePlanId,omitempty"`
3076
3077 OfferId string `json:"offerId,omitempty"`
3078
3079 PackageName string `json:"packageName,omitempty"`
3080
3081 ProductId string `json:"productId,omitempty"`
3082
3083
3084
3085
3086
3087 ForceSendFields []string `json:"-"`
3088
3089
3090
3091
3092 NullFields []string `json:"-"`
3093 }
3094
3095 func (s *GetSubscriptionOfferRequest) MarshalJSON() ([]byte, error) {
3096 type NoMethod GetSubscriptionOfferRequest
3097 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3098 }
3099
3100
3101 type Grant struct {
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124 AppLevelPermissions []string `json:"appLevelPermissions,omitempty"`
3125
3126
3127
3128
3129 Name string `json:"name,omitempty"`
3130
3131
3132 PackageName string `json:"packageName,omitempty"`
3133
3134
3135 googleapi.ServerResponse `json:"-"`
3136
3137
3138
3139
3140
3141 ForceSendFields []string `json:"-"`
3142
3143
3144
3145
3146 NullFields []string `json:"-"`
3147 }
3148
3149 func (s *Grant) MarshalJSON() ([]byte, error) {
3150 type NoMethod Grant
3151 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3152 }
3153
3154
3155 type Image struct {
3156
3157 Id string `json:"id,omitempty"`
3158
3159 Sha1 string `json:"sha1,omitempty"`
3160
3161 Sha256 string `json:"sha256,omitempty"`
3162
3163 Url string `json:"url,omitempty"`
3164
3165
3166
3167
3168
3169 ForceSendFields []string `json:"-"`
3170
3171
3172
3173
3174 NullFields []string `json:"-"`
3175 }
3176
3177 func (s *Image) MarshalJSON() ([]byte, error) {
3178 type NoMethod Image
3179 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3180 }
3181
3182
3183 type ImagesDeleteAllResponse struct {
3184
3185 Deleted []*Image `json:"deleted,omitempty"`
3186
3187
3188 googleapi.ServerResponse `json:"-"`
3189
3190
3191
3192
3193
3194 ForceSendFields []string `json:"-"`
3195
3196
3197
3198
3199 NullFields []string `json:"-"`
3200 }
3201
3202 func (s *ImagesDeleteAllResponse) MarshalJSON() ([]byte, error) {
3203 type NoMethod ImagesDeleteAllResponse
3204 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3205 }
3206
3207
3208 type ImagesListResponse struct {
3209
3210 Images []*Image `json:"images,omitempty"`
3211
3212
3213 googleapi.ServerResponse `json:"-"`
3214
3215
3216
3217
3218
3219 ForceSendFields []string `json:"-"`
3220
3221
3222
3223
3224 NullFields []string `json:"-"`
3225 }
3226
3227 func (s *ImagesListResponse) MarshalJSON() ([]byte, error) {
3228 type NoMethod ImagesListResponse
3229 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3230 }
3231
3232
3233 type ImagesUploadResponse struct {
3234
3235 Image *Image `json:"image,omitempty"`
3236
3237
3238 googleapi.ServerResponse `json:"-"`
3239
3240
3241
3242
3243
3244 ForceSendFields []string `json:"-"`
3245
3246
3247
3248
3249 NullFields []string `json:"-"`
3250 }
3251
3252 func (s *ImagesUploadResponse) MarshalJSON() ([]byte, error) {
3253 type NoMethod ImagesUploadResponse
3254 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3255 }
3256
3257
3258 type InAppProduct struct {
3259
3260
3261 DefaultLanguage string `json:"defaultLanguage,omitempty"`
3262
3263
3264 DefaultPrice *Price `json:"defaultPrice,omitempty"`
3265
3266
3267
3268
3269
3270 GracePeriod string `json:"gracePeriod,omitempty"`
3271
3272
3273 Listings map[string]InAppProductListing `json:"listings,omitempty"`
3274
3275
3276 ManagedProductTaxesAndComplianceSettings *ManagedProductTaxAndComplianceSettings `json:"managedProductTaxesAndComplianceSettings,omitempty"`
3277
3278 PackageName string `json:"packageName,omitempty"`
3279
3280
3281 Prices map[string]Price `json:"prices,omitempty"`
3282
3283
3284
3285
3286
3287
3288 PurchaseType string `json:"purchaseType,omitempty"`
3289
3290 Sku string `json:"sku,omitempty"`
3291
3292
3293
3294
3295
3296
3297
3298 Status string `json:"status,omitempty"`
3299
3300
3301
3302 SubscriptionPeriod string `json:"subscriptionPeriod,omitempty"`
3303
3304
3305 SubscriptionTaxesAndComplianceSettings *SubscriptionTaxAndComplianceSettings `json:"subscriptionTaxesAndComplianceSettings,omitempty"`
3306
3307
3308 TrialPeriod string `json:"trialPeriod,omitempty"`
3309
3310
3311 googleapi.ServerResponse `json:"-"`
3312
3313
3314
3315
3316
3317 ForceSendFields []string `json:"-"`
3318
3319
3320
3321
3322 NullFields []string `json:"-"`
3323 }
3324
3325 func (s *InAppProduct) MarshalJSON() ([]byte, error) {
3326 type NoMethod InAppProduct
3327 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3328 }
3329
3330
3331 type InAppProductListing struct {
3332
3333 Benefits []string `json:"benefits,omitempty"`
3334
3335 Description string `json:"description,omitempty"`
3336
3337 Title string `json:"title,omitempty"`
3338
3339
3340
3341
3342
3343 ForceSendFields []string `json:"-"`
3344
3345
3346
3347
3348 NullFields []string `json:"-"`
3349 }
3350
3351 func (s *InAppProductListing) MarshalJSON() ([]byte, error) {
3352 type NoMethod InAppProductListing
3353 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3354 }
3355
3356
3357 type InappproductsBatchDeleteRequest struct {
3358
3359
3360
3361 Requests []*InappproductsDeleteRequest `json:"requests,omitempty"`
3362
3363
3364
3365
3366
3367 ForceSendFields []string `json:"-"`
3368
3369
3370
3371
3372 NullFields []string `json:"-"`
3373 }
3374
3375 func (s *InappproductsBatchDeleteRequest) MarshalJSON() ([]byte, error) {
3376 type NoMethod InappproductsBatchDeleteRequest
3377 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3378 }
3379
3380
3381
3382 type InappproductsBatchGetResponse struct {
3383
3384
3385 Inappproduct []*InAppProduct `json:"inappproduct,omitempty"`
3386
3387
3388 googleapi.ServerResponse `json:"-"`
3389
3390
3391
3392
3393
3394 ForceSendFields []string `json:"-"`
3395
3396
3397
3398
3399 NullFields []string `json:"-"`
3400 }
3401
3402 func (s *InappproductsBatchGetResponse) MarshalJSON() ([]byte, error) {
3403 type NoMethod InappproductsBatchGetResponse
3404 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3405 }
3406
3407
3408
3409 type InappproductsBatchUpdateRequest struct {
3410
3411
3412
3413 Requests []*InappproductsUpdateRequest `json:"requests,omitempty"`
3414
3415
3416
3417
3418
3419 ForceSendFields []string `json:"-"`
3420
3421
3422
3423
3424 NullFields []string `json:"-"`
3425 }
3426
3427 func (s *InappproductsBatchUpdateRequest) MarshalJSON() ([]byte, error) {
3428 type NoMethod InappproductsBatchUpdateRequest
3429 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3430 }
3431
3432
3433
3434 type InappproductsBatchUpdateResponse struct {
3435
3436 Inappproducts []*InAppProduct `json:"inappproducts,omitempty"`
3437
3438
3439 googleapi.ServerResponse `json:"-"`
3440
3441
3442
3443
3444
3445 ForceSendFields []string `json:"-"`
3446
3447
3448
3449
3450 NullFields []string `json:"-"`
3451 }
3452
3453 func (s *InappproductsBatchUpdateResponse) MarshalJSON() ([]byte, error) {
3454 type NoMethod InappproductsBatchUpdateResponse
3455 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3456 }
3457
3458
3459 type InappproductsDeleteRequest struct {
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472 LatencyTolerance string `json:"latencyTolerance,omitempty"`
3473
3474 PackageName string `json:"packageName,omitempty"`
3475
3476 Sku string `json:"sku,omitempty"`
3477
3478
3479
3480
3481
3482 ForceSendFields []string `json:"-"`
3483
3484
3485
3486
3487 NullFields []string `json:"-"`
3488 }
3489
3490 func (s *InappproductsDeleteRequest) MarshalJSON() ([]byte, error) {
3491 type NoMethod InappproductsDeleteRequest
3492 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3493 }
3494
3495
3496 type InappproductsListResponse struct {
3497
3498 Inappproduct []*InAppProduct `json:"inappproduct,omitempty"`
3499
3500
3501 Kind string `json:"kind,omitempty"`
3502
3503 PageInfo *PageInfo `json:"pageInfo,omitempty"`
3504
3505
3506 TokenPagination *TokenPagination `json:"tokenPagination,omitempty"`
3507
3508
3509 googleapi.ServerResponse `json:"-"`
3510
3511
3512
3513
3514
3515 ForceSendFields []string `json:"-"`
3516
3517
3518
3519
3520 NullFields []string `json:"-"`
3521 }
3522
3523 func (s *InappproductsListResponse) MarshalJSON() ([]byte, error) {
3524 type NoMethod InappproductsListResponse
3525 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3526 }
3527
3528
3529 type InappproductsUpdateRequest struct {
3530
3531
3532 AllowMissing bool `json:"allowMissing,omitempty"`
3533
3534
3535
3536
3537 AutoConvertMissingPrices bool `json:"autoConvertMissingPrices,omitempty"`
3538
3539 Inappproduct *InAppProduct `json:"inappproduct,omitempty"`
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552 LatencyTolerance string `json:"latencyTolerance,omitempty"`
3553
3554 PackageName string `json:"packageName,omitempty"`
3555
3556 Sku string `json:"sku,omitempty"`
3557
3558
3559
3560
3561
3562 ForceSendFields []string `json:"-"`
3563
3564
3565
3566
3567 NullFields []string `json:"-"`
3568 }
3569
3570 func (s *InappproductsUpdateRequest) MarshalJSON() ([]byte, error) {
3571 type NoMethod InappproductsUpdateRequest
3572 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3573 }
3574
3575
3576 type InstallmentPlan struct {
3577
3578
3579 InitialCommittedPaymentsCount int64 `json:"initialCommittedPaymentsCount,omitempty"`
3580
3581
3582
3583 PendingCancellation *PendingCancellation `json:"pendingCancellation,omitempty"`
3584
3585
3586 RemainingCommittedPaymentsCount int64 `json:"remainingCommittedPaymentsCount,omitempty"`
3587
3588
3589
3590 SubsequentCommittedPaymentsCount int64 `json:"subsequentCommittedPaymentsCount,omitempty"`
3591
3592
3593
3594
3595
3596 ForceSendFields []string `json:"-"`
3597
3598
3599
3600
3601 NullFields []string `json:"-"`
3602 }
3603
3604 func (s *InstallmentPlan) MarshalJSON() ([]byte, error) {
3605 type NoMethod InstallmentPlan
3606 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3607 }
3608
3609
3610
3611 type InstallmentsBasePlanType struct {
3612
3613
3614
3615
3616 AccountHoldDuration string `json:"accountHoldDuration,omitempty"`
3617
3618
3619 BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"`
3620
3621
3622 CommittedPaymentsCount int64 `json:"committedPaymentsCount,omitempty"`
3623
3624
3625
3626
3627 GracePeriodDuration string `json:"gracePeriodDuration,omitempty"`
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640 ProrationMode string `json:"prorationMode,omitempty"`
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650 RenewalType string `json:"renewalType,omitempty"`
3651
3652
3653
3654
3655
3656
3657
3658
3659 ResubscribeState string `json:"resubscribeState,omitempty"`
3660
3661
3662
3663
3664
3665 ForceSendFields []string `json:"-"`
3666
3667
3668
3669
3670 NullFields []string `json:"-"`
3671 }
3672
3673 func (s *InstallmentsBasePlanType) MarshalJSON() ([]byte, error) {
3674 type NoMethod InstallmentsBasePlanType
3675 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3676 }
3677
3678
3679
3680 type InternalAppSharingArtifact struct {
3681
3682
3683 CertificateFingerprint string `json:"certificateFingerprint,omitempty"`
3684
3685
3686
3687 DownloadUrl string `json:"downloadUrl,omitempty"`
3688
3689
3690 Sha256 string `json:"sha256,omitempty"`
3691
3692
3693 googleapi.ServerResponse `json:"-"`
3694
3695
3696
3697
3698
3699 ForceSendFields []string `json:"-"`
3700
3701
3702
3703
3704 NullFields []string `json:"-"`
3705 }
3706
3707 func (s *InternalAppSharingArtifact) MarshalJSON() ([]byte, error) {
3708 type NoMethod InternalAppSharingArtifact
3709 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3710 }
3711
3712
3713
3714 type IntroductoryPriceInfo struct {
3715
3716
3717
3718
3719
3720 IntroductoryPriceAmountMicros int64 `json:"introductoryPriceAmountMicros,omitempty,string"`
3721
3722
3723
3724 IntroductoryPriceCurrencyCode string `json:"introductoryPriceCurrencyCode,omitempty"`
3725
3726
3727 IntroductoryPriceCycles int64 `json:"introductoryPriceCycles,omitempty"`
3728
3729
3730
3731 IntroductoryPricePeriod string `json:"introductoryPricePeriod,omitempty"`
3732
3733
3734
3735
3736
3737 ForceSendFields []string `json:"-"`
3738
3739
3740
3741
3742 NullFields []string `json:"-"`
3743 }
3744
3745 func (s *IntroductoryPriceInfo) MarshalJSON() ([]byte, error) {
3746 type NoMethod IntroductoryPriceInfo
3747 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3748 }
3749
3750
3751 type LanguageTargeting struct {
3752
3753 Alternatives []string `json:"alternatives,omitempty"`
3754
3755 Value []string `json:"value,omitempty"`
3756
3757
3758
3759
3760
3761 ForceSendFields []string `json:"-"`
3762
3763
3764
3765
3766 NullFields []string `json:"-"`
3767 }
3768
3769 func (s *LanguageTargeting) MarshalJSON() ([]byte, error) {
3770 type NoMethod LanguageTargeting
3771 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3772 }
3773
3774
3775
3776 type ListAppRecoveriesResponse struct {
3777
3778
3779 RecoveryActions []*AppRecoveryAction `json:"recoveryActions,omitempty"`
3780
3781
3782 googleapi.ServerResponse `json:"-"`
3783
3784
3785
3786
3787
3788 ForceSendFields []string `json:"-"`
3789
3790
3791
3792
3793 NullFields []string `json:"-"`
3794 }
3795
3796 func (s *ListAppRecoveriesResponse) MarshalJSON() ([]byte, error) {
3797 type NoMethod ListAppRecoveriesResponse
3798 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3799 }
3800
3801
3802
3803 type ListDeviceTierConfigsResponse struct {
3804
3805 DeviceTierConfigs []*DeviceTierConfig `json:"deviceTierConfigs,omitempty"`
3806
3807
3808 NextPageToken string `json:"nextPageToken,omitempty"`
3809
3810
3811 googleapi.ServerResponse `json:"-"`
3812
3813
3814
3815
3816
3817 ForceSendFields []string `json:"-"`
3818
3819
3820
3821
3822 NullFields []string `json:"-"`
3823 }
3824
3825 func (s *ListDeviceTierConfigsResponse) MarshalJSON() ([]byte, error) {
3826 type NoMethod ListDeviceTierConfigsResponse
3827 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3828 }
3829
3830
3831 type ListSubscriptionOffersResponse struct {
3832
3833
3834 NextPageToken string `json:"nextPageToken,omitempty"`
3835
3836 SubscriptionOffers []*SubscriptionOffer `json:"subscriptionOffers,omitempty"`
3837
3838
3839 googleapi.ServerResponse `json:"-"`
3840
3841
3842
3843
3844
3845 ForceSendFields []string `json:"-"`
3846
3847
3848
3849
3850 NullFields []string `json:"-"`
3851 }
3852
3853 func (s *ListSubscriptionOffersResponse) MarshalJSON() ([]byte, error) {
3854 type NoMethod ListSubscriptionOffersResponse
3855 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3856 }
3857
3858
3859 type ListSubscriptionsResponse struct {
3860
3861
3862 NextPageToken string `json:"nextPageToken,omitempty"`
3863
3864 Subscriptions []*Subscription `json:"subscriptions,omitempty"`
3865
3866
3867 googleapi.ServerResponse `json:"-"`
3868
3869
3870
3871
3872
3873 ForceSendFields []string `json:"-"`
3874
3875
3876
3877
3878 NullFields []string `json:"-"`
3879 }
3880
3881 func (s *ListSubscriptionsResponse) MarshalJSON() ([]byte, error) {
3882 type NoMethod ListSubscriptionsResponse
3883 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3884 }
3885
3886
3887
3888 type ListUsersResponse struct {
3889
3890
3891
3892 NextPageToken string `json:"nextPageToken,omitempty"`
3893
3894 Users []*User `json:"users,omitempty"`
3895
3896
3897 googleapi.ServerResponse `json:"-"`
3898
3899
3900
3901
3902
3903 ForceSendFields []string `json:"-"`
3904
3905
3906
3907
3908 NullFields []string `json:"-"`
3909 }
3910
3911 func (s *ListUsersResponse) MarshalJSON() ([]byte, error) {
3912 type NoMethod ListUsersResponse
3913 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3914 }
3915
3916
3917 type Listing struct {
3918
3919 FullDescription string `json:"fullDescription,omitempty"`
3920
3921
3922 Language string `json:"language,omitempty"`
3923
3924 ShortDescription string `json:"shortDescription,omitempty"`
3925
3926 Title string `json:"title,omitempty"`
3927
3928 Video string `json:"video,omitempty"`
3929
3930
3931 googleapi.ServerResponse `json:"-"`
3932
3933
3934
3935
3936
3937 ForceSendFields []string `json:"-"`
3938
3939
3940
3941
3942 NullFields []string `json:"-"`
3943 }
3944
3945 func (s *Listing) MarshalJSON() ([]byte, error) {
3946 type NoMethod Listing
3947 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3948 }
3949
3950
3951 type ListingsListResponse struct {
3952
3953 Kind string `json:"kind,omitempty"`
3954
3955 Listings []*Listing `json:"listings,omitempty"`
3956
3957
3958 googleapi.ServerResponse `json:"-"`
3959
3960
3961
3962
3963
3964 ForceSendFields []string `json:"-"`
3965
3966
3967
3968
3969 NullFields []string `json:"-"`
3970 }
3971
3972 func (s *ListingsListResponse) MarshalJSON() ([]byte, error) {
3973 type NoMethod ListingsListResponse
3974 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
3975 }
3976
3977
3978 type LocalizedText struct {
3979
3980
3981 Language string `json:"language,omitempty"`
3982
3983 Text string `json:"text,omitempty"`
3984
3985
3986
3987
3988
3989 ForceSendFields []string `json:"-"`
3990
3991
3992
3993
3994 NullFields []string `json:"-"`
3995 }
3996
3997 func (s *LocalizedText) MarshalJSON() ([]byte, error) {
3998 type NoMethod LocalizedText
3999 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4000 }
4001
4002
4003
4004 type ManagedProductTaxAndComplianceSettings struct {
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016 EeaWithdrawalRightType string `json:"eeaWithdrawalRightType,omitempty"`
4017
4018
4019 IsTokenizedDigitalAsset bool `json:"isTokenizedDigitalAsset,omitempty"`
4020
4021
4022 TaxRateInfoByRegionCode map[string]RegionalTaxRateInfo `json:"taxRateInfoByRegionCode,omitempty"`
4023
4024
4025
4026
4027
4028 ForceSendFields []string `json:"-"`
4029
4030
4031
4032
4033 NullFields []string `json:"-"`
4034 }
4035
4036 func (s *ManagedProductTaxAndComplianceSettings) MarshalJSON() ([]byte, error) {
4037 type NoMethod ManagedProductTaxAndComplianceSettings
4038 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4039 }
4040
4041
4042 type MigrateBasePlanPricesRequest struct {
4043
4044
4045 BasePlanId string `json:"basePlanId,omitempty"`
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058 LatencyTolerance string `json:"latencyTolerance,omitempty"`
4059
4060
4061 PackageName string `json:"packageName,omitempty"`
4062
4063
4064 ProductId string `json:"productId,omitempty"`
4065
4066 RegionalPriceMigrations []*RegionalPriceMigrationConfig `json:"regionalPriceMigrations,omitempty"`
4067
4068
4069 RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"`
4070
4071
4072
4073
4074
4075 ForceSendFields []string `json:"-"`
4076
4077
4078
4079
4080 NullFields []string `json:"-"`
4081 }
4082
4083 func (s *MigrateBasePlanPricesRequest) MarshalJSON() ([]byte, error) {
4084 type NoMethod MigrateBasePlanPricesRequest
4085 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4086 }
4087
4088
4089 type MigrateBasePlanPricesResponse struct {
4090
4091 googleapi.ServerResponse `json:"-"`
4092 }
4093
4094
4095 type ModuleMetadata struct {
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107 DeliveryType string `json:"deliveryType,omitempty"`
4108
4109
4110 Dependencies []string `json:"dependencies,omitempty"`
4111
4112
4113
4114
4115
4116 ModuleType string `json:"moduleType,omitempty"`
4117
4118 Name string `json:"name,omitempty"`
4119
4120
4121 Targeting *ModuleTargeting `json:"targeting,omitempty"`
4122
4123
4124
4125
4126
4127 ForceSendFields []string `json:"-"`
4128
4129
4130
4131
4132 NullFields []string `json:"-"`
4133 }
4134
4135 func (s *ModuleMetadata) MarshalJSON() ([]byte, error) {
4136 type NoMethod ModuleMetadata
4137 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4138 }
4139
4140
4141 type ModuleTargeting struct {
4142
4143 DeviceFeatureTargeting []*DeviceFeatureTargeting `json:"deviceFeatureTargeting,omitempty"`
4144
4145 SdkVersionTargeting *SdkVersionTargeting `json:"sdkVersionTargeting,omitempty"`
4146
4147 UserCountriesTargeting *UserCountriesTargeting `json:"userCountriesTargeting,omitempty"`
4148
4149
4150
4151
4152
4153 ForceSendFields []string `json:"-"`
4154
4155
4156
4157
4158 NullFields []string `json:"-"`
4159 }
4160
4161 func (s *ModuleTargeting) MarshalJSON() ([]byte, error) {
4162 type NoMethod ModuleTargeting
4163 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4164 }
4165
4166
4167 type Money struct {
4168
4169 CurrencyCode string `json:"currencyCode,omitempty"`
4170
4171
4172
4173
4174
4175 Nanos int64 `json:"nanos,omitempty"`
4176
4177
4178 Units int64 `json:"units,omitempty,string"`
4179
4180
4181
4182
4183
4184 ForceSendFields []string `json:"-"`
4185
4186
4187
4188
4189 NullFields []string `json:"-"`
4190 }
4191
4192 func (s *Money) MarshalJSON() ([]byte, error) {
4193 type NoMethod Money
4194 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4195 }
4196
4197
4198 type MultiAbi struct {
4199
4200 Abi []*Abi `json:"abi,omitempty"`
4201
4202
4203
4204
4205
4206 ForceSendFields []string `json:"-"`
4207
4208
4209
4210
4211 NullFields []string `json:"-"`
4212 }
4213
4214 func (s *MultiAbi) MarshalJSON() ([]byte, error) {
4215 type NoMethod MultiAbi
4216 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4217 }
4218
4219
4220 type MultiAbiTargeting struct {
4221
4222
4223 Alternatives []*MultiAbi `json:"alternatives,omitempty"`
4224
4225 Value []*MultiAbi `json:"value,omitempty"`
4226
4227
4228
4229
4230
4231 ForceSendFields []string `json:"-"`
4232
4233
4234
4235
4236 NullFields []string `json:"-"`
4237 }
4238
4239 func (s *MultiAbiTargeting) MarshalJSON() ([]byte, error) {
4240 type NoMethod MultiAbiTargeting
4241 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4242 }
4243
4244
4245 type OfferDetails struct {
4246
4247 BasePlanId string `json:"basePlanId,omitempty"`
4248
4249 OfferId string `json:"offerId,omitempty"`
4250
4251
4252 OfferTags []string `json:"offerTags,omitempty"`
4253
4254
4255
4256
4257
4258 ForceSendFields []string `json:"-"`
4259
4260
4261
4262
4263 NullFields []string `json:"-"`
4264 }
4265
4266 func (s *OfferDetails) MarshalJSON() ([]byte, error) {
4267 type NoMethod OfferDetails
4268 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4269 }
4270
4271
4272
4273 type OfferTag struct {
4274
4275
4276
4277 Tag string `json:"tag,omitempty"`
4278
4279
4280
4281
4282
4283 ForceSendFields []string `json:"-"`
4284
4285
4286
4287
4288 NullFields []string `json:"-"`
4289 }
4290
4291 func (s *OfferTag) MarshalJSON() ([]byte, error) {
4292 type NoMethod OfferTag
4293 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4294 }
4295
4296
4297 type OneTimeExternalTransaction struct {
4298
4299
4300 ExternalTransactionToken string `json:"externalTransactionToken,omitempty"`
4301
4302
4303
4304
4305
4306 ForceSendFields []string `json:"-"`
4307
4308
4309
4310
4311 NullFields []string `json:"-"`
4312 }
4313
4314 func (s *OneTimeExternalTransaction) MarshalJSON() ([]byte, error) {
4315 type NoMethod OneTimeExternalTransaction
4316 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4317 }
4318
4319
4320
4321 type OtherRecurringProduct struct {
4322 }
4323
4324
4325
4326 type OtherRegionsBasePlanConfig struct {
4327
4328
4329 EurPrice *Money `json:"eurPrice,omitempty"`
4330
4331
4332
4333 NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"`
4334
4335
4336 UsdPrice *Money `json:"usdPrice,omitempty"`
4337
4338
4339
4340
4341
4342 ForceSendFields []string `json:"-"`
4343
4344
4345
4346
4347 NullFields []string `json:"-"`
4348 }
4349
4350 func (s *OtherRegionsBasePlanConfig) MarshalJSON() ([]byte, error) {
4351 type NoMethod OtherRegionsBasePlanConfig
4352 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4353 }
4354
4355
4356
4357 type OtherRegionsSubscriptionOfferConfig struct {
4358
4359
4360
4361 OtherRegionsNewSubscriberAvailability bool `json:"otherRegionsNewSubscriberAvailability,omitempty"`
4362
4363
4364
4365
4366
4367
4368 ForceSendFields []string `json:"-"`
4369
4370
4371
4372
4373
4374 NullFields []string `json:"-"`
4375 }
4376
4377 func (s *OtherRegionsSubscriptionOfferConfig) MarshalJSON() ([]byte, error) {
4378 type NoMethod OtherRegionsSubscriptionOfferConfig
4379 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4380 }
4381
4382
4383
4384 type OtherRegionsSubscriptionOfferPhaseConfig struct {
4385
4386
4387
4388
4389
4390
4391
4392 AbsoluteDiscounts *OtherRegionsSubscriptionOfferPhasePrices `json:"absoluteDiscounts,omitempty"`
4393
4394 Free *OtherRegionsSubscriptionOfferPhaseFreePriceOverride `json:"free,omitempty"`
4395
4396
4397
4398 OtherRegionsPrices *OtherRegionsSubscriptionOfferPhasePrices `json:"otherRegionsPrices,omitempty"`
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408 RelativeDiscount float64 `json:"relativeDiscount,omitempty"`
4409
4410
4411
4412
4413
4414 ForceSendFields []string `json:"-"`
4415
4416
4417
4418
4419 NullFields []string `json:"-"`
4420 }
4421
4422 func (s *OtherRegionsSubscriptionOfferPhaseConfig) MarshalJSON() ([]byte, error) {
4423 type NoMethod OtherRegionsSubscriptionOfferPhaseConfig
4424 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4425 }
4426
4427 func (s *OtherRegionsSubscriptionOfferPhaseConfig) UnmarshalJSON(data []byte) error {
4428 type NoMethod OtherRegionsSubscriptionOfferPhaseConfig
4429 var s1 struct {
4430 RelativeDiscount gensupport.JSONFloat64 `json:"relativeDiscount"`
4431 *NoMethod
4432 }
4433 s1.NoMethod = (*NoMethod)(s)
4434 if err := json.Unmarshal(data, &s1); err != nil {
4435 return err
4436 }
4437 s.RelativeDiscount = float64(s1.RelativeDiscount)
4438 return nil
4439 }
4440
4441
4442
4443
4444 type OtherRegionsSubscriptionOfferPhaseFreePriceOverride struct {
4445 }
4446
4447
4448
4449 type OtherRegionsSubscriptionOfferPhasePrices struct {
4450
4451
4452 EurPrice *Money `json:"eurPrice,omitempty"`
4453
4454
4455 UsdPrice *Money `json:"usdPrice,omitempty"`
4456
4457
4458
4459
4460
4461 ForceSendFields []string `json:"-"`
4462
4463
4464
4465
4466 NullFields []string `json:"-"`
4467 }
4468
4469 func (s *OtherRegionsSubscriptionOfferPhasePrices) MarshalJSON() ([]byte, error) {
4470 type NoMethod OtherRegionsSubscriptionOfferPhasePrices
4471 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4472 }
4473
4474
4475
4476
4477 type PageInfo struct {
4478
4479
4480 ResultPerPage int64 `json:"resultPerPage,omitempty"`
4481
4482 StartIndex int64 `json:"startIndex,omitempty"`
4483
4484
4485 TotalResults int64 `json:"totalResults,omitempty"`
4486
4487
4488
4489
4490
4491 ForceSendFields []string `json:"-"`
4492
4493
4494
4495
4496 NullFields []string `json:"-"`
4497 }
4498
4499 func (s *PageInfo) MarshalJSON() ([]byte, error) {
4500 type NoMethod PageInfo
4501 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4502 }
4503
4504
4505 type PartialRefund struct {
4506
4507
4508
4509 RefundId string `json:"refundId,omitempty"`
4510
4511
4512 RefundPreTaxAmount *Price `json:"refundPreTaxAmount,omitempty"`
4513
4514
4515
4516
4517
4518 ForceSendFields []string `json:"-"`
4519
4520
4521
4522
4523 NullFields []string `json:"-"`
4524 }
4525
4526 func (s *PartialRefund) MarshalJSON() ([]byte, error) {
4527 type NoMethod PartialRefund
4528 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4529 }
4530
4531
4532 type PausedStateContext struct {
4533
4534
4535 AutoResumeTime string `json:"autoResumeTime,omitempty"`
4536
4537
4538
4539
4540
4541 ForceSendFields []string `json:"-"`
4542
4543
4544
4545
4546 NullFields []string `json:"-"`
4547 }
4548
4549 func (s *PausedStateContext) MarshalJSON() ([]byte, error) {
4550 type NoMethod PausedStateContext
4551 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4552 }
4553
4554
4555
4556
4557 type PendingCancellation struct {
4558 }
4559
4560
4561
4562 type PrepaidBasePlanType struct {
4563
4564
4565 BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"`
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575 TimeExtension string `json:"timeExtension,omitempty"`
4576
4577
4578
4579
4580
4581 ForceSendFields []string `json:"-"`
4582
4583
4584
4585
4586 NullFields []string `json:"-"`
4587 }
4588
4589 func (s *PrepaidBasePlanType) MarshalJSON() ([]byte, error) {
4590 type NoMethod PrepaidBasePlanType
4591 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4592 }
4593
4594
4595 type PrepaidPlan struct {
4596
4597
4598
4599 AllowExtendAfterTime string `json:"allowExtendAfterTime,omitempty"`
4600
4601
4602
4603
4604
4605 ForceSendFields []string `json:"-"`
4606
4607
4608
4609
4610 NullFields []string `json:"-"`
4611 }
4612
4613 func (s *PrepaidPlan) MarshalJSON() ([]byte, error) {
4614 type NoMethod PrepaidPlan
4615 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4616 }
4617
4618
4619 type Price struct {
4620
4621
4622 Currency string `json:"currency,omitempty"`
4623
4624
4625 PriceMicros string `json:"priceMicros,omitempty"`
4626
4627
4628
4629
4630
4631 ForceSendFields []string `json:"-"`
4632
4633
4634
4635
4636 NullFields []string `json:"-"`
4637 }
4638
4639 func (s *Price) MarshalJSON() ([]byte, error) {
4640 type NoMethod Price
4641 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4642 }
4643
4644
4645
4646 type ProductPurchase struct {
4647
4648
4649 AcknowledgementState int64 `json:"acknowledgementState,omitempty"`
4650
4651
4652 ConsumptionState int64 `json:"consumptionState,omitempty"`
4653
4654
4655 DeveloperPayload string `json:"developerPayload,omitempty"`
4656
4657
4658 Kind string `json:"kind,omitempty"`
4659
4660
4661
4662
4663
4664 ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"`
4665
4666
4667
4668
4669
4670 ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"`
4671
4672 OrderId string `json:"orderId,omitempty"`
4673
4674 ProductId string `json:"productId,omitempty"`
4675
4676
4677 PurchaseState int64 `json:"purchaseState,omitempty"`
4678
4679
4680 PurchaseTimeMillis int64 `json:"purchaseTimeMillis,omitempty,string"`
4681
4682
4683 PurchaseToken string `json:"purchaseToken,omitempty"`
4684
4685
4686
4687
4688
4689 PurchaseType *int64 `json:"purchaseType,omitempty"`
4690
4691
4692 Quantity int64 `json:"quantity,omitempty"`
4693
4694
4695
4696 RefundableQuantity int64 `json:"refundableQuantity,omitempty"`
4697
4698
4699 RegionCode string `json:"regionCode,omitempty"`
4700
4701
4702 googleapi.ServerResponse `json:"-"`
4703
4704
4705
4706
4707
4708 ForceSendFields []string `json:"-"`
4709
4710
4711
4712
4713 NullFields []string `json:"-"`
4714 }
4715
4716 func (s *ProductPurchase) MarshalJSON() ([]byte, error) {
4717 type NoMethod ProductPurchase
4718 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4719 }
4720
4721
4722
4723 type ProductPurchasesAcknowledgeRequest struct {
4724
4725 DeveloperPayload string `json:"developerPayload,omitempty"`
4726
4727
4728
4729
4730
4731 ForceSendFields []string `json:"-"`
4732
4733
4734
4735
4736 NullFields []string `json:"-"`
4737 }
4738
4739 func (s *ProductPurchasesAcknowledgeRequest) MarshalJSON() ([]byte, error) {
4740 type NoMethod ProductPurchasesAcknowledgeRequest
4741 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4742 }
4743
4744
4745
4746
4747 type RecurringExternalTransaction struct {
4748
4749 ExternalSubscription *ExternalSubscription `json:"externalSubscription,omitempty"`
4750
4751
4752
4753 ExternalTransactionToken string `json:"externalTransactionToken,omitempty"`
4754
4755
4756
4757
4758 InitialExternalTransactionId string `json:"initialExternalTransactionId,omitempty"`
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770 MigratedTransactionProgram string `json:"migratedTransactionProgram,omitempty"`
4771
4772
4773 OtherRecurringProduct *OtherRecurringProduct `json:"otherRecurringProduct,omitempty"`
4774
4775
4776
4777
4778
4779 ForceSendFields []string `json:"-"`
4780
4781
4782
4783
4784 NullFields []string `json:"-"`
4785 }
4786
4787 func (s *RecurringExternalTransaction) MarshalJSON() ([]byte, error) {
4788 type NoMethod RecurringExternalTransaction
4789 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4790 }
4791
4792
4793
4794 type RefundExternalTransactionRequest struct {
4795
4796 FullRefund *FullRefund `json:"fullRefund,omitempty"`
4797
4798 PartialRefund *PartialRefund `json:"partialRefund,omitempty"`
4799
4800 RefundTime string `json:"refundTime,omitempty"`
4801
4802
4803
4804
4805
4806 ForceSendFields []string `json:"-"`
4807
4808
4809
4810
4811 NullFields []string `json:"-"`
4812 }
4813
4814 func (s *RefundExternalTransactionRequest) MarshalJSON() ([]byte, error) {
4815 type NoMethod RefundExternalTransactionRequest
4816 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4817 }
4818
4819
4820 type RegionalBasePlanConfig struct {
4821
4822
4823
4824
4825 NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"`
4826
4827
4828
4829 Price *Money `json:"price,omitempty"`
4830
4831
4832 RegionCode string `json:"regionCode,omitempty"`
4833
4834
4835
4836
4837
4838 ForceSendFields []string `json:"-"`
4839
4840
4841
4842
4843 NullFields []string `json:"-"`
4844 }
4845
4846 func (s *RegionalBasePlanConfig) MarshalJSON() ([]byte, error) {
4847 type NoMethod RegionalBasePlanConfig
4848 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4849 }
4850
4851
4852 type RegionalPriceMigrationConfig struct {
4853
4854
4855
4856
4857
4858
4859
4860 OldestAllowedPriceVersionTime string `json:"oldestAllowedPriceVersionTime,omitempty"`
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872 PriceIncreaseType string `json:"priceIncreaseType,omitempty"`
4873
4874
4875 RegionCode string `json:"regionCode,omitempty"`
4876
4877
4878
4879
4880
4881 ForceSendFields []string `json:"-"`
4882
4883
4884
4885
4886 NullFields []string `json:"-"`
4887 }
4888
4889 func (s *RegionalPriceMigrationConfig) MarshalJSON() ([]byte, error) {
4890 type NoMethod RegionalPriceMigrationConfig
4891 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4892 }
4893
4894
4895
4896 type RegionalSubscriptionOfferConfig struct {
4897
4898
4899
4900
4901 NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"`
4902
4903
4904 RegionCode string `json:"regionCode,omitempty"`
4905
4906
4907
4908
4909
4910 ForceSendFields []string `json:"-"`
4911
4912
4913
4914
4915 NullFields []string `json:"-"`
4916 }
4917
4918 func (s *RegionalSubscriptionOfferConfig) MarshalJSON() ([]byte, error) {
4919 type NoMethod RegionalSubscriptionOfferConfig
4920 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4921 }
4922
4923
4924
4925 type RegionalSubscriptionOfferPhaseConfig struct {
4926
4927
4928
4929
4930
4931
4932 AbsoluteDiscount *Money `json:"absoluteDiscount,omitempty"`
4933
4934 Free *RegionalSubscriptionOfferPhaseFreePriceOverride `json:"free,omitempty"`
4935
4936
4937 Price *Money `json:"price,omitempty"`
4938
4939 RegionCode string `json:"regionCode,omitempty"`
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949 RelativeDiscount float64 `json:"relativeDiscount,omitempty"`
4950
4951
4952
4953
4954
4955 ForceSendFields []string `json:"-"`
4956
4957
4958
4959
4960 NullFields []string `json:"-"`
4961 }
4962
4963 func (s *RegionalSubscriptionOfferPhaseConfig) MarshalJSON() ([]byte, error) {
4964 type NoMethod RegionalSubscriptionOfferPhaseConfig
4965 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
4966 }
4967
4968 func (s *RegionalSubscriptionOfferPhaseConfig) UnmarshalJSON(data []byte) error {
4969 type NoMethod RegionalSubscriptionOfferPhaseConfig
4970 var s1 struct {
4971 RelativeDiscount gensupport.JSONFloat64 `json:"relativeDiscount"`
4972 *NoMethod
4973 }
4974 s1.NoMethod = (*NoMethod)(s)
4975 if err := json.Unmarshal(data, &s1); err != nil {
4976 return err
4977 }
4978 s.RelativeDiscount = float64(s1.RelativeDiscount)
4979 return nil
4980 }
4981
4982
4983
4984 type RegionalSubscriptionOfferPhaseFreePriceOverride struct {
4985 }
4986
4987
4988
4989 type RegionalTaxRateInfo struct {
4990
4991
4992
4993 EligibleForStreamingServiceTaxRate bool `json:"eligibleForStreamingServiceTaxRate,omitempty"`
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014 StreamingTaxType string `json:"streamingTaxType,omitempty"`
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027 TaxTier string `json:"taxTier,omitempty"`
5028
5029
5030
5031
5032
5033
5034 ForceSendFields []string `json:"-"`
5035
5036
5037
5038
5039
5040 NullFields []string `json:"-"`
5041 }
5042
5043 func (s *RegionalTaxRateInfo) MarshalJSON() ([]byte, error) {
5044 type NoMethod RegionalTaxRateInfo
5045 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5046 }
5047
5048
5049 type Regions struct {
5050
5051
5052
5053
5054 RegionCode []string `json:"regionCode,omitempty"`
5055
5056
5057
5058
5059
5060 ForceSendFields []string `json:"-"`
5061
5062
5063
5064
5065 NullFields []string `json:"-"`
5066 }
5067
5068 func (s *Regions) MarshalJSON() ([]byte, error) {
5069 type NoMethod Regions
5070 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5071 }
5072
5073
5074
5075 type RegionsVersion struct {
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085 Version string `json:"version,omitempty"`
5086
5087
5088
5089
5090
5091 ForceSendFields []string `json:"-"`
5092
5093
5094
5095
5096 NullFields []string `json:"-"`
5097 }
5098
5099 func (s *RegionsVersion) MarshalJSON() ([]byte, error) {
5100 type NoMethod RegionsVersion
5101 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5102 }
5103
5104
5105
5106 type RemoteInAppUpdate struct {
5107
5108
5109 IsRemoteInAppUpdateRequested bool `json:"isRemoteInAppUpdateRequested,omitempty"`
5110
5111
5112
5113
5114
5115 ForceSendFields []string `json:"-"`
5116
5117
5118
5119
5120 NullFields []string `json:"-"`
5121 }
5122
5123 func (s *RemoteInAppUpdate) MarshalJSON() ([]byte, error) {
5124 type NoMethod RemoteInAppUpdate
5125 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5126 }
5127
5128
5129
5130 type RemoteInAppUpdateData struct {
5131
5132
5133 RemoteAppUpdateDataPerBundle []*RemoteInAppUpdateDataPerBundle `json:"remoteAppUpdateDataPerBundle,omitempty"`
5134
5135
5136
5137
5138
5139 ForceSendFields []string `json:"-"`
5140
5141
5142
5143
5144 NullFields []string `json:"-"`
5145 }
5146
5147 func (s *RemoteInAppUpdateData) MarshalJSON() ([]byte, error) {
5148 type NoMethod RemoteInAppUpdateData
5149 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5150 }
5151
5152
5153
5154 type RemoteInAppUpdateDataPerBundle struct {
5155
5156 RecoveredDeviceCount int64 `json:"recoveredDeviceCount,omitempty,string"`
5157
5158
5159 TotalDeviceCount int64 `json:"totalDeviceCount,omitempty,string"`
5160
5161 VersionCode int64 `json:"versionCode,omitempty,string"`
5162
5163
5164
5165
5166
5167 ForceSendFields []string `json:"-"`
5168
5169
5170
5171
5172 NullFields []string `json:"-"`
5173 }
5174
5175 func (s *RemoteInAppUpdateDataPerBundle) MarshalJSON() ([]byte, error) {
5176 type NoMethod RemoteInAppUpdateDataPerBundle
5177 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5178 }
5179
5180
5181
5182 type ReplacementCancellation struct {
5183 }
5184
5185
5186
5187
5188 type RestrictedPaymentCountries struct {
5189
5190
5191 RegionCodes []string `json:"regionCodes,omitempty"`
5192
5193
5194
5195
5196
5197 ForceSendFields []string `json:"-"`
5198
5199
5200
5201
5202 NullFields []string `json:"-"`
5203 }
5204
5205 func (s *RestrictedPaymentCountries) MarshalJSON() ([]byte, error) {
5206 type NoMethod RestrictedPaymentCountries
5207 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5208 }
5209
5210
5211 type Review struct {
5212
5213 AuthorName string `json:"authorName,omitempty"`
5214
5215 Comments []*Comment `json:"comments,omitempty"`
5216
5217 ReviewId string `json:"reviewId,omitempty"`
5218
5219
5220 googleapi.ServerResponse `json:"-"`
5221
5222
5223
5224
5225
5226 ForceSendFields []string `json:"-"`
5227
5228
5229
5230
5231 NullFields []string `json:"-"`
5232 }
5233
5234 func (s *Review) MarshalJSON() ([]byte, error) {
5235 type NoMethod Review
5236 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5237 }
5238
5239
5240 type ReviewReplyResult struct {
5241
5242 LastEdited *Timestamp `json:"lastEdited,omitempty"`
5243
5244 ReplyText string `json:"replyText,omitempty"`
5245
5246
5247
5248
5249
5250 ForceSendFields []string `json:"-"`
5251
5252
5253
5254
5255 NullFields []string `json:"-"`
5256 }
5257
5258 func (s *ReviewReplyResult) MarshalJSON() ([]byte, error) {
5259 type NoMethod ReviewReplyResult
5260 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5261 }
5262
5263
5264 type ReviewsListResponse struct {
5265
5266 PageInfo *PageInfo `json:"pageInfo,omitempty"`
5267
5268 Reviews []*Review `json:"reviews,omitempty"`
5269
5270
5271 TokenPagination *TokenPagination `json:"tokenPagination,omitempty"`
5272
5273
5274 googleapi.ServerResponse `json:"-"`
5275
5276
5277
5278
5279
5280 ForceSendFields []string `json:"-"`
5281
5282
5283
5284
5285 NullFields []string `json:"-"`
5286 }
5287
5288 func (s *ReviewsListResponse) MarshalJSON() ([]byte, error) {
5289 type NoMethod ReviewsListResponse
5290 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5291 }
5292
5293
5294 type ReviewsReplyRequest struct {
5295
5296
5297 ReplyText string `json:"replyText,omitempty"`
5298
5299
5300
5301
5302
5303 ForceSendFields []string `json:"-"`
5304
5305
5306
5307
5308 NullFields []string `json:"-"`
5309 }
5310
5311 func (s *ReviewsReplyRequest) MarshalJSON() ([]byte, error) {
5312 type NoMethod ReviewsReplyRequest
5313 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5314 }
5315
5316
5317 type ReviewsReplyResponse struct {
5318
5319 Result *ReviewReplyResult `json:"result,omitempty"`
5320
5321
5322 googleapi.ServerResponse `json:"-"`
5323
5324
5325
5326
5327
5328 ForceSendFields []string `json:"-"`
5329
5330
5331
5332
5333 NullFields []string `json:"-"`
5334 }
5335
5336 func (s *ReviewsReplyResponse) MarshalJSON() ([]byte, error) {
5337 type NoMethod ReviewsReplyResponse
5338 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5339 }
5340
5341
5342
5343 type RevocationContext struct {
5344
5345
5346
5347 ProratedRefund *RevocationContextProratedRefund `json:"proratedRefund,omitempty"`
5348
5349
5350
5351
5352
5353 ForceSendFields []string `json:"-"`
5354
5355
5356
5357
5358 NullFields []string `json:"-"`
5359 }
5360
5361 func (s *RevocationContext) MarshalJSON() ([]byte, error) {
5362 type NoMethod RevocationContext
5363 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5364 }
5365
5366
5367
5368 type RevocationContextProratedRefund struct {
5369 }
5370
5371
5372
5373 type RevokeSubscriptionPurchaseRequest struct {
5374
5375
5376 RevocationContext *RevocationContext `json:"revocationContext,omitempty"`
5377
5378
5379
5380
5381
5382 ForceSendFields []string `json:"-"`
5383
5384
5385
5386
5387 NullFields []string `json:"-"`
5388 }
5389
5390 func (s *RevokeSubscriptionPurchaseRequest) MarshalJSON() ([]byte, error) {
5391 type NoMethod RevokeSubscriptionPurchaseRequest
5392 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5393 }
5394
5395
5396
5397 type RevokeSubscriptionPurchaseResponse struct {
5398
5399 googleapi.ServerResponse `json:"-"`
5400 }
5401
5402
5403 type SafetyLabelsUpdateRequest struct {
5404
5405
5406
5407
5408
5409 SafetyLabels string `json:"safetyLabels,omitempty"`
5410
5411
5412
5413
5414
5415 ForceSendFields []string `json:"-"`
5416
5417
5418
5419
5420 NullFields []string `json:"-"`
5421 }
5422
5423 func (s *SafetyLabelsUpdateRequest) MarshalJSON() ([]byte, error) {
5424 type NoMethod SafetyLabelsUpdateRequest
5425 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5426 }
5427
5428
5429 type SafetyLabelsUpdateResponse struct {
5430
5431 googleapi.ServerResponse `json:"-"`
5432 }
5433
5434
5435 type ScreenDensity struct {
5436
5437
5438
5439
5440
5441
5442
5443
5444
5445
5446
5447
5448 DensityAlias string `json:"densityAlias,omitempty"`
5449
5450 DensityDpi int64 `json:"densityDpi,omitempty"`
5451
5452
5453
5454
5455
5456 ForceSendFields []string `json:"-"`
5457
5458
5459
5460
5461 NullFields []string `json:"-"`
5462 }
5463
5464 func (s *ScreenDensity) MarshalJSON() ([]byte, error) {
5465 type NoMethod ScreenDensity
5466 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5467 }
5468
5469
5470 type ScreenDensityTargeting struct {
5471
5472
5473 Alternatives []*ScreenDensity `json:"alternatives,omitempty"`
5474
5475 Value []*ScreenDensity `json:"value,omitempty"`
5476
5477
5478
5479
5480
5481 ForceSendFields []string `json:"-"`
5482
5483
5484
5485
5486 NullFields []string `json:"-"`
5487 }
5488
5489 func (s *ScreenDensityTargeting) MarshalJSON() ([]byte, error) {
5490 type NoMethod ScreenDensityTargeting
5491 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5492 }
5493
5494
5495 type SdkVersion struct {
5496
5497 Min int64 `json:"min,omitempty"`
5498
5499
5500
5501
5502
5503 ForceSendFields []string `json:"-"`
5504
5505
5506
5507
5508 NullFields []string `json:"-"`
5509 }
5510
5511 func (s *SdkVersion) MarshalJSON() ([]byte, error) {
5512 type NoMethod SdkVersion
5513 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5514 }
5515
5516
5517 type SdkVersionTargeting struct {
5518
5519
5520 Alternatives []*SdkVersion `json:"alternatives,omitempty"`
5521
5522 Value []*SdkVersion `json:"value,omitempty"`
5523
5524
5525
5526
5527
5528 ForceSendFields []string `json:"-"`
5529
5530
5531
5532
5533 NullFields []string `json:"-"`
5534 }
5535
5536 func (s *SdkVersionTargeting) MarshalJSON() ([]byte, error) {
5537 type NoMethod SdkVersionTargeting
5538 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5539 }
5540
5541
5542 type SplitApkMetadata struct {
5543
5544 IsMasterSplit bool `json:"isMasterSplit,omitempty"`
5545
5546 SplitId string `json:"splitId,omitempty"`
5547
5548
5549
5550
5551
5552 ForceSendFields []string `json:"-"`
5553
5554
5555
5556
5557 NullFields []string `json:"-"`
5558 }
5559
5560 func (s *SplitApkMetadata) MarshalJSON() ([]byte, error) {
5561 type NoMethod SplitApkMetadata
5562 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5563 }
5564
5565
5566
5567
5568 type SplitApkVariant struct {
5569
5570 ApkSet []*ApkSet `json:"apkSet,omitempty"`
5571
5572 Targeting *VariantTargeting `json:"targeting,omitempty"`
5573
5574
5575
5576
5577 VariantNumber int64 `json:"variantNumber,omitempty"`
5578
5579
5580
5581
5582
5583 ForceSendFields []string `json:"-"`
5584
5585
5586
5587
5588 NullFields []string `json:"-"`
5589 }
5590
5591 func (s *SplitApkVariant) MarshalJSON() ([]byte, error) {
5592 type NoMethod SplitApkVariant
5593 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5594 }
5595
5596
5597 type StandaloneApkMetadata struct {
5598
5599 FusedModuleName []string `json:"fusedModuleName,omitempty"`
5600
5601
5602
5603
5604
5605 ForceSendFields []string `json:"-"`
5606
5607
5608
5609
5610 NullFields []string `json:"-"`
5611 }
5612
5613 func (s *StandaloneApkMetadata) MarshalJSON() ([]byte, error) {
5614 type NoMethod StandaloneApkMetadata
5615 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5616 }
5617
5618
5619
5620 type SubscribeWithGoogleInfo struct {
5621
5622
5623 EmailAddress string `json:"emailAddress,omitempty"`
5624
5625 FamilyName string `json:"familyName,omitempty"`
5626
5627 GivenName string `json:"givenName,omitempty"`
5628
5629
5630 ProfileId string `json:"profileId,omitempty"`
5631
5632
5633 ProfileName string `json:"profileName,omitempty"`
5634
5635
5636
5637
5638
5639 ForceSendFields []string `json:"-"`
5640
5641
5642
5643
5644 NullFields []string `json:"-"`
5645 }
5646
5647 func (s *SubscribeWithGoogleInfo) MarshalJSON() ([]byte, error) {
5648 type NoMethod SubscribeWithGoogleInfo
5649 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5650 }
5651
5652
5653 type Subscription struct {
5654
5655 Archived bool `json:"archived,omitempty"`
5656
5657
5658 BasePlans []*BasePlan `json:"basePlans,omitempty"`
5659
5660
5661 Listings []*SubscriptionListing `json:"listings,omitempty"`
5662
5663 PackageName string `json:"packageName,omitempty"`
5664
5665
5666
5667
5668 ProductId string `json:"productId,omitempty"`
5669
5670
5671
5672 RestrictedPaymentCountries *RestrictedPaymentCountries `json:"restrictedPaymentCountries,omitempty"`
5673
5674 TaxAndComplianceSettings *SubscriptionTaxAndComplianceSettings `json:"taxAndComplianceSettings,omitempty"`
5675
5676
5677 googleapi.ServerResponse `json:"-"`
5678
5679
5680
5681
5682
5683 ForceSendFields []string `json:"-"`
5684
5685
5686
5687
5688 NullFields []string `json:"-"`
5689 }
5690
5691 func (s *Subscription) MarshalJSON() ([]byte, error) {
5692 type NoMethod Subscription
5693 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5694 }
5695
5696
5697
5698 type SubscriptionCancelSurveyResult struct {
5699
5700
5701
5702 CancelSurveyReason int64 `json:"cancelSurveyReason,omitempty"`
5703
5704
5705 UserInputCancelReason string `json:"userInputCancelReason,omitempty"`
5706
5707
5708
5709
5710
5711 ForceSendFields []string `json:"-"`
5712
5713
5714
5715
5716 NullFields []string `json:"-"`
5717 }
5718
5719 func (s *SubscriptionCancelSurveyResult) MarshalJSON() ([]byte, error) {
5720 type NoMethod SubscriptionCancelSurveyResult
5721 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5722 }
5723
5724
5725
5726 type SubscriptionDeferralInfo struct {
5727
5728
5729
5730 DesiredExpiryTimeMillis int64 `json:"desiredExpiryTimeMillis,omitempty,string"`
5731
5732
5733
5734 ExpectedExpiryTimeMillis int64 `json:"expectedExpiryTimeMillis,omitempty,string"`
5735
5736
5737
5738
5739
5740 ForceSendFields []string `json:"-"`
5741
5742
5743
5744
5745 NullFields []string `json:"-"`
5746 }
5747
5748 func (s *SubscriptionDeferralInfo) MarshalJSON() ([]byte, error) {
5749 type NoMethod SubscriptionDeferralInfo
5750 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5751 }
5752
5753
5754
5755 type SubscriptionItemPriceChangeDetails struct {
5756
5757
5758
5759
5760 ExpectedNewPriceChargeTime string `json:"expectedNewPriceChargeTime,omitempty"`
5761
5762 NewPrice *Money `json:"newPrice,omitempty"`
5763
5764
5765
5766
5767
5768
5769
5770
5771
5772
5773
5774 PriceChangeMode string `json:"priceChangeMode,omitempty"`
5775
5776
5777
5778
5779
5780
5781
5782
5783
5784 PriceChangeState string `json:"priceChangeState,omitempty"`
5785
5786
5787
5788
5789
5790 ForceSendFields []string `json:"-"`
5791
5792
5793
5794
5795 NullFields []string `json:"-"`
5796 }
5797
5798 func (s *SubscriptionItemPriceChangeDetails) MarshalJSON() ([]byte, error) {
5799 type NoMethod SubscriptionItemPriceChangeDetails
5800 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5801 }
5802
5803
5804 type SubscriptionListing struct {
5805
5806
5807
5808 Benefits []string `json:"benefits,omitempty"`
5809
5810
5811 Description string `json:"description,omitempty"`
5812
5813
5814 LanguageCode string `json:"languageCode,omitempty"`
5815
5816
5817 Title string `json:"title,omitempty"`
5818
5819
5820
5821
5822
5823 ForceSendFields []string `json:"-"`
5824
5825
5826
5827
5828 NullFields []string `json:"-"`
5829 }
5830
5831 func (s *SubscriptionListing) MarshalJSON() ([]byte, error) {
5832 type NoMethod SubscriptionListing
5833 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5834 }
5835
5836
5837 type SubscriptionOffer struct {
5838
5839
5840 BasePlanId string `json:"basePlanId,omitempty"`
5841
5842
5843 OfferId string `json:"offerId,omitempty"`
5844
5845
5846 OfferTags []*OfferTag `json:"offerTags,omitempty"`
5847
5848
5849 OtherRegionsConfig *OtherRegionsSubscriptionOfferConfig `json:"otherRegionsConfig,omitempty"`
5850
5851
5852 PackageName string `json:"packageName,omitempty"`
5853
5854
5855
5856
5857 Phases []*SubscriptionOfferPhase `json:"phases,omitempty"`
5858
5859
5860 ProductId string `json:"productId,omitempty"`
5861
5862
5863 RegionalConfigs []*RegionalSubscriptionOfferConfig `json:"regionalConfigs,omitempty"`
5864
5865
5866
5867
5868
5869
5870
5871
5872
5873
5874
5875
5876 State string `json:"state,omitempty"`
5877
5878
5879
5880
5881 Targeting *SubscriptionOfferTargeting `json:"targeting,omitempty"`
5882
5883
5884 googleapi.ServerResponse `json:"-"`
5885
5886
5887
5888
5889
5890 ForceSendFields []string `json:"-"`
5891
5892
5893
5894
5895 NullFields []string `json:"-"`
5896 }
5897
5898 func (s *SubscriptionOffer) MarshalJSON() ([]byte, error) {
5899 type NoMethod SubscriptionOffer
5900 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5901 }
5902
5903
5904 type SubscriptionOfferPhase struct {
5905
5906
5907 Duration string `json:"duration,omitempty"`
5908
5909
5910 OtherRegionsConfig *OtherRegionsSubscriptionOfferPhaseConfig `json:"otherRegionsConfig,omitempty"`
5911
5912
5913
5914 RecurrenceCount int64 `json:"recurrenceCount,omitempty"`
5915
5916
5917
5918 RegionalConfigs []*RegionalSubscriptionOfferPhaseConfig `json:"regionalConfigs,omitempty"`
5919
5920
5921
5922
5923
5924 ForceSendFields []string `json:"-"`
5925
5926
5927
5928
5929 NullFields []string `json:"-"`
5930 }
5931
5932 func (s *SubscriptionOfferPhase) MarshalJSON() ([]byte, error) {
5933 type NoMethod SubscriptionOfferPhase
5934 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5935 }
5936
5937
5938
5939 type SubscriptionOfferTargeting struct {
5940
5941 AcquisitionRule *AcquisitionTargetingRule `json:"acquisitionRule,omitempty"`
5942
5943 UpgradeRule *UpgradeTargetingRule `json:"upgradeRule,omitempty"`
5944
5945
5946
5947
5948
5949 ForceSendFields []string `json:"-"`
5950
5951
5952
5953
5954 NullFields []string `json:"-"`
5955 }
5956
5957 func (s *SubscriptionOfferTargeting) MarshalJSON() ([]byte, error) {
5958 type NoMethod SubscriptionOfferTargeting
5959 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5960 }
5961
5962
5963
5964
5965
5966 type SubscriptionPriceChange struct {
5967
5968
5969 NewPrice *Price `json:"newPrice,omitempty"`
5970
5971
5972
5973
5974
5975
5976
5977 State int64 `json:"state,omitempty"`
5978
5979
5980
5981
5982
5983 ForceSendFields []string `json:"-"`
5984
5985
5986
5987
5988 NullFields []string `json:"-"`
5989 }
5990
5991 func (s *SubscriptionPriceChange) MarshalJSON() ([]byte, error) {
5992 type NoMethod SubscriptionPriceChange
5993 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
5994 }
5995
5996
5997
5998 type SubscriptionPurchase struct {
5999
6000
6001 AcknowledgementState int64 `json:"acknowledgementState,omitempty"`
6002
6003
6004 AutoRenewing bool `json:"autoRenewing,omitempty"`
6005
6006
6007
6008 AutoResumeTimeMillis int64 `json:"autoResumeTimeMillis,omitempty,string"`
6009
6010
6011
6012
6013
6014 CancelReason int64 `json:"cancelReason,omitempty"`
6015
6016
6017 CancelSurveyResult *SubscriptionCancelSurveyResult `json:"cancelSurveyResult,omitempty"`
6018
6019
6020 CountryCode string `json:"countryCode,omitempty"`
6021
6022
6023 DeveloperPayload string `json:"developerPayload,omitempty"`
6024
6025
6026 EmailAddress string `json:"emailAddress,omitempty"`
6027
6028
6029 ExpiryTimeMillis int64 `json:"expiryTimeMillis,omitempty,string"`
6030
6031
6032
6033 ExternalAccountId string `json:"externalAccountId,omitempty"`
6034
6035
6036 FamilyName string `json:"familyName,omitempty"`
6037
6038
6039 GivenName string `json:"givenName,omitempty"`
6040
6041
6042
6043
6044 IntroductoryPriceInfo *IntroductoryPriceInfo `json:"introductoryPriceInfo,omitempty"`
6045
6046
6047 Kind string `json:"kind,omitempty"`
6048
6049
6050
6051
6052
6053
6054
6055
6056
6057
6058 LinkedPurchaseToken string `json:"linkedPurchaseToken,omitempty"`
6059
6060
6061
6062
6063
6064
6065 ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"`
6066
6067
6068
6069
6070
6071 ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"`
6072
6073
6074
6075
6076 OrderId string `json:"orderId,omitempty"`
6077
6078
6079
6080 PaymentState *int64 `json:"paymentState,omitempty"`
6081
6082
6083
6084
6085
6086 PriceAmountMicros int64 `json:"priceAmountMicros,omitempty,string"`
6087
6088
6089
6090
6091 PriceChange *SubscriptionPriceChange `json:"priceChange,omitempty"`
6092
6093
6094
6095 PriceCurrencyCode string `json:"priceCurrencyCode,omitempty"`
6096
6097
6098 ProfileId string `json:"profileId,omitempty"`
6099
6100
6101 ProfileName string `json:"profileName,omitempty"`
6102
6103
6104
6105 PromotionCode string `json:"promotionCode,omitempty"`
6106
6107
6108
6109 PromotionType int64 `json:"promotionType,omitempty"`
6110
6111
6112
6113
6114 PurchaseType *int64 `json:"purchaseType,omitempty"`
6115
6116
6117 StartTimeMillis int64 `json:"startTimeMillis,omitempty,string"`
6118
6119
6120
6121 UserCancellationTimeMillis int64 `json:"userCancellationTimeMillis,omitempty,string"`
6122
6123
6124 googleapi.ServerResponse `json:"-"`
6125
6126
6127
6128
6129
6130 ForceSendFields []string `json:"-"`
6131
6132
6133
6134
6135 NullFields []string `json:"-"`
6136 }
6137
6138 func (s *SubscriptionPurchase) MarshalJSON() ([]byte, error) {
6139 type NoMethod SubscriptionPurchase
6140 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6141 }
6142
6143
6144 type SubscriptionPurchaseLineItem struct {
6145
6146 AutoRenewingPlan *AutoRenewingPlan `json:"autoRenewingPlan,omitempty"`
6147
6148 DeferredItemReplacement *DeferredItemReplacement `json:"deferredItemReplacement,omitempty"`
6149
6150
6151 ExpiryTime string `json:"expiryTime,omitempty"`
6152
6153 OfferDetails *OfferDetails `json:"offerDetails,omitempty"`
6154
6155 PrepaidPlan *PrepaidPlan `json:"prepaidPlan,omitempty"`
6156
6157 ProductId string `json:"productId,omitempty"`
6158
6159
6160
6161
6162
6163 ForceSendFields []string `json:"-"`
6164
6165
6166
6167
6168 NullFields []string `json:"-"`
6169 }
6170
6171 func (s *SubscriptionPurchaseLineItem) MarshalJSON() ([]byte, error) {
6172 type NoMethod SubscriptionPurchaseLineItem
6173 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6174 }
6175
6176
6177
6178 type SubscriptionPurchaseV2 struct {
6179
6180
6181
6182
6183
6184
6185
6186 AcknowledgementState string `json:"acknowledgementState,omitempty"`
6187
6188
6189
6190 CanceledStateContext *CanceledStateContext `json:"canceledStateContext,omitempty"`
6191
6192
6193 ExternalAccountIdentifiers *ExternalAccountIdentifiers `json:"externalAccountIdentifiers,omitempty"`
6194
6195
6196 Kind string `json:"kind,omitempty"`
6197
6198
6199
6200
6201
6202 LatestOrderId string `json:"latestOrderId,omitempty"`
6203
6204
6205
6206 LineItems []*SubscriptionPurchaseLineItem `json:"lineItems,omitempty"`
6207
6208
6209
6210
6211
6212 LinkedPurchaseToken string `json:"linkedPurchaseToken,omitempty"`
6213
6214
6215
6216 PausedStateContext *PausedStateContext `json:"pausedStateContext,omitempty"`
6217
6218
6219 RegionCode string `json:"regionCode,omitempty"`
6220
6221
6222 StartTime string `json:"startTime,omitempty"`
6223
6224
6225 SubscribeWithGoogleInfo *SubscribeWithGoogleInfo `json:"subscribeWithGoogleInfo,omitempty"`
6226
6227
6228
6229
6230
6231
6232
6233
6234
6235
6236
6237
6238
6239
6240
6241
6242
6243
6244
6245
6246
6247
6248
6249
6250 SubscriptionState string `json:"subscriptionState,omitempty"`
6251
6252 TestPurchase *TestPurchase `json:"testPurchase,omitempty"`
6253
6254
6255 googleapi.ServerResponse `json:"-"`
6256
6257
6258
6259
6260
6261 ForceSendFields []string `json:"-"`
6262
6263
6264
6265
6266 NullFields []string `json:"-"`
6267 }
6268
6269 func (s *SubscriptionPurchaseV2) MarshalJSON() ([]byte, error) {
6270 type NoMethod SubscriptionPurchaseV2
6271 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6272 }
6273
6274
6275
6276 type SubscriptionPurchasesAcknowledgeRequest struct {
6277
6278 DeveloperPayload string `json:"developerPayload,omitempty"`
6279
6280
6281
6282
6283
6284 ForceSendFields []string `json:"-"`
6285
6286
6287
6288
6289 NullFields []string `json:"-"`
6290 }
6291
6292 func (s *SubscriptionPurchasesAcknowledgeRequest) MarshalJSON() ([]byte, error) {
6293 type NoMethod SubscriptionPurchasesAcknowledgeRequest
6294 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6295 }
6296
6297
6298
6299 type SubscriptionPurchasesDeferRequest struct {
6300
6301
6302 DeferralInfo *SubscriptionDeferralInfo `json:"deferralInfo,omitempty"`
6303
6304
6305
6306
6307
6308 ForceSendFields []string `json:"-"`
6309
6310
6311
6312
6313 NullFields []string `json:"-"`
6314 }
6315
6316 func (s *SubscriptionPurchasesDeferRequest) MarshalJSON() ([]byte, error) {
6317 type NoMethod SubscriptionPurchasesDeferRequest
6318 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6319 }
6320
6321
6322
6323 type SubscriptionPurchasesDeferResponse struct {
6324
6325
6326 NewExpiryTimeMillis int64 `json:"newExpiryTimeMillis,omitempty,string"`
6327
6328
6329 googleapi.ServerResponse `json:"-"`
6330
6331
6332
6333
6334
6335 ForceSendFields []string `json:"-"`
6336
6337
6338
6339
6340 NullFields []string `json:"-"`
6341 }
6342
6343 func (s *SubscriptionPurchasesDeferResponse) MarshalJSON() ([]byte, error) {
6344 type NoMethod SubscriptionPurchasesDeferResponse
6345 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6346 }
6347
6348
6349
6350 type SubscriptionTaxAndComplianceSettings struct {
6351
6352
6353
6354
6355
6356
6357
6358
6359
6360
6361
6362 EeaWithdrawalRightType string `json:"eeaWithdrawalRightType,omitempty"`
6363
6364
6365 IsTokenizedDigitalAsset bool `json:"isTokenizedDigitalAsset,omitempty"`
6366
6367
6368 TaxRateInfoByRegionCode map[string]RegionalTaxRateInfo `json:"taxRateInfoByRegionCode,omitempty"`
6369
6370
6371
6372
6373
6374 ForceSendFields []string `json:"-"`
6375
6376
6377
6378
6379 NullFields []string `json:"-"`
6380 }
6381
6382 func (s *SubscriptionTaxAndComplianceSettings) MarshalJSON() ([]byte, error) {
6383 type NoMethod SubscriptionTaxAndComplianceSettings
6384 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6385 }
6386
6387
6388 type SystemApkOptions struct {
6389
6390 Rotated bool `json:"rotated,omitempty"`
6391
6392
6393 UncompressedDexFiles bool `json:"uncompressedDexFiles,omitempty"`
6394
6395
6396 UncompressedNativeLibraries bool `json:"uncompressedNativeLibraries,omitempty"`
6397
6398
6399
6400
6401
6402 ForceSendFields []string `json:"-"`
6403
6404
6405
6406
6407 NullFields []string `json:"-"`
6408 }
6409
6410 func (s *SystemApkOptions) MarshalJSON() ([]byte, error) {
6411 type NoMethod SystemApkOptions
6412 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6413 }
6414
6415
6416
6417 type SystemApksListResponse struct {
6418
6419 Variants []*Variant `json:"variants,omitempty"`
6420
6421
6422 googleapi.ServerResponse `json:"-"`
6423
6424
6425
6426
6427
6428 ForceSendFields []string `json:"-"`
6429
6430
6431
6432
6433 NullFields []string `json:"-"`
6434 }
6435
6436 func (s *SystemApksListResponse) MarshalJSON() ([]byte, error) {
6437 type NoMethod SystemApksListResponse
6438 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6439 }
6440
6441
6442 type SystemFeature struct {
6443
6444 Name string `json:"name,omitempty"`
6445
6446
6447
6448
6449
6450 ForceSendFields []string `json:"-"`
6451
6452
6453
6454
6455 NullFields []string `json:"-"`
6456 }
6457
6458 func (s *SystemFeature) MarshalJSON() ([]byte, error) {
6459 type NoMethod SystemFeature
6460 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6461 }
6462
6463
6464
6465 type SystemInitiatedCancellation struct {
6466 }
6467
6468
6469
6470 type Targeting struct {
6471
6472 AllUsers *AllUsers `json:"allUsers,omitempty"`
6473
6474 AndroidSdks *AndroidSdks `json:"androidSdks,omitempty"`
6475
6476 Regions *Regions `json:"regions,omitempty"`
6477
6478 VersionList *AppVersionList `json:"versionList,omitempty"`
6479
6480 VersionRange *AppVersionRange `json:"versionRange,omitempty"`
6481
6482
6483
6484
6485
6486 ForceSendFields []string `json:"-"`
6487
6488
6489
6490
6491 NullFields []string `json:"-"`
6492 }
6493
6494 func (s *Targeting) MarshalJSON() ([]byte, error) {
6495 type NoMethod Targeting
6496 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6497 }
6498
6499
6500 type TargetingInfo struct {
6501
6502 AssetSliceSet []*AssetSliceSet `json:"assetSliceSet,omitempty"`
6503
6504 PackageName string `json:"packageName,omitempty"`
6505
6506 Variant []*SplitApkVariant `json:"variant,omitempty"`
6507
6508
6509
6510
6511
6512 ForceSendFields []string `json:"-"`
6513
6514
6515
6516
6517 NullFields []string `json:"-"`
6518 }
6519
6520 func (s *TargetingInfo) MarshalJSON() ([]byte, error) {
6521 type NoMethod TargetingInfo
6522 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6523 }
6524
6525
6526
6527
6528 type TargetingRuleScope struct {
6529
6530
6531 AnySubscriptionInApp *TargetingRuleScopeAnySubscriptionInApp `json:"anySubscriptionInApp,omitempty"`
6532
6533
6534
6535 SpecificSubscriptionInApp string `json:"specificSubscriptionInApp,omitempty"`
6536
6537
6538 ThisSubscription *TargetingRuleScopeThisSubscription `json:"thisSubscription,omitempty"`
6539
6540
6541
6542
6543
6544 ForceSendFields []string `json:"-"`
6545
6546
6547
6548
6549 NullFields []string `json:"-"`
6550 }
6551
6552 func (s *TargetingRuleScope) MarshalJSON() ([]byte, error) {
6553 type NoMethod TargetingRuleScope
6554 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6555 }
6556
6557
6558
6559 type TargetingRuleScopeAnySubscriptionInApp struct {
6560 }
6561
6562
6563
6564 type TargetingRuleScopeThisSubscription struct {
6565 }
6566
6567
6568
6569 type TargetingUpdate struct {
6570
6571 AllUsers *AllUsers `json:"allUsers,omitempty"`
6572
6573
6574 AndroidSdks *AndroidSdks `json:"androidSdks,omitempty"`
6575
6576 Regions *Regions `json:"regions,omitempty"`
6577
6578
6579
6580
6581
6582 ForceSendFields []string `json:"-"`
6583
6584
6585
6586
6587 NullFields []string `json:"-"`
6588 }
6589
6590 func (s *TargetingUpdate) MarshalJSON() ([]byte, error) {
6591 type NoMethod TargetingUpdate
6592 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6593 }
6594
6595
6596 type TestPurchase struct {
6597 }
6598
6599
6600
6601
6602 type Testers struct {
6603
6604 GoogleGroups []string `json:"googleGroups,omitempty"`
6605
6606
6607 googleapi.ServerResponse `json:"-"`
6608
6609
6610
6611
6612
6613 ForceSendFields []string `json:"-"`
6614
6615
6616
6617
6618 NullFields []string `json:"-"`
6619 }
6620
6621 func (s *Testers) MarshalJSON() ([]byte, error) {
6622 type NoMethod Testers
6623 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6624 }
6625
6626
6627 type TextureCompressionFormat struct {
6628
6629
6630
6631
6632
6633
6634
6635
6636
6637
6638
6639
6640
6641
6642 Alias string `json:"alias,omitempty"`
6643
6644
6645
6646
6647
6648 ForceSendFields []string `json:"-"`
6649
6650
6651
6652
6653 NullFields []string `json:"-"`
6654 }
6655
6656 func (s *TextureCompressionFormat) MarshalJSON() ([]byte, error) {
6657 type NoMethod TextureCompressionFormat
6658 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6659 }
6660
6661
6662
6663 type TextureCompressionFormatTargeting struct {
6664
6665
6666 Alternatives []*TextureCompressionFormat `json:"alternatives,omitempty"`
6667
6668 Value []*TextureCompressionFormat `json:"value,omitempty"`
6669
6670
6671
6672
6673
6674 ForceSendFields []string `json:"-"`
6675
6676
6677
6678
6679 NullFields []string `json:"-"`
6680 }
6681
6682 func (s *TextureCompressionFormatTargeting) MarshalJSON() ([]byte, error) {
6683 type NoMethod TextureCompressionFormatTargeting
6684 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6685 }
6686
6687
6688
6689
6690
6691 type Timestamp struct {
6692
6693
6694 Nanos int64 `json:"nanos,omitempty"`
6695
6696 Seconds int64 `json:"seconds,omitempty,string"`
6697
6698
6699
6700
6701
6702 ForceSendFields []string `json:"-"`
6703
6704
6705
6706
6707 NullFields []string `json:"-"`
6708 }
6709
6710 func (s *Timestamp) MarshalJSON() ([]byte, error) {
6711 type NoMethod Timestamp
6712 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6713 }
6714
6715
6716
6717
6718
6719
6720
6721
6722
6723
6724 type TokenPagination struct {
6725
6726
6727 NextPageToken string `json:"nextPageToken,omitempty"`
6728 PreviousPageToken string `json:"previousPageToken,omitempty"`
6729
6730
6731
6732
6733
6734 ForceSendFields []string `json:"-"`
6735
6736
6737
6738
6739 NullFields []string `json:"-"`
6740 }
6741
6742 func (s *TokenPagination) MarshalJSON() ([]byte, error) {
6743 type NoMethod TokenPagination
6744 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6745 }
6746
6747
6748 type Track struct {
6749
6750
6751 Releases []*TrackRelease `json:"releases,omitempty"`
6752
6753
6754
6755
6756 Track string `json:"track,omitempty"`
6757
6758
6759 googleapi.ServerResponse `json:"-"`
6760
6761
6762
6763
6764
6765 ForceSendFields []string `json:"-"`
6766
6767
6768
6769
6770 NullFields []string `json:"-"`
6771 }
6772
6773 func (s *Track) MarshalJSON() ([]byte, error) {
6774 type NoMethod Track
6775 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6776 }
6777
6778
6779 type TrackConfig struct {
6780
6781
6782
6783
6784
6785
6786
6787
6788 FormFactor string `json:"formFactor,omitempty"`
6789
6790
6791
6792
6793
6794
6795 Track string `json:"track,omitempty"`
6796
6797
6798
6799
6800
6801
6802 Type string `json:"type,omitempty"`
6803
6804
6805
6806
6807
6808 ForceSendFields []string `json:"-"`
6809
6810
6811
6812
6813 NullFields []string `json:"-"`
6814 }
6815
6816 func (s *TrackConfig) MarshalJSON() ([]byte, error) {
6817 type NoMethod TrackConfig
6818 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6819 }
6820
6821
6822
6823 type TrackCountryAvailability struct {
6824
6825
6826
6827 Countries []*TrackTargetedCountry `json:"countries,omitempty"`
6828
6829
6830 RestOfWorld bool `json:"restOfWorld,omitempty"`
6831
6832
6833
6834
6835
6836
6837 SyncWithProduction bool `json:"syncWithProduction,omitempty"`
6838
6839
6840 googleapi.ServerResponse `json:"-"`
6841
6842
6843
6844
6845
6846 ForceSendFields []string `json:"-"`
6847
6848
6849
6850
6851 NullFields []string `json:"-"`
6852 }
6853
6854 func (s *TrackCountryAvailability) MarshalJSON() ([]byte, error) {
6855 type NoMethod TrackCountryAvailability
6856 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6857 }
6858
6859
6860 type TrackRelease struct {
6861
6862 CountryTargeting *CountryTargeting `json:"countryTargeting,omitempty"`
6863
6864
6865
6866
6867
6868 InAppUpdatePriority int64 `json:"inAppUpdatePriority,omitempty"`
6869
6870
6871
6872 Name string `json:"name,omitempty"`
6873
6874 ReleaseNotes []*LocalizedText `json:"releaseNotes,omitempty"`
6875
6876
6877
6878
6879
6880
6881
6882
6883
6884
6885
6886
6887 Status string `json:"status,omitempty"`
6888
6889
6890 UserFraction float64 `json:"userFraction,omitempty"`
6891
6892
6893 VersionCodes googleapi.Int64s `json:"versionCodes,omitempty"`
6894
6895
6896
6897
6898
6899 ForceSendFields []string `json:"-"`
6900
6901
6902
6903
6904 NullFields []string `json:"-"`
6905 }
6906
6907 func (s *TrackRelease) MarshalJSON() ([]byte, error) {
6908 type NoMethod TrackRelease
6909 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6910 }
6911
6912 func (s *TrackRelease) UnmarshalJSON(data []byte) error {
6913 type NoMethod TrackRelease
6914 var s1 struct {
6915 UserFraction gensupport.JSONFloat64 `json:"userFraction"`
6916 *NoMethod
6917 }
6918 s1.NoMethod = (*NoMethod)(s)
6919 if err := json.Unmarshal(data, &s1); err != nil {
6920 return err
6921 }
6922 s.UserFraction = float64(s1.UserFraction)
6923 return nil
6924 }
6925
6926
6927
6928 type TrackTargetedCountry struct {
6929
6930 CountryCode string `json:"countryCode,omitempty"`
6931
6932
6933
6934
6935
6936 ForceSendFields []string `json:"-"`
6937
6938
6939
6940
6941 NullFields []string `json:"-"`
6942 }
6943
6944 func (s *TrackTargetedCountry) MarshalJSON() ([]byte, error) {
6945 type NoMethod TrackTargetedCountry
6946 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6947 }
6948
6949
6950 type TracksListResponse struct {
6951
6952 Kind string `json:"kind,omitempty"`
6953
6954 Tracks []*Track `json:"tracks,omitempty"`
6955
6956
6957 googleapi.ServerResponse `json:"-"`
6958
6959
6960
6961
6962
6963 ForceSendFields []string `json:"-"`
6964
6965
6966
6967
6968 NullFields []string `json:"-"`
6969 }
6970
6971 func (s *TracksListResponse) MarshalJSON() ([]byte, error) {
6972 type NoMethod TracksListResponse
6973 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
6974 }
6975
6976
6977
6978 type UpdateBasePlanStateRequest struct {
6979
6980
6981 ActivateBasePlanRequest *ActivateBasePlanRequest `json:"activateBasePlanRequest,omitempty"`
6982
6983
6984
6985 DeactivateBasePlanRequest *DeactivateBasePlanRequest `json:"deactivateBasePlanRequest,omitempty"`
6986
6987
6988
6989
6990
6991 ForceSendFields []string `json:"-"`
6992
6993
6994
6995
6996 NullFields []string `json:"-"`
6997 }
6998
6999 func (s *UpdateBasePlanStateRequest) MarshalJSON() ([]byte, error) {
7000 type NoMethod UpdateBasePlanStateRequest
7001 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7002 }
7003
7004
7005 type UpdateSubscriptionOfferRequest struct {
7006
7007
7008
7009 AllowMissing bool `json:"allowMissing,omitempty"`
7010
7011
7012
7013
7014
7015
7016
7017
7018
7019
7020
7021
7022 LatencyTolerance string `json:"latencyTolerance,omitempty"`
7023
7024
7025 RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"`
7026
7027 SubscriptionOffer *SubscriptionOffer `json:"subscriptionOffer,omitempty"`
7028
7029 UpdateMask string `json:"updateMask,omitempty"`
7030
7031
7032
7033
7034
7035 ForceSendFields []string `json:"-"`
7036
7037
7038
7039
7040 NullFields []string `json:"-"`
7041 }
7042
7043 func (s *UpdateSubscriptionOfferRequest) MarshalJSON() ([]byte, error) {
7044 type NoMethod UpdateSubscriptionOfferRequest
7045 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7046 }
7047
7048
7049
7050 type UpdateSubscriptionOfferStateRequest struct {
7051
7052
7053 ActivateSubscriptionOfferRequest *ActivateSubscriptionOfferRequest `json:"activateSubscriptionOfferRequest,omitempty"`
7054
7055
7056
7057 DeactivateSubscriptionOfferRequest *DeactivateSubscriptionOfferRequest `json:"deactivateSubscriptionOfferRequest,omitempty"`
7058
7059
7060
7061
7062
7063
7064 ForceSendFields []string `json:"-"`
7065
7066
7067
7068
7069
7070 NullFields []string `json:"-"`
7071 }
7072
7073 func (s *UpdateSubscriptionOfferStateRequest) MarshalJSON() ([]byte, error) {
7074 type NoMethod UpdateSubscriptionOfferStateRequest
7075 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7076 }
7077
7078
7079 type UpdateSubscriptionRequest struct {
7080
7081
7082
7083 AllowMissing bool `json:"allowMissing,omitempty"`
7084
7085
7086
7087
7088
7089
7090
7091
7092
7093
7094
7095
7096 LatencyTolerance string `json:"latencyTolerance,omitempty"`
7097
7098
7099 RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"`
7100
7101 Subscription *Subscription `json:"subscription,omitempty"`
7102
7103 UpdateMask string `json:"updateMask,omitempty"`
7104
7105
7106
7107
7108
7109 ForceSendFields []string `json:"-"`
7110
7111
7112
7113
7114 NullFields []string `json:"-"`
7115 }
7116
7117 func (s *UpdateSubscriptionRequest) MarshalJSON() ([]byte, error) {
7118 type NoMethod UpdateSubscriptionRequest
7119 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7120 }
7121
7122
7123
7124 type UpgradeTargetingRule struct {
7125
7126
7127
7128
7129 BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"`
7130
7131
7132
7133 OncePerUser bool `json:"oncePerUser,omitempty"`
7134
7135
7136 Scope *TargetingRuleScope `json:"scope,omitempty"`
7137
7138
7139
7140
7141
7142 ForceSendFields []string `json:"-"`
7143
7144
7145
7146
7147 NullFields []string `json:"-"`
7148 }
7149
7150 func (s *UpgradeTargetingRule) MarshalJSON() ([]byte, error) {
7151 type NoMethod UpgradeTargetingRule
7152 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7153 }
7154
7155
7156 type User struct {
7157
7158
7159
7160
7161
7162
7163
7164
7165
7166
7167 AccessState string `json:"accessState,omitempty"`
7168
7169
7170
7171
7172
7173
7174
7175
7176
7177
7178
7179
7180
7181
7182
7183
7184
7185
7186
7187
7188
7189
7190
7191
7192
7193
7194
7195
7196
7197
7198
7199
7200
7201
7202 DeveloperAccountPermissions []string `json:"developerAccountPermissions,omitempty"`
7203
7204 Email string `json:"email,omitempty"`
7205
7206
7207 ExpirationTime string `json:"expirationTime,omitempty"`
7208
7209 Grants []*Grant `json:"grants,omitempty"`
7210
7211
7212 Name string `json:"name,omitempty"`
7213
7214
7215
7216
7217
7218
7219
7220
7221 Partial bool `json:"partial,omitempty"`
7222
7223
7224 googleapi.ServerResponse `json:"-"`
7225
7226
7227
7228
7229
7230 ForceSendFields []string `json:"-"`
7231
7232
7233
7234
7235 NullFields []string `json:"-"`
7236 }
7237
7238 func (s *User) MarshalJSON() ([]byte, error) {
7239 type NoMethod User
7240 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7241 }
7242
7243
7244 type UserComment struct {
7245
7246
7247 AndroidOsVersion int64 `json:"androidOsVersion,omitempty"`
7248
7249
7250 AppVersionCode int64 `json:"appVersionCode,omitempty"`
7251
7252
7253 AppVersionName string `json:"appVersionName,omitempty"`
7254
7255
7256 Device string `json:"device,omitempty"`
7257
7258 DeviceMetadata *DeviceMetadata `json:"deviceMetadata,omitempty"`
7259
7260 LastModified *Timestamp `json:"lastModified,omitempty"`
7261
7262
7263 OriginalText string `json:"originalText,omitempty"`
7264
7265
7266
7267 ReviewerLanguage string `json:"reviewerLanguage,omitempty"`
7268
7269 StarRating int64 `json:"starRating,omitempty"`
7270
7271
7272
7273 Text string `json:"text,omitempty"`
7274
7275 ThumbsDownCount int64 `json:"thumbsDownCount,omitempty"`
7276
7277 ThumbsUpCount int64 `json:"thumbsUpCount,omitempty"`
7278
7279
7280
7281
7282
7283 ForceSendFields []string `json:"-"`
7284
7285
7286
7287
7288 NullFields []string `json:"-"`
7289 }
7290
7291 func (s *UserComment) MarshalJSON() ([]byte, error) {
7292 type NoMethod UserComment
7293 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7294 }
7295
7296
7297
7298 type UserCountriesTargeting struct {
7299
7300 CountryCodes []string `json:"countryCodes,omitempty"`
7301
7302 Exclude bool `json:"exclude,omitempty"`
7303
7304
7305
7306
7307
7308 ForceSendFields []string `json:"-"`
7309
7310
7311
7312
7313 NullFields []string `json:"-"`
7314 }
7315
7316 func (s *UserCountriesTargeting) MarshalJSON() ([]byte, error) {
7317 type NoMethod UserCountriesTargeting
7318 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7319 }
7320
7321
7322
7323 type UserCountrySet struct {
7324
7325
7326
7327 CountryCodes []string `json:"countryCodes,omitempty"`
7328
7329 Name string `json:"name,omitempty"`
7330
7331
7332
7333
7334
7335 ForceSendFields []string `json:"-"`
7336
7337
7338
7339
7340 NullFields []string `json:"-"`
7341 }
7342
7343 func (s *UserCountrySet) MarshalJSON() ([]byte, error) {
7344 type NoMethod UserCountrySet
7345 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7346 }
7347
7348
7349
7350 type UserInitiatedCancellation struct {
7351
7352
7353 CancelSurveyResult *CancelSurveyResult `json:"cancelSurveyResult,omitempty"`
7354
7355
7356
7357 CancelTime string `json:"cancelTime,omitempty"`
7358
7359
7360
7361
7362
7363 ForceSendFields []string `json:"-"`
7364
7365
7366
7367
7368 NullFields []string `json:"-"`
7369 }
7370
7371 func (s *UserInitiatedCancellation) MarshalJSON() ([]byte, error) {
7372 type NoMethod UserInitiatedCancellation
7373 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7374 }
7375
7376
7377 type UsesPermission struct {
7378
7379
7380 MaxSdkVersion int64 `json:"maxSdkVersion,omitempty"`
7381
7382 Name string `json:"name,omitempty"`
7383
7384
7385
7386
7387
7388 ForceSendFields []string `json:"-"`
7389
7390
7391
7392
7393 NullFields []string `json:"-"`
7394 }
7395
7396 func (s *UsesPermission) MarshalJSON() ([]byte, error) {
7397 type NoMethod UsesPermission
7398 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7399 }
7400
7401
7402
7403 type Variant struct {
7404
7405 DeviceSpec *DeviceSpec `json:"deviceSpec,omitempty"`
7406
7407 Options *SystemApkOptions `json:"options,omitempty"`
7408
7409 VariantId int64 `json:"variantId,omitempty"`
7410
7411
7412 googleapi.ServerResponse `json:"-"`
7413
7414
7415
7416
7417
7418 ForceSendFields []string `json:"-"`
7419
7420
7421
7422
7423 NullFields []string `json:"-"`
7424 }
7425
7426 func (s *Variant) MarshalJSON() ([]byte, error) {
7427 type NoMethod Variant
7428 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7429 }
7430
7431
7432 type VariantTargeting struct {
7433
7434 AbiTargeting *AbiTargeting `json:"abiTargeting,omitempty"`
7435
7436 MultiAbiTargeting *MultiAbiTargeting `json:"multiAbiTargeting,omitempty"`
7437
7438 ScreenDensityTargeting *ScreenDensityTargeting `json:"screenDensityTargeting,omitempty"`
7439
7440 SdkVersionTargeting *SdkVersionTargeting `json:"sdkVersionTargeting,omitempty"`
7441
7442
7443 TextureCompressionFormatTargeting *TextureCompressionFormatTargeting `json:"textureCompressionFormatTargeting,omitempty"`
7444
7445
7446
7447
7448
7449 ForceSendFields []string `json:"-"`
7450
7451
7452
7453
7454 NullFields []string `json:"-"`
7455 }
7456
7457 func (s *VariantTargeting) MarshalJSON() ([]byte, error) {
7458 type NoMethod VariantTargeting
7459 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7460 }
7461
7462
7463
7464 type VoidedPurchase struct {
7465
7466
7467 Kind string `json:"kind,omitempty"`
7468
7469
7470 OrderId string `json:"orderId,omitempty"`
7471
7472
7473 PurchaseTimeMillis int64 `json:"purchaseTimeMillis,omitempty,string"`
7474
7475
7476
7477 PurchaseToken string `json:"purchaseToken,omitempty"`
7478
7479
7480
7481 VoidedQuantity int64 `json:"voidedQuantity,omitempty"`
7482
7483
7484
7485 VoidedReason int64 `json:"voidedReason,omitempty"`
7486
7487
7488 VoidedSource int64 `json:"voidedSource,omitempty"`
7489
7490
7491
7492 VoidedTimeMillis int64 `json:"voidedTimeMillis,omitempty,string"`
7493
7494
7495
7496
7497
7498 ForceSendFields []string `json:"-"`
7499
7500
7501
7502
7503 NullFields []string `json:"-"`
7504 }
7505
7506 func (s *VoidedPurchase) MarshalJSON() ([]byte, error) {
7507 type NoMethod VoidedPurchase
7508 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7509 }
7510
7511
7512 type VoidedPurchasesListResponse struct {
7513
7514 PageInfo *PageInfo `json:"pageInfo,omitempty"`
7515
7516 TokenPagination *TokenPagination `json:"tokenPagination,omitempty"`
7517 VoidedPurchases []*VoidedPurchase `json:"voidedPurchases,omitempty"`
7518
7519
7520 googleapi.ServerResponse `json:"-"`
7521
7522
7523
7524
7525
7526 ForceSendFields []string `json:"-"`
7527
7528
7529
7530
7531 NullFields []string `json:"-"`
7532 }
7533
7534 func (s *VoidedPurchasesListResponse) MarshalJSON() ([]byte, error) {
7535 type NoMethod VoidedPurchasesListResponse
7536 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
7537 }
7538
7539 type ApplicationsDataSafetyCall struct {
7540 s *Service
7541 packageName string
7542 safetylabelsupdaterequest *SafetyLabelsUpdateRequest
7543 urlParams_ gensupport.URLParams
7544 ctx_ context.Context
7545 header_ http.Header
7546 }
7547
7548
7549
7550
7551 func (r *ApplicationsService) DataSafety(packageName string, safetylabelsupdaterequest *SafetyLabelsUpdateRequest) *ApplicationsDataSafetyCall {
7552 c := &ApplicationsDataSafetyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
7553 c.packageName = packageName
7554 c.safetylabelsupdaterequest = safetylabelsupdaterequest
7555 return c
7556 }
7557
7558
7559
7560
7561 func (c *ApplicationsDataSafetyCall) Fields(s ...googleapi.Field) *ApplicationsDataSafetyCall {
7562 c.urlParams_.Set("fields", googleapi.CombineFields(s))
7563 return c
7564 }
7565
7566
7567 func (c *ApplicationsDataSafetyCall) Context(ctx context.Context) *ApplicationsDataSafetyCall {
7568 c.ctx_ = ctx
7569 return c
7570 }
7571
7572
7573
7574 func (c *ApplicationsDataSafetyCall) Header() http.Header {
7575 if c.header_ == nil {
7576 c.header_ = make(http.Header)
7577 }
7578 return c.header_
7579 }
7580
7581 func (c *ApplicationsDataSafetyCall) doRequest(alt string) (*http.Response, error) {
7582 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
7583 var body io.Reader = nil
7584 body, err := googleapi.WithoutDataWrapper.JSONReader(c.safetylabelsupdaterequest)
7585 if err != nil {
7586 return nil, err
7587 }
7588 c.urlParams_.Set("alt", alt)
7589 c.urlParams_.Set("prettyPrint", "false")
7590 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/dataSafety")
7591 urls += "?" + c.urlParams_.Encode()
7592 req, err := http.NewRequest("POST", urls, body)
7593 if err != nil {
7594 return nil, err
7595 }
7596 req.Header = reqHeaders
7597 googleapi.Expand(req.URL, map[string]string{
7598 "packageName": c.packageName,
7599 })
7600 return gensupport.SendRequest(c.ctx_, c.s.client, req)
7601 }
7602
7603
7604
7605
7606
7607
7608
7609 func (c *ApplicationsDataSafetyCall) Do(opts ...googleapi.CallOption) (*SafetyLabelsUpdateResponse, error) {
7610 gensupport.SetOptions(c.urlParams_, opts...)
7611 res, err := c.doRequest("json")
7612 if res != nil && res.StatusCode == http.StatusNotModified {
7613 if res.Body != nil {
7614 res.Body.Close()
7615 }
7616 return nil, gensupport.WrapError(&googleapi.Error{
7617 Code: res.StatusCode,
7618 Header: res.Header,
7619 })
7620 }
7621 if err != nil {
7622 return nil, err
7623 }
7624 defer googleapi.CloseBody(res)
7625 if err := googleapi.CheckResponse(res); err != nil {
7626 return nil, gensupport.WrapError(err)
7627 }
7628 ret := &SafetyLabelsUpdateResponse{
7629 ServerResponse: googleapi.ServerResponse{
7630 Header: res.Header,
7631 HTTPStatusCode: res.StatusCode,
7632 },
7633 }
7634 target := &ret
7635 if err := gensupport.DecodeResponse(target, res); err != nil {
7636 return nil, err
7637 }
7638 return ret, nil
7639 }
7640
7641 type ApplicationsDeviceTierConfigsCreateCall struct {
7642 s *Service
7643 packageName string
7644 devicetierconfig *DeviceTierConfig
7645 urlParams_ gensupport.URLParams
7646 ctx_ context.Context
7647 header_ http.Header
7648 }
7649
7650
7651
7652
7653 func (r *ApplicationsDeviceTierConfigsService) Create(packageName string, devicetierconfig *DeviceTierConfig) *ApplicationsDeviceTierConfigsCreateCall {
7654 c := &ApplicationsDeviceTierConfigsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
7655 c.packageName = packageName
7656 c.devicetierconfig = devicetierconfig
7657 return c
7658 }
7659
7660
7661
7662
7663 func (c *ApplicationsDeviceTierConfigsCreateCall) AllowUnknownDevices(allowUnknownDevices bool) *ApplicationsDeviceTierConfigsCreateCall {
7664 c.urlParams_.Set("allowUnknownDevices", fmt.Sprint(allowUnknownDevices))
7665 return c
7666 }
7667
7668
7669
7670
7671 func (c *ApplicationsDeviceTierConfigsCreateCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsCreateCall {
7672 c.urlParams_.Set("fields", googleapi.CombineFields(s))
7673 return c
7674 }
7675
7676
7677 func (c *ApplicationsDeviceTierConfigsCreateCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsCreateCall {
7678 c.ctx_ = ctx
7679 return c
7680 }
7681
7682
7683
7684 func (c *ApplicationsDeviceTierConfigsCreateCall) Header() http.Header {
7685 if c.header_ == nil {
7686 c.header_ = make(http.Header)
7687 }
7688 return c.header_
7689 }
7690
7691 func (c *ApplicationsDeviceTierConfigsCreateCall) doRequest(alt string) (*http.Response, error) {
7692 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
7693 var body io.Reader = nil
7694 body, err := googleapi.WithoutDataWrapper.JSONReader(c.devicetierconfig)
7695 if err != nil {
7696 return nil, err
7697 }
7698 c.urlParams_.Set("alt", alt)
7699 c.urlParams_.Set("prettyPrint", "false")
7700 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs")
7701 urls += "?" + c.urlParams_.Encode()
7702 req, err := http.NewRequest("POST", urls, body)
7703 if err != nil {
7704 return nil, err
7705 }
7706 req.Header = reqHeaders
7707 googleapi.Expand(req.URL, map[string]string{
7708 "packageName": c.packageName,
7709 })
7710 return gensupport.SendRequest(c.ctx_, c.s.client, req)
7711 }
7712
7713
7714
7715
7716
7717
7718
7719 func (c *ApplicationsDeviceTierConfigsCreateCall) Do(opts ...googleapi.CallOption) (*DeviceTierConfig, error) {
7720 gensupport.SetOptions(c.urlParams_, opts...)
7721 res, err := c.doRequest("json")
7722 if res != nil && res.StatusCode == http.StatusNotModified {
7723 if res.Body != nil {
7724 res.Body.Close()
7725 }
7726 return nil, gensupport.WrapError(&googleapi.Error{
7727 Code: res.StatusCode,
7728 Header: res.Header,
7729 })
7730 }
7731 if err != nil {
7732 return nil, err
7733 }
7734 defer googleapi.CloseBody(res)
7735 if err := googleapi.CheckResponse(res); err != nil {
7736 return nil, gensupport.WrapError(err)
7737 }
7738 ret := &DeviceTierConfig{
7739 ServerResponse: googleapi.ServerResponse{
7740 Header: res.Header,
7741 HTTPStatusCode: res.StatusCode,
7742 },
7743 }
7744 target := &ret
7745 if err := gensupport.DecodeResponse(target, res); err != nil {
7746 return nil, err
7747 }
7748 return ret, nil
7749 }
7750
7751 type ApplicationsDeviceTierConfigsGetCall struct {
7752 s *Service
7753 packageName string
7754 deviceTierConfigId int64
7755 urlParams_ gensupport.URLParams
7756 ifNoneMatch_ string
7757 ctx_ context.Context
7758 header_ http.Header
7759 }
7760
7761
7762
7763
7764
7765 func (r *ApplicationsDeviceTierConfigsService) Get(packageName string, deviceTierConfigId int64) *ApplicationsDeviceTierConfigsGetCall {
7766 c := &ApplicationsDeviceTierConfigsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
7767 c.packageName = packageName
7768 c.deviceTierConfigId = deviceTierConfigId
7769 return c
7770 }
7771
7772
7773
7774
7775 func (c *ApplicationsDeviceTierConfigsGetCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsGetCall {
7776 c.urlParams_.Set("fields", googleapi.CombineFields(s))
7777 return c
7778 }
7779
7780
7781
7782
7783 func (c *ApplicationsDeviceTierConfigsGetCall) IfNoneMatch(entityTag string) *ApplicationsDeviceTierConfigsGetCall {
7784 c.ifNoneMatch_ = entityTag
7785 return c
7786 }
7787
7788
7789 func (c *ApplicationsDeviceTierConfigsGetCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsGetCall {
7790 c.ctx_ = ctx
7791 return c
7792 }
7793
7794
7795
7796 func (c *ApplicationsDeviceTierConfigsGetCall) Header() http.Header {
7797 if c.header_ == nil {
7798 c.header_ = make(http.Header)
7799 }
7800 return c.header_
7801 }
7802
7803 func (c *ApplicationsDeviceTierConfigsGetCall) doRequest(alt string) (*http.Response, error) {
7804 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
7805 if c.ifNoneMatch_ != "" {
7806 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
7807 }
7808 var body io.Reader = nil
7809 c.urlParams_.Set("alt", alt)
7810 c.urlParams_.Set("prettyPrint", "false")
7811 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs/{deviceTierConfigId}")
7812 urls += "?" + c.urlParams_.Encode()
7813 req, err := http.NewRequest("GET", urls, body)
7814 if err != nil {
7815 return nil, err
7816 }
7817 req.Header = reqHeaders
7818 googleapi.Expand(req.URL, map[string]string{
7819 "packageName": c.packageName,
7820 "deviceTierConfigId": strconv.FormatInt(c.deviceTierConfigId, 10),
7821 })
7822 return gensupport.SendRequest(c.ctx_, c.s.client, req)
7823 }
7824
7825
7826
7827
7828
7829
7830
7831 func (c *ApplicationsDeviceTierConfigsGetCall) Do(opts ...googleapi.CallOption) (*DeviceTierConfig, error) {
7832 gensupport.SetOptions(c.urlParams_, opts...)
7833 res, err := c.doRequest("json")
7834 if res != nil && res.StatusCode == http.StatusNotModified {
7835 if res.Body != nil {
7836 res.Body.Close()
7837 }
7838 return nil, gensupport.WrapError(&googleapi.Error{
7839 Code: res.StatusCode,
7840 Header: res.Header,
7841 })
7842 }
7843 if err != nil {
7844 return nil, err
7845 }
7846 defer googleapi.CloseBody(res)
7847 if err := googleapi.CheckResponse(res); err != nil {
7848 return nil, gensupport.WrapError(err)
7849 }
7850 ret := &DeviceTierConfig{
7851 ServerResponse: googleapi.ServerResponse{
7852 Header: res.Header,
7853 HTTPStatusCode: res.StatusCode,
7854 },
7855 }
7856 target := &ret
7857 if err := gensupport.DecodeResponse(target, res); err != nil {
7858 return nil, err
7859 }
7860 return ret, nil
7861 }
7862
7863 type ApplicationsDeviceTierConfigsListCall struct {
7864 s *Service
7865 packageName string
7866 urlParams_ gensupport.URLParams
7867 ifNoneMatch_ string
7868 ctx_ context.Context
7869 header_ http.Header
7870 }
7871
7872
7873
7874
7875
7876 func (r *ApplicationsDeviceTierConfigsService) List(packageName string) *ApplicationsDeviceTierConfigsListCall {
7877 c := &ApplicationsDeviceTierConfigsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
7878 c.packageName = packageName
7879 return c
7880 }
7881
7882
7883
7884
7885
7886
7887 func (c *ApplicationsDeviceTierConfigsListCall) PageSize(pageSize int64) *ApplicationsDeviceTierConfigsListCall {
7888 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
7889 return c
7890 }
7891
7892
7893
7894
7895 func (c *ApplicationsDeviceTierConfigsListCall) PageToken(pageToken string) *ApplicationsDeviceTierConfigsListCall {
7896 c.urlParams_.Set("pageToken", pageToken)
7897 return c
7898 }
7899
7900
7901
7902
7903 func (c *ApplicationsDeviceTierConfigsListCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsListCall {
7904 c.urlParams_.Set("fields", googleapi.CombineFields(s))
7905 return c
7906 }
7907
7908
7909
7910
7911 func (c *ApplicationsDeviceTierConfigsListCall) IfNoneMatch(entityTag string) *ApplicationsDeviceTierConfigsListCall {
7912 c.ifNoneMatch_ = entityTag
7913 return c
7914 }
7915
7916
7917 func (c *ApplicationsDeviceTierConfigsListCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsListCall {
7918 c.ctx_ = ctx
7919 return c
7920 }
7921
7922
7923
7924 func (c *ApplicationsDeviceTierConfigsListCall) Header() http.Header {
7925 if c.header_ == nil {
7926 c.header_ = make(http.Header)
7927 }
7928 return c.header_
7929 }
7930
7931 func (c *ApplicationsDeviceTierConfigsListCall) doRequest(alt string) (*http.Response, error) {
7932 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
7933 if c.ifNoneMatch_ != "" {
7934 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
7935 }
7936 var body io.Reader = nil
7937 c.urlParams_.Set("alt", alt)
7938 c.urlParams_.Set("prettyPrint", "false")
7939 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs")
7940 urls += "?" + c.urlParams_.Encode()
7941 req, err := http.NewRequest("GET", urls, body)
7942 if err != nil {
7943 return nil, err
7944 }
7945 req.Header = reqHeaders
7946 googleapi.Expand(req.URL, map[string]string{
7947 "packageName": c.packageName,
7948 })
7949 return gensupport.SendRequest(c.ctx_, c.s.client, req)
7950 }
7951
7952
7953
7954
7955
7956
7957
7958 func (c *ApplicationsDeviceTierConfigsListCall) Do(opts ...googleapi.CallOption) (*ListDeviceTierConfigsResponse, error) {
7959 gensupport.SetOptions(c.urlParams_, opts...)
7960 res, err := c.doRequest("json")
7961 if res != nil && res.StatusCode == http.StatusNotModified {
7962 if res.Body != nil {
7963 res.Body.Close()
7964 }
7965 return nil, gensupport.WrapError(&googleapi.Error{
7966 Code: res.StatusCode,
7967 Header: res.Header,
7968 })
7969 }
7970 if err != nil {
7971 return nil, err
7972 }
7973 defer googleapi.CloseBody(res)
7974 if err := googleapi.CheckResponse(res); err != nil {
7975 return nil, gensupport.WrapError(err)
7976 }
7977 ret := &ListDeviceTierConfigsResponse{
7978 ServerResponse: googleapi.ServerResponse{
7979 Header: res.Header,
7980 HTTPStatusCode: res.StatusCode,
7981 },
7982 }
7983 target := &ret
7984 if err := gensupport.DecodeResponse(target, res); err != nil {
7985 return nil, err
7986 }
7987 return ret, nil
7988 }
7989
7990
7991
7992
7993 func (c *ApplicationsDeviceTierConfigsListCall) Pages(ctx context.Context, f func(*ListDeviceTierConfigsResponse) error) error {
7994 c.ctx_ = ctx
7995 defer c.PageToken(c.urlParams_.Get("pageToken"))
7996 for {
7997 x, err := c.Do()
7998 if err != nil {
7999 return err
8000 }
8001 if err := f(x); err != nil {
8002 return err
8003 }
8004 if x.NextPageToken == "" {
8005 return nil
8006 }
8007 c.PageToken(x.NextPageToken)
8008 }
8009 }
8010
8011 type ApprecoveryAddTargetingCall struct {
8012 s *Service
8013 packageName string
8014 appRecoveryId int64
8015 addtargetingrequest *AddTargetingRequest
8016 urlParams_ gensupport.URLParams
8017 ctx_ context.Context
8018 header_ http.Header
8019 }
8020
8021
8022
8023
8024
8025
8026
8027
8028 func (r *ApprecoveryService) AddTargeting(packageName string, appRecoveryId int64, addtargetingrequest *AddTargetingRequest) *ApprecoveryAddTargetingCall {
8029 c := &ApprecoveryAddTargetingCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8030 c.packageName = packageName
8031 c.appRecoveryId = appRecoveryId
8032 c.addtargetingrequest = addtargetingrequest
8033 return c
8034 }
8035
8036
8037
8038
8039 func (c *ApprecoveryAddTargetingCall) Fields(s ...googleapi.Field) *ApprecoveryAddTargetingCall {
8040 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8041 return c
8042 }
8043
8044
8045 func (c *ApprecoveryAddTargetingCall) Context(ctx context.Context) *ApprecoveryAddTargetingCall {
8046 c.ctx_ = ctx
8047 return c
8048 }
8049
8050
8051
8052 func (c *ApprecoveryAddTargetingCall) Header() http.Header {
8053 if c.header_ == nil {
8054 c.header_ = make(http.Header)
8055 }
8056 return c.header_
8057 }
8058
8059 func (c *ApprecoveryAddTargetingCall) doRequest(alt string) (*http.Response, error) {
8060 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
8061 var body io.Reader = nil
8062 body, err := googleapi.WithoutDataWrapper.JSONReader(c.addtargetingrequest)
8063 if err != nil {
8064 return nil, err
8065 }
8066 c.urlParams_.Set("alt", alt)
8067 c.urlParams_.Set("prettyPrint", "false")
8068 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}:addTargeting")
8069 urls += "?" + c.urlParams_.Encode()
8070 req, err := http.NewRequest("POST", urls, body)
8071 if err != nil {
8072 return nil, err
8073 }
8074 req.Header = reqHeaders
8075 googleapi.Expand(req.URL, map[string]string{
8076 "packageName": c.packageName,
8077 "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10),
8078 })
8079 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8080 }
8081
8082
8083
8084
8085
8086
8087
8088 func (c *ApprecoveryAddTargetingCall) Do(opts ...googleapi.CallOption) (*AddTargetingResponse, error) {
8089 gensupport.SetOptions(c.urlParams_, opts...)
8090 res, err := c.doRequest("json")
8091 if res != nil && res.StatusCode == http.StatusNotModified {
8092 if res.Body != nil {
8093 res.Body.Close()
8094 }
8095 return nil, gensupport.WrapError(&googleapi.Error{
8096 Code: res.StatusCode,
8097 Header: res.Header,
8098 })
8099 }
8100 if err != nil {
8101 return nil, err
8102 }
8103 defer googleapi.CloseBody(res)
8104 if err := googleapi.CheckResponse(res); err != nil {
8105 return nil, gensupport.WrapError(err)
8106 }
8107 ret := &AddTargetingResponse{
8108 ServerResponse: googleapi.ServerResponse{
8109 Header: res.Header,
8110 HTTPStatusCode: res.StatusCode,
8111 },
8112 }
8113 target := &ret
8114 if err := gensupport.DecodeResponse(target, res); err != nil {
8115 return nil, err
8116 }
8117 return ret, nil
8118 }
8119
8120 type ApprecoveryAppRecoveriesCall struct {
8121 s *Service
8122 packageName string
8123 urlParams_ gensupport.URLParams
8124 ctx_ context.Context
8125 header_ http.Header
8126 }
8127
8128
8129
8130
8131
8132
8133 func (r *ApprecoveryService) AppRecoveries(packageName string) *ApprecoveryAppRecoveriesCall {
8134 c := &ApprecoveryAppRecoveriesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8135 c.packageName = packageName
8136 return c
8137 }
8138
8139
8140
8141 func (c *ApprecoveryAppRecoveriesCall) VersionCode(versionCode int64) *ApprecoveryAppRecoveriesCall {
8142 c.urlParams_.Set("versionCode", fmt.Sprint(versionCode))
8143 return c
8144 }
8145
8146
8147
8148
8149 func (c *ApprecoveryAppRecoveriesCall) Fields(s ...googleapi.Field) *ApprecoveryAppRecoveriesCall {
8150 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8151 return c
8152 }
8153
8154
8155 func (c *ApprecoveryAppRecoveriesCall) Context(ctx context.Context) *ApprecoveryAppRecoveriesCall {
8156 c.ctx_ = ctx
8157 return c
8158 }
8159
8160
8161
8162 func (c *ApprecoveryAppRecoveriesCall) Header() http.Header {
8163 if c.header_ == nil {
8164 c.header_ = make(http.Header)
8165 }
8166 return c.header_
8167 }
8168
8169 func (c *ApprecoveryAppRecoveriesCall) doRequest(alt string) (*http.Response, error) {
8170 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
8171 var body io.Reader = nil
8172 c.urlParams_.Set("alt", alt)
8173 c.urlParams_.Set("prettyPrint", "false")
8174 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries")
8175 urls += "?" + c.urlParams_.Encode()
8176 req, err := http.NewRequest("POST", urls, body)
8177 if err != nil {
8178 return nil, err
8179 }
8180 req.Header = reqHeaders
8181 googleapi.Expand(req.URL, map[string]string{
8182 "packageName": c.packageName,
8183 })
8184 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8185 }
8186
8187
8188
8189
8190
8191
8192
8193 func (c *ApprecoveryAppRecoveriesCall) Do(opts ...googleapi.CallOption) (*ListAppRecoveriesResponse, error) {
8194 gensupport.SetOptions(c.urlParams_, opts...)
8195 res, err := c.doRequest("json")
8196 if res != nil && res.StatusCode == http.StatusNotModified {
8197 if res.Body != nil {
8198 res.Body.Close()
8199 }
8200 return nil, gensupport.WrapError(&googleapi.Error{
8201 Code: res.StatusCode,
8202 Header: res.Header,
8203 })
8204 }
8205 if err != nil {
8206 return nil, err
8207 }
8208 defer googleapi.CloseBody(res)
8209 if err := googleapi.CheckResponse(res); err != nil {
8210 return nil, gensupport.WrapError(err)
8211 }
8212 ret := &ListAppRecoveriesResponse{
8213 ServerResponse: googleapi.ServerResponse{
8214 Header: res.Header,
8215 HTTPStatusCode: res.StatusCode,
8216 },
8217 }
8218 target := &ret
8219 if err := gensupport.DecodeResponse(target, res); err != nil {
8220 return nil, err
8221 }
8222 return ret, nil
8223 }
8224
8225 type ApprecoveryCancelCall struct {
8226 s *Service
8227 packageName string
8228 appRecoveryId int64
8229 cancelapprecoveryrequest *CancelAppRecoveryRequest
8230 urlParams_ gensupport.URLParams
8231 ctx_ context.Context
8232 header_ http.Header
8233 }
8234
8235
8236
8237
8238
8239
8240
8241 func (r *ApprecoveryService) Cancel(packageName string, appRecoveryId int64, cancelapprecoveryrequest *CancelAppRecoveryRequest) *ApprecoveryCancelCall {
8242 c := &ApprecoveryCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8243 c.packageName = packageName
8244 c.appRecoveryId = appRecoveryId
8245 c.cancelapprecoveryrequest = cancelapprecoveryrequest
8246 return c
8247 }
8248
8249
8250
8251
8252 func (c *ApprecoveryCancelCall) Fields(s ...googleapi.Field) *ApprecoveryCancelCall {
8253 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8254 return c
8255 }
8256
8257
8258 func (c *ApprecoveryCancelCall) Context(ctx context.Context) *ApprecoveryCancelCall {
8259 c.ctx_ = ctx
8260 return c
8261 }
8262
8263
8264
8265 func (c *ApprecoveryCancelCall) Header() http.Header {
8266 if c.header_ == nil {
8267 c.header_ = make(http.Header)
8268 }
8269 return c.header_
8270 }
8271
8272 func (c *ApprecoveryCancelCall) doRequest(alt string) (*http.Response, error) {
8273 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
8274 var body io.Reader = nil
8275 body, err := googleapi.WithoutDataWrapper.JSONReader(c.cancelapprecoveryrequest)
8276 if err != nil {
8277 return nil, err
8278 }
8279 c.urlParams_.Set("alt", alt)
8280 c.urlParams_.Set("prettyPrint", "false")
8281 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}:cancel")
8282 urls += "?" + c.urlParams_.Encode()
8283 req, err := http.NewRequest("POST", urls, body)
8284 if err != nil {
8285 return nil, err
8286 }
8287 req.Header = reqHeaders
8288 googleapi.Expand(req.URL, map[string]string{
8289 "packageName": c.packageName,
8290 "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10),
8291 })
8292 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8293 }
8294
8295
8296
8297
8298
8299
8300
8301 func (c *ApprecoveryCancelCall) Do(opts ...googleapi.CallOption) (*CancelAppRecoveryResponse, error) {
8302 gensupport.SetOptions(c.urlParams_, opts...)
8303 res, err := c.doRequest("json")
8304 if res != nil && res.StatusCode == http.StatusNotModified {
8305 if res.Body != nil {
8306 res.Body.Close()
8307 }
8308 return nil, gensupport.WrapError(&googleapi.Error{
8309 Code: res.StatusCode,
8310 Header: res.Header,
8311 })
8312 }
8313 if err != nil {
8314 return nil, err
8315 }
8316 defer googleapi.CloseBody(res)
8317 if err := googleapi.CheckResponse(res); err != nil {
8318 return nil, gensupport.WrapError(err)
8319 }
8320 ret := &CancelAppRecoveryResponse{
8321 ServerResponse: googleapi.ServerResponse{
8322 Header: res.Header,
8323 HTTPStatusCode: res.StatusCode,
8324 },
8325 }
8326 target := &ret
8327 if err := gensupport.DecodeResponse(target, res); err != nil {
8328 return nil, err
8329 }
8330 return ret, nil
8331 }
8332
8333 type ApprecoveryCreateCall struct {
8334 s *Service
8335 packageName string
8336 createdraftapprecoveryrequest *CreateDraftAppRecoveryRequest
8337 urlParams_ gensupport.URLParams
8338 ctx_ context.Context
8339 header_ http.Header
8340 }
8341
8342
8343
8344
8345
8346
8347 func (r *ApprecoveryService) Create(packageName string, createdraftapprecoveryrequest *CreateDraftAppRecoveryRequest) *ApprecoveryCreateCall {
8348 c := &ApprecoveryCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8349 c.packageName = packageName
8350 c.createdraftapprecoveryrequest = createdraftapprecoveryrequest
8351 return c
8352 }
8353
8354
8355
8356
8357 func (c *ApprecoveryCreateCall) Fields(s ...googleapi.Field) *ApprecoveryCreateCall {
8358 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8359 return c
8360 }
8361
8362
8363 func (c *ApprecoveryCreateCall) Context(ctx context.Context) *ApprecoveryCreateCall {
8364 c.ctx_ = ctx
8365 return c
8366 }
8367
8368
8369
8370 func (c *ApprecoveryCreateCall) Header() http.Header {
8371 if c.header_ == nil {
8372 c.header_ = make(http.Header)
8373 }
8374 return c.header_
8375 }
8376
8377 func (c *ApprecoveryCreateCall) doRequest(alt string) (*http.Response, error) {
8378 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
8379 var body io.Reader = nil
8380 body, err := googleapi.WithoutDataWrapper.JSONReader(c.createdraftapprecoveryrequest)
8381 if err != nil {
8382 return nil, err
8383 }
8384 c.urlParams_.Set("alt", alt)
8385 c.urlParams_.Set("prettyPrint", "false")
8386 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries")
8387 urls += "?" + c.urlParams_.Encode()
8388 req, err := http.NewRequest("POST", urls, body)
8389 if err != nil {
8390 return nil, err
8391 }
8392 req.Header = reqHeaders
8393 googleapi.Expand(req.URL, map[string]string{
8394 "packageName": c.packageName,
8395 })
8396 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8397 }
8398
8399
8400
8401
8402
8403
8404
8405 func (c *ApprecoveryCreateCall) Do(opts ...googleapi.CallOption) (*AppRecoveryAction, error) {
8406 gensupport.SetOptions(c.urlParams_, opts...)
8407 res, err := c.doRequest("json")
8408 if res != nil && res.StatusCode == http.StatusNotModified {
8409 if res.Body != nil {
8410 res.Body.Close()
8411 }
8412 return nil, gensupport.WrapError(&googleapi.Error{
8413 Code: res.StatusCode,
8414 Header: res.Header,
8415 })
8416 }
8417 if err != nil {
8418 return nil, err
8419 }
8420 defer googleapi.CloseBody(res)
8421 if err := googleapi.CheckResponse(res); err != nil {
8422 return nil, gensupport.WrapError(err)
8423 }
8424 ret := &AppRecoveryAction{
8425 ServerResponse: googleapi.ServerResponse{
8426 Header: res.Header,
8427 HTTPStatusCode: res.StatusCode,
8428 },
8429 }
8430 target := &ret
8431 if err := gensupport.DecodeResponse(target, res); err != nil {
8432 return nil, err
8433 }
8434 return ret, nil
8435 }
8436
8437 type ApprecoveryDeployCall struct {
8438 s *Service
8439 packageName string
8440 appRecoveryId int64
8441 deployapprecoveryrequest *DeployAppRecoveryRequest
8442 urlParams_ gensupport.URLParams
8443 ctx_ context.Context
8444 header_ http.Header
8445 }
8446
8447
8448
8449
8450
8451
8452
8453
8454 func (r *ApprecoveryService) Deploy(packageName string, appRecoveryId int64, deployapprecoveryrequest *DeployAppRecoveryRequest) *ApprecoveryDeployCall {
8455 c := &ApprecoveryDeployCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8456 c.packageName = packageName
8457 c.appRecoveryId = appRecoveryId
8458 c.deployapprecoveryrequest = deployapprecoveryrequest
8459 return c
8460 }
8461
8462
8463
8464
8465 func (c *ApprecoveryDeployCall) Fields(s ...googleapi.Field) *ApprecoveryDeployCall {
8466 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8467 return c
8468 }
8469
8470
8471 func (c *ApprecoveryDeployCall) Context(ctx context.Context) *ApprecoveryDeployCall {
8472 c.ctx_ = ctx
8473 return c
8474 }
8475
8476
8477
8478 func (c *ApprecoveryDeployCall) Header() http.Header {
8479 if c.header_ == nil {
8480 c.header_ = make(http.Header)
8481 }
8482 return c.header_
8483 }
8484
8485 func (c *ApprecoveryDeployCall) doRequest(alt string) (*http.Response, error) {
8486 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
8487 var body io.Reader = nil
8488 body, err := googleapi.WithoutDataWrapper.JSONReader(c.deployapprecoveryrequest)
8489 if err != nil {
8490 return nil, err
8491 }
8492 c.urlParams_.Set("alt", alt)
8493 c.urlParams_.Set("prettyPrint", "false")
8494 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}:deploy")
8495 urls += "?" + c.urlParams_.Encode()
8496 req, err := http.NewRequest("POST", urls, body)
8497 if err != nil {
8498 return nil, err
8499 }
8500 req.Header = reqHeaders
8501 googleapi.Expand(req.URL, map[string]string{
8502 "packageName": c.packageName,
8503 "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10),
8504 })
8505 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8506 }
8507
8508
8509
8510
8511
8512
8513
8514 func (c *ApprecoveryDeployCall) Do(opts ...googleapi.CallOption) (*DeployAppRecoveryResponse, error) {
8515 gensupport.SetOptions(c.urlParams_, opts...)
8516 res, err := c.doRequest("json")
8517 if res != nil && res.StatusCode == http.StatusNotModified {
8518 if res.Body != nil {
8519 res.Body.Close()
8520 }
8521 return nil, gensupport.WrapError(&googleapi.Error{
8522 Code: res.StatusCode,
8523 Header: res.Header,
8524 })
8525 }
8526 if err != nil {
8527 return nil, err
8528 }
8529 defer googleapi.CloseBody(res)
8530 if err := googleapi.CheckResponse(res); err != nil {
8531 return nil, gensupport.WrapError(err)
8532 }
8533 ret := &DeployAppRecoveryResponse{
8534 ServerResponse: googleapi.ServerResponse{
8535 Header: res.Header,
8536 HTTPStatusCode: res.StatusCode,
8537 },
8538 }
8539 target := &ret
8540 if err := gensupport.DecodeResponse(target, res); err != nil {
8541 return nil, err
8542 }
8543 return ret, nil
8544 }
8545
8546 type EditsCommitCall struct {
8547 s *Service
8548 packageName string
8549 editId string
8550 urlParams_ gensupport.URLParams
8551 ctx_ context.Context
8552 header_ http.Header
8553 }
8554
8555
8556
8557
8558
8559 func (r *EditsService) Commit(packageName string, editId string) *EditsCommitCall {
8560 c := &EditsCommitCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8561 c.packageName = packageName
8562 c.editId = editId
8563 return c
8564 }
8565
8566
8567
8568
8569
8570
8571 func (c *EditsCommitCall) ChangesNotSentForReview(changesNotSentForReview bool) *EditsCommitCall {
8572 c.urlParams_.Set("changesNotSentForReview", fmt.Sprint(changesNotSentForReview))
8573 return c
8574 }
8575
8576
8577
8578
8579 func (c *EditsCommitCall) Fields(s ...googleapi.Field) *EditsCommitCall {
8580 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8581 return c
8582 }
8583
8584
8585 func (c *EditsCommitCall) Context(ctx context.Context) *EditsCommitCall {
8586 c.ctx_ = ctx
8587 return c
8588 }
8589
8590
8591
8592 func (c *EditsCommitCall) Header() http.Header {
8593 if c.header_ == nil {
8594 c.header_ = make(http.Header)
8595 }
8596 return c.header_
8597 }
8598
8599 func (c *EditsCommitCall) doRequest(alt string) (*http.Response, error) {
8600 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
8601 var body io.Reader = nil
8602 c.urlParams_.Set("alt", alt)
8603 c.urlParams_.Set("prettyPrint", "false")
8604 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}:commit")
8605 urls += "?" + c.urlParams_.Encode()
8606 req, err := http.NewRequest("POST", urls, body)
8607 if err != nil {
8608 return nil, err
8609 }
8610 req.Header = reqHeaders
8611 googleapi.Expand(req.URL, map[string]string{
8612 "packageName": c.packageName,
8613 "editId": c.editId,
8614 })
8615 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8616 }
8617
8618
8619
8620
8621
8622
8623 func (c *EditsCommitCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) {
8624 gensupport.SetOptions(c.urlParams_, opts...)
8625 res, err := c.doRequest("json")
8626 if res != nil && res.StatusCode == http.StatusNotModified {
8627 if res.Body != nil {
8628 res.Body.Close()
8629 }
8630 return nil, gensupport.WrapError(&googleapi.Error{
8631 Code: res.StatusCode,
8632 Header: res.Header,
8633 })
8634 }
8635 if err != nil {
8636 return nil, err
8637 }
8638 defer googleapi.CloseBody(res)
8639 if err := googleapi.CheckResponse(res); err != nil {
8640 return nil, gensupport.WrapError(err)
8641 }
8642 ret := &AppEdit{
8643 ServerResponse: googleapi.ServerResponse{
8644 Header: res.Header,
8645 HTTPStatusCode: res.StatusCode,
8646 },
8647 }
8648 target := &ret
8649 if err := gensupport.DecodeResponse(target, res); err != nil {
8650 return nil, err
8651 }
8652 return ret, nil
8653 }
8654
8655 type EditsDeleteCall struct {
8656 s *Service
8657 packageName string
8658 editId string
8659 urlParams_ gensupport.URLParams
8660 ctx_ context.Context
8661 header_ http.Header
8662 }
8663
8664
8665
8666
8667
8668 func (r *EditsService) Delete(packageName string, editId string) *EditsDeleteCall {
8669 c := &EditsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8670 c.packageName = packageName
8671 c.editId = editId
8672 return c
8673 }
8674
8675
8676
8677
8678 func (c *EditsDeleteCall) Fields(s ...googleapi.Field) *EditsDeleteCall {
8679 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8680 return c
8681 }
8682
8683
8684 func (c *EditsDeleteCall) Context(ctx context.Context) *EditsDeleteCall {
8685 c.ctx_ = ctx
8686 return c
8687 }
8688
8689
8690
8691 func (c *EditsDeleteCall) Header() http.Header {
8692 if c.header_ == nil {
8693 c.header_ = make(http.Header)
8694 }
8695 return c.header_
8696 }
8697
8698 func (c *EditsDeleteCall) doRequest(alt string) (*http.Response, error) {
8699 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
8700 var body io.Reader = nil
8701 c.urlParams_.Set("alt", alt)
8702 c.urlParams_.Set("prettyPrint", "false")
8703 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}")
8704 urls += "?" + c.urlParams_.Encode()
8705 req, err := http.NewRequest("DELETE", urls, body)
8706 if err != nil {
8707 return nil, err
8708 }
8709 req.Header = reqHeaders
8710 googleapi.Expand(req.URL, map[string]string{
8711 "packageName": c.packageName,
8712 "editId": c.editId,
8713 })
8714 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8715 }
8716
8717
8718 func (c *EditsDeleteCall) Do(opts ...googleapi.CallOption) error {
8719 gensupport.SetOptions(c.urlParams_, opts...)
8720 res, err := c.doRequest("json")
8721 if err != nil {
8722 return err
8723 }
8724 defer googleapi.CloseBody(res)
8725 if err := googleapi.CheckResponse(res); err != nil {
8726 return gensupport.WrapError(err)
8727 }
8728 return nil
8729 }
8730
8731 type EditsGetCall struct {
8732 s *Service
8733 packageName string
8734 editId string
8735 urlParams_ gensupport.URLParams
8736 ifNoneMatch_ string
8737 ctx_ context.Context
8738 header_ http.Header
8739 }
8740
8741
8742
8743
8744
8745 func (r *EditsService) Get(packageName string, editId string) *EditsGetCall {
8746 c := &EditsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8747 c.packageName = packageName
8748 c.editId = editId
8749 return c
8750 }
8751
8752
8753
8754
8755 func (c *EditsGetCall) Fields(s ...googleapi.Field) *EditsGetCall {
8756 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8757 return c
8758 }
8759
8760
8761
8762
8763 func (c *EditsGetCall) IfNoneMatch(entityTag string) *EditsGetCall {
8764 c.ifNoneMatch_ = entityTag
8765 return c
8766 }
8767
8768
8769 func (c *EditsGetCall) Context(ctx context.Context) *EditsGetCall {
8770 c.ctx_ = ctx
8771 return c
8772 }
8773
8774
8775
8776 func (c *EditsGetCall) Header() http.Header {
8777 if c.header_ == nil {
8778 c.header_ = make(http.Header)
8779 }
8780 return c.header_
8781 }
8782
8783 func (c *EditsGetCall) doRequest(alt string) (*http.Response, error) {
8784 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
8785 if c.ifNoneMatch_ != "" {
8786 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
8787 }
8788 var body io.Reader = nil
8789 c.urlParams_.Set("alt", alt)
8790 c.urlParams_.Set("prettyPrint", "false")
8791 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}")
8792 urls += "?" + c.urlParams_.Encode()
8793 req, err := http.NewRequest("GET", urls, body)
8794 if err != nil {
8795 return nil, err
8796 }
8797 req.Header = reqHeaders
8798 googleapi.Expand(req.URL, map[string]string{
8799 "packageName": c.packageName,
8800 "editId": c.editId,
8801 })
8802 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8803 }
8804
8805
8806
8807
8808
8809
8810 func (c *EditsGetCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) {
8811 gensupport.SetOptions(c.urlParams_, opts...)
8812 res, err := c.doRequest("json")
8813 if res != nil && res.StatusCode == http.StatusNotModified {
8814 if res.Body != nil {
8815 res.Body.Close()
8816 }
8817 return nil, gensupport.WrapError(&googleapi.Error{
8818 Code: res.StatusCode,
8819 Header: res.Header,
8820 })
8821 }
8822 if err != nil {
8823 return nil, err
8824 }
8825 defer googleapi.CloseBody(res)
8826 if err := googleapi.CheckResponse(res); err != nil {
8827 return nil, gensupport.WrapError(err)
8828 }
8829 ret := &AppEdit{
8830 ServerResponse: googleapi.ServerResponse{
8831 Header: res.Header,
8832 HTTPStatusCode: res.StatusCode,
8833 },
8834 }
8835 target := &ret
8836 if err := gensupport.DecodeResponse(target, res); err != nil {
8837 return nil, err
8838 }
8839 return ret, nil
8840 }
8841
8842 type EditsInsertCall struct {
8843 s *Service
8844 packageName string
8845 appedit *AppEdit
8846 urlParams_ gensupport.URLParams
8847 ctx_ context.Context
8848 header_ http.Header
8849 }
8850
8851
8852
8853
8854 func (r *EditsService) Insert(packageName string, appedit *AppEdit) *EditsInsertCall {
8855 c := &EditsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8856 c.packageName = packageName
8857 c.appedit = appedit
8858 return c
8859 }
8860
8861
8862
8863
8864 func (c *EditsInsertCall) Fields(s ...googleapi.Field) *EditsInsertCall {
8865 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8866 return c
8867 }
8868
8869
8870 func (c *EditsInsertCall) Context(ctx context.Context) *EditsInsertCall {
8871 c.ctx_ = ctx
8872 return c
8873 }
8874
8875
8876
8877 func (c *EditsInsertCall) Header() http.Header {
8878 if c.header_ == nil {
8879 c.header_ = make(http.Header)
8880 }
8881 return c.header_
8882 }
8883
8884 func (c *EditsInsertCall) doRequest(alt string) (*http.Response, error) {
8885 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
8886 var body io.Reader = nil
8887 body, err := googleapi.WithoutDataWrapper.JSONReader(c.appedit)
8888 if err != nil {
8889 return nil, err
8890 }
8891 c.urlParams_.Set("alt", alt)
8892 c.urlParams_.Set("prettyPrint", "false")
8893 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits")
8894 urls += "?" + c.urlParams_.Encode()
8895 req, err := http.NewRequest("POST", urls, body)
8896 if err != nil {
8897 return nil, err
8898 }
8899 req.Header = reqHeaders
8900 googleapi.Expand(req.URL, map[string]string{
8901 "packageName": c.packageName,
8902 })
8903 return gensupport.SendRequest(c.ctx_, c.s.client, req)
8904 }
8905
8906
8907
8908
8909
8910
8911 func (c *EditsInsertCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) {
8912 gensupport.SetOptions(c.urlParams_, opts...)
8913 res, err := c.doRequest("json")
8914 if res != nil && res.StatusCode == http.StatusNotModified {
8915 if res.Body != nil {
8916 res.Body.Close()
8917 }
8918 return nil, gensupport.WrapError(&googleapi.Error{
8919 Code: res.StatusCode,
8920 Header: res.Header,
8921 })
8922 }
8923 if err != nil {
8924 return nil, err
8925 }
8926 defer googleapi.CloseBody(res)
8927 if err := googleapi.CheckResponse(res); err != nil {
8928 return nil, gensupport.WrapError(err)
8929 }
8930 ret := &AppEdit{
8931 ServerResponse: googleapi.ServerResponse{
8932 Header: res.Header,
8933 HTTPStatusCode: res.StatusCode,
8934 },
8935 }
8936 target := &ret
8937 if err := gensupport.DecodeResponse(target, res); err != nil {
8938 return nil, err
8939 }
8940 return ret, nil
8941 }
8942
8943 type EditsValidateCall struct {
8944 s *Service
8945 packageName string
8946 editId string
8947 urlParams_ gensupport.URLParams
8948 ctx_ context.Context
8949 header_ http.Header
8950 }
8951
8952
8953
8954
8955
8956 func (r *EditsService) Validate(packageName string, editId string) *EditsValidateCall {
8957 c := &EditsValidateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
8958 c.packageName = packageName
8959 c.editId = editId
8960 return c
8961 }
8962
8963
8964
8965
8966 func (c *EditsValidateCall) Fields(s ...googleapi.Field) *EditsValidateCall {
8967 c.urlParams_.Set("fields", googleapi.CombineFields(s))
8968 return c
8969 }
8970
8971
8972 func (c *EditsValidateCall) Context(ctx context.Context) *EditsValidateCall {
8973 c.ctx_ = ctx
8974 return c
8975 }
8976
8977
8978
8979 func (c *EditsValidateCall) Header() http.Header {
8980 if c.header_ == nil {
8981 c.header_ = make(http.Header)
8982 }
8983 return c.header_
8984 }
8985
8986 func (c *EditsValidateCall) doRequest(alt string) (*http.Response, error) {
8987 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
8988 var body io.Reader = nil
8989 c.urlParams_.Set("alt", alt)
8990 c.urlParams_.Set("prettyPrint", "false")
8991 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}:validate")
8992 urls += "?" + c.urlParams_.Encode()
8993 req, err := http.NewRequest("POST", urls, body)
8994 if err != nil {
8995 return nil, err
8996 }
8997 req.Header = reqHeaders
8998 googleapi.Expand(req.URL, map[string]string{
8999 "packageName": c.packageName,
9000 "editId": c.editId,
9001 })
9002 return gensupport.SendRequest(c.ctx_, c.s.client, req)
9003 }
9004
9005
9006
9007
9008
9009
9010 func (c *EditsValidateCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) {
9011 gensupport.SetOptions(c.urlParams_, opts...)
9012 res, err := c.doRequest("json")
9013 if res != nil && res.StatusCode == http.StatusNotModified {
9014 if res.Body != nil {
9015 res.Body.Close()
9016 }
9017 return nil, gensupport.WrapError(&googleapi.Error{
9018 Code: res.StatusCode,
9019 Header: res.Header,
9020 })
9021 }
9022 if err != nil {
9023 return nil, err
9024 }
9025 defer googleapi.CloseBody(res)
9026 if err := googleapi.CheckResponse(res); err != nil {
9027 return nil, gensupport.WrapError(err)
9028 }
9029 ret := &AppEdit{
9030 ServerResponse: googleapi.ServerResponse{
9031 Header: res.Header,
9032 HTTPStatusCode: res.StatusCode,
9033 },
9034 }
9035 target := &ret
9036 if err := gensupport.DecodeResponse(target, res); err != nil {
9037 return nil, err
9038 }
9039 return ret, nil
9040 }
9041
9042 type EditsApksAddexternallyhostedCall struct {
9043 s *Service
9044 packageName string
9045 editId string
9046 apksaddexternallyhostedrequest *ApksAddExternallyHostedRequest
9047 urlParams_ gensupport.URLParams
9048 ctx_ context.Context
9049 header_ http.Header
9050 }
9051
9052
9053
9054
9055
9056
9057
9058
9059 func (r *EditsApksService) Addexternallyhosted(packageName string, editId string, apksaddexternallyhostedrequest *ApksAddExternallyHostedRequest) *EditsApksAddexternallyhostedCall {
9060 c := &EditsApksAddexternallyhostedCall{s: r.s, urlParams_: make(gensupport.URLParams)}
9061 c.packageName = packageName
9062 c.editId = editId
9063 c.apksaddexternallyhostedrequest = apksaddexternallyhostedrequest
9064 return c
9065 }
9066
9067
9068
9069
9070 func (c *EditsApksAddexternallyhostedCall) Fields(s ...googleapi.Field) *EditsApksAddexternallyhostedCall {
9071 c.urlParams_.Set("fields", googleapi.CombineFields(s))
9072 return c
9073 }
9074
9075
9076 func (c *EditsApksAddexternallyhostedCall) Context(ctx context.Context) *EditsApksAddexternallyhostedCall {
9077 c.ctx_ = ctx
9078 return c
9079 }
9080
9081
9082
9083 func (c *EditsApksAddexternallyhostedCall) Header() http.Header {
9084 if c.header_ == nil {
9085 c.header_ = make(http.Header)
9086 }
9087 return c.header_
9088 }
9089
9090 func (c *EditsApksAddexternallyhostedCall) doRequest(alt string) (*http.Response, error) {
9091 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
9092 var body io.Reader = nil
9093 body, err := googleapi.WithoutDataWrapper.JSONReader(c.apksaddexternallyhostedrequest)
9094 if err != nil {
9095 return nil, err
9096 }
9097 c.urlParams_.Set("alt", alt)
9098 c.urlParams_.Set("prettyPrint", "false")
9099 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/externallyHosted")
9100 urls += "?" + c.urlParams_.Encode()
9101 req, err := http.NewRequest("POST", urls, body)
9102 if err != nil {
9103 return nil, err
9104 }
9105 req.Header = reqHeaders
9106 googleapi.Expand(req.URL, map[string]string{
9107 "packageName": c.packageName,
9108 "editId": c.editId,
9109 })
9110 return gensupport.SendRequest(c.ctx_, c.s.client, req)
9111 }
9112
9113
9114
9115
9116
9117
9118
9119 func (c *EditsApksAddexternallyhostedCall) Do(opts ...googleapi.CallOption) (*ApksAddExternallyHostedResponse, error) {
9120 gensupport.SetOptions(c.urlParams_, opts...)
9121 res, err := c.doRequest("json")
9122 if res != nil && res.StatusCode == http.StatusNotModified {
9123 if res.Body != nil {
9124 res.Body.Close()
9125 }
9126 return nil, gensupport.WrapError(&googleapi.Error{
9127 Code: res.StatusCode,
9128 Header: res.Header,
9129 })
9130 }
9131 if err != nil {
9132 return nil, err
9133 }
9134 defer googleapi.CloseBody(res)
9135 if err := googleapi.CheckResponse(res); err != nil {
9136 return nil, gensupport.WrapError(err)
9137 }
9138 ret := &ApksAddExternallyHostedResponse{
9139 ServerResponse: googleapi.ServerResponse{
9140 Header: res.Header,
9141 HTTPStatusCode: res.StatusCode,
9142 },
9143 }
9144 target := &ret
9145 if err := gensupport.DecodeResponse(target, res); err != nil {
9146 return nil, err
9147 }
9148 return ret, nil
9149 }
9150
9151 type EditsApksListCall struct {
9152 s *Service
9153 packageName string
9154 editId string
9155 urlParams_ gensupport.URLParams
9156 ifNoneMatch_ string
9157 ctx_ context.Context
9158 header_ http.Header
9159 }
9160
9161
9162
9163
9164
9165 func (r *EditsApksService) List(packageName string, editId string) *EditsApksListCall {
9166 c := &EditsApksListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
9167 c.packageName = packageName
9168 c.editId = editId
9169 return c
9170 }
9171
9172
9173
9174
9175 func (c *EditsApksListCall) Fields(s ...googleapi.Field) *EditsApksListCall {
9176 c.urlParams_.Set("fields", googleapi.CombineFields(s))
9177 return c
9178 }
9179
9180
9181
9182
9183 func (c *EditsApksListCall) IfNoneMatch(entityTag string) *EditsApksListCall {
9184 c.ifNoneMatch_ = entityTag
9185 return c
9186 }
9187
9188
9189 func (c *EditsApksListCall) Context(ctx context.Context) *EditsApksListCall {
9190 c.ctx_ = ctx
9191 return c
9192 }
9193
9194
9195
9196 func (c *EditsApksListCall) Header() http.Header {
9197 if c.header_ == nil {
9198 c.header_ = make(http.Header)
9199 }
9200 return c.header_
9201 }
9202
9203 func (c *EditsApksListCall) doRequest(alt string) (*http.Response, error) {
9204 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
9205 if c.ifNoneMatch_ != "" {
9206 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
9207 }
9208 var body io.Reader = nil
9209 c.urlParams_.Set("alt", alt)
9210 c.urlParams_.Set("prettyPrint", "false")
9211 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks")
9212 urls += "?" + c.urlParams_.Encode()
9213 req, err := http.NewRequest("GET", urls, body)
9214 if err != nil {
9215 return nil, err
9216 }
9217 req.Header = reqHeaders
9218 googleapi.Expand(req.URL, map[string]string{
9219 "packageName": c.packageName,
9220 "editId": c.editId,
9221 })
9222 return gensupport.SendRequest(c.ctx_, c.s.client, req)
9223 }
9224
9225
9226
9227
9228
9229
9230
9231 func (c *EditsApksListCall) Do(opts ...googleapi.CallOption) (*ApksListResponse, error) {
9232 gensupport.SetOptions(c.urlParams_, opts...)
9233 res, err := c.doRequest("json")
9234 if res != nil && res.StatusCode == http.StatusNotModified {
9235 if res.Body != nil {
9236 res.Body.Close()
9237 }
9238 return nil, gensupport.WrapError(&googleapi.Error{
9239 Code: res.StatusCode,
9240 Header: res.Header,
9241 })
9242 }
9243 if err != nil {
9244 return nil, err
9245 }
9246 defer googleapi.CloseBody(res)
9247 if err := googleapi.CheckResponse(res); err != nil {
9248 return nil, gensupport.WrapError(err)
9249 }
9250 ret := &ApksListResponse{
9251 ServerResponse: googleapi.ServerResponse{
9252 Header: res.Header,
9253 HTTPStatusCode: res.StatusCode,
9254 },
9255 }
9256 target := &ret
9257 if err := gensupport.DecodeResponse(target, res); err != nil {
9258 return nil, err
9259 }
9260 return ret, nil
9261 }
9262
9263 type EditsApksUploadCall struct {
9264 s *Service
9265 packageName string
9266 editId string
9267 urlParams_ gensupport.URLParams
9268 mediaInfo_ *gensupport.MediaInfo
9269 ctx_ context.Context
9270 header_ http.Header
9271 }
9272
9273
9274
9275
9276
9277 func (r *EditsApksService) Upload(packageName string, editId string) *EditsApksUploadCall {
9278 c := &EditsApksUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
9279 c.packageName = packageName
9280 c.editId = editId
9281 return c
9282 }
9283
9284
9285
9286
9287
9288
9289
9290
9291 func (c *EditsApksUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsApksUploadCall {
9292 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
9293 return c
9294 }
9295
9296
9297
9298
9299
9300
9301
9302
9303
9304
9305 func (c *EditsApksUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsApksUploadCall {
9306 c.ctx_ = ctx
9307 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
9308 return c
9309 }
9310
9311
9312
9313
9314
9315 func (c *EditsApksUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsApksUploadCall {
9316 c.mediaInfo_.SetProgressUpdater(pu)
9317 return c
9318 }
9319
9320
9321
9322
9323 func (c *EditsApksUploadCall) Fields(s ...googleapi.Field) *EditsApksUploadCall {
9324 c.urlParams_.Set("fields", googleapi.CombineFields(s))
9325 return c
9326 }
9327
9328
9329
9330
9331 func (c *EditsApksUploadCall) Context(ctx context.Context) *EditsApksUploadCall {
9332 c.ctx_ = ctx
9333 return c
9334 }
9335
9336
9337
9338 func (c *EditsApksUploadCall) Header() http.Header {
9339 if c.header_ == nil {
9340 c.header_ = make(http.Header)
9341 }
9342 return c.header_
9343 }
9344
9345 func (c *EditsApksUploadCall) doRequest(alt string) (*http.Response, error) {
9346 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
9347 var body io.Reader = nil
9348 c.urlParams_.Set("alt", alt)
9349 c.urlParams_.Set("prettyPrint", "false")
9350 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks")
9351 if c.mediaInfo_ != nil {
9352 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks")
9353 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
9354 }
9355 if body == nil {
9356 body = new(bytes.Buffer)
9357 reqHeaders.Set("Content-Type", "application/json")
9358 }
9359 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
9360 defer cleanup()
9361 urls += "?" + c.urlParams_.Encode()
9362 req, err := http.NewRequest("POST", urls, body)
9363 if err != nil {
9364 return nil, err
9365 }
9366 req.Header = reqHeaders
9367 req.GetBody = getBody
9368 googleapi.Expand(req.URL, map[string]string{
9369 "packageName": c.packageName,
9370 "editId": c.editId,
9371 })
9372 return gensupport.SendRequest(c.ctx_, c.s.client, req)
9373 }
9374
9375
9376
9377
9378
9379
9380 func (c *EditsApksUploadCall) Do(opts ...googleapi.CallOption) (*Apk, error) {
9381 gensupport.SetOptions(c.urlParams_, opts...)
9382 res, err := c.doRequest("json")
9383 if res != nil && res.StatusCode == http.StatusNotModified {
9384 if res.Body != nil {
9385 res.Body.Close()
9386 }
9387 return nil, gensupport.WrapError(&googleapi.Error{
9388 Code: res.StatusCode,
9389 Header: res.Header,
9390 })
9391 }
9392 if err != nil {
9393 return nil, err
9394 }
9395 defer googleapi.CloseBody(res)
9396 if err := googleapi.CheckResponse(res); err != nil {
9397 return nil, gensupport.WrapError(err)
9398 }
9399 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
9400 if rx != nil {
9401 rx.Client = c.s.client
9402 rx.UserAgent = c.s.userAgent()
9403 ctx := c.ctx_
9404 if ctx == nil {
9405 ctx = context.TODO()
9406 }
9407 res, err = rx.Upload(ctx)
9408 if err != nil {
9409 return nil, err
9410 }
9411 defer res.Body.Close()
9412 if err := googleapi.CheckResponse(res); err != nil {
9413 return nil, gensupport.WrapError(err)
9414 }
9415 }
9416 ret := &Apk{
9417 ServerResponse: googleapi.ServerResponse{
9418 Header: res.Header,
9419 HTTPStatusCode: res.StatusCode,
9420 },
9421 }
9422 target := &ret
9423 if err := gensupport.DecodeResponse(target, res); err != nil {
9424 return nil, err
9425 }
9426 return ret, nil
9427 }
9428
9429 type EditsBundlesListCall struct {
9430 s *Service
9431 packageName string
9432 editId string
9433 urlParams_ gensupport.URLParams
9434 ifNoneMatch_ string
9435 ctx_ context.Context
9436 header_ http.Header
9437 }
9438
9439
9440
9441
9442
9443 func (r *EditsBundlesService) List(packageName string, editId string) *EditsBundlesListCall {
9444 c := &EditsBundlesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
9445 c.packageName = packageName
9446 c.editId = editId
9447 return c
9448 }
9449
9450
9451
9452
9453 func (c *EditsBundlesListCall) Fields(s ...googleapi.Field) *EditsBundlesListCall {
9454 c.urlParams_.Set("fields", googleapi.CombineFields(s))
9455 return c
9456 }
9457
9458
9459
9460
9461 func (c *EditsBundlesListCall) IfNoneMatch(entityTag string) *EditsBundlesListCall {
9462 c.ifNoneMatch_ = entityTag
9463 return c
9464 }
9465
9466
9467 func (c *EditsBundlesListCall) Context(ctx context.Context) *EditsBundlesListCall {
9468 c.ctx_ = ctx
9469 return c
9470 }
9471
9472
9473
9474 func (c *EditsBundlesListCall) Header() http.Header {
9475 if c.header_ == nil {
9476 c.header_ = make(http.Header)
9477 }
9478 return c.header_
9479 }
9480
9481 func (c *EditsBundlesListCall) doRequest(alt string) (*http.Response, error) {
9482 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
9483 if c.ifNoneMatch_ != "" {
9484 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
9485 }
9486 var body io.Reader = nil
9487 c.urlParams_.Set("alt", alt)
9488 c.urlParams_.Set("prettyPrint", "false")
9489 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles")
9490 urls += "?" + c.urlParams_.Encode()
9491 req, err := http.NewRequest("GET", urls, body)
9492 if err != nil {
9493 return nil, err
9494 }
9495 req.Header = reqHeaders
9496 googleapi.Expand(req.URL, map[string]string{
9497 "packageName": c.packageName,
9498 "editId": c.editId,
9499 })
9500 return gensupport.SendRequest(c.ctx_, c.s.client, req)
9501 }
9502
9503
9504
9505
9506
9507
9508
9509 func (c *EditsBundlesListCall) Do(opts ...googleapi.CallOption) (*BundlesListResponse, error) {
9510 gensupport.SetOptions(c.urlParams_, opts...)
9511 res, err := c.doRequest("json")
9512 if res != nil && res.StatusCode == http.StatusNotModified {
9513 if res.Body != nil {
9514 res.Body.Close()
9515 }
9516 return nil, gensupport.WrapError(&googleapi.Error{
9517 Code: res.StatusCode,
9518 Header: res.Header,
9519 })
9520 }
9521 if err != nil {
9522 return nil, err
9523 }
9524 defer googleapi.CloseBody(res)
9525 if err := googleapi.CheckResponse(res); err != nil {
9526 return nil, gensupport.WrapError(err)
9527 }
9528 ret := &BundlesListResponse{
9529 ServerResponse: googleapi.ServerResponse{
9530 Header: res.Header,
9531 HTTPStatusCode: res.StatusCode,
9532 },
9533 }
9534 target := &ret
9535 if err := gensupport.DecodeResponse(target, res); err != nil {
9536 return nil, err
9537 }
9538 return ret, nil
9539 }
9540
9541 type EditsBundlesUploadCall struct {
9542 s *Service
9543 packageName string
9544 editId string
9545 urlParams_ gensupport.URLParams
9546 mediaInfo_ *gensupport.MediaInfo
9547 ctx_ context.Context
9548 header_ http.Header
9549 }
9550
9551
9552
9553
9554
9555
9556
9557
9558
9559
9560 func (r *EditsBundlesService) Upload(packageName string, editId string) *EditsBundlesUploadCall {
9561 c := &EditsBundlesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
9562 c.packageName = packageName
9563 c.editId = editId
9564 return c
9565 }
9566
9567
9568
9569
9570
9571 func (c *EditsBundlesUploadCall) AckBundleInstallationWarning(ackBundleInstallationWarning bool) *EditsBundlesUploadCall {
9572 c.urlParams_.Set("ackBundleInstallationWarning", fmt.Sprint(ackBundleInstallationWarning))
9573 return c
9574 }
9575
9576
9577
9578
9579 func (c *EditsBundlesUploadCall) DeviceTierConfigId(deviceTierConfigId string) *EditsBundlesUploadCall {
9580 c.urlParams_.Set("deviceTierConfigId", deviceTierConfigId)
9581 return c
9582 }
9583
9584
9585
9586
9587
9588
9589
9590
9591 func (c *EditsBundlesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsBundlesUploadCall {
9592 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
9593 return c
9594 }
9595
9596
9597
9598
9599
9600
9601
9602
9603
9604
9605 func (c *EditsBundlesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsBundlesUploadCall {
9606 c.ctx_ = ctx
9607 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
9608 return c
9609 }
9610
9611
9612
9613
9614
9615 func (c *EditsBundlesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsBundlesUploadCall {
9616 c.mediaInfo_.SetProgressUpdater(pu)
9617 return c
9618 }
9619
9620
9621
9622
9623 func (c *EditsBundlesUploadCall) Fields(s ...googleapi.Field) *EditsBundlesUploadCall {
9624 c.urlParams_.Set("fields", googleapi.CombineFields(s))
9625 return c
9626 }
9627
9628
9629
9630
9631 func (c *EditsBundlesUploadCall) Context(ctx context.Context) *EditsBundlesUploadCall {
9632 c.ctx_ = ctx
9633 return c
9634 }
9635
9636
9637
9638 func (c *EditsBundlesUploadCall) Header() http.Header {
9639 if c.header_ == nil {
9640 c.header_ = make(http.Header)
9641 }
9642 return c.header_
9643 }
9644
9645 func (c *EditsBundlesUploadCall) doRequest(alt string) (*http.Response, error) {
9646 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
9647 var body io.Reader = nil
9648 c.urlParams_.Set("alt", alt)
9649 c.urlParams_.Set("prettyPrint", "false")
9650 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles")
9651 if c.mediaInfo_ != nil {
9652 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles")
9653 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
9654 }
9655 if body == nil {
9656 body = new(bytes.Buffer)
9657 reqHeaders.Set("Content-Type", "application/json")
9658 }
9659 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
9660 defer cleanup()
9661 urls += "?" + c.urlParams_.Encode()
9662 req, err := http.NewRequest("POST", urls, body)
9663 if err != nil {
9664 return nil, err
9665 }
9666 req.Header = reqHeaders
9667 req.GetBody = getBody
9668 googleapi.Expand(req.URL, map[string]string{
9669 "packageName": c.packageName,
9670 "editId": c.editId,
9671 })
9672 return gensupport.SendRequest(c.ctx_, c.s.client, req)
9673 }
9674
9675
9676
9677
9678
9679
9680 func (c *EditsBundlesUploadCall) Do(opts ...googleapi.CallOption) (*Bundle, error) {
9681 gensupport.SetOptions(c.urlParams_, opts...)
9682 res, err := c.doRequest("json")
9683 if res != nil && res.StatusCode == http.StatusNotModified {
9684 if res.Body != nil {
9685 res.Body.Close()
9686 }
9687 return nil, gensupport.WrapError(&googleapi.Error{
9688 Code: res.StatusCode,
9689 Header: res.Header,
9690 })
9691 }
9692 if err != nil {
9693 return nil, err
9694 }
9695 defer googleapi.CloseBody(res)
9696 if err := googleapi.CheckResponse(res); err != nil {
9697 return nil, gensupport.WrapError(err)
9698 }
9699 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
9700 if rx != nil {
9701 rx.Client = c.s.client
9702 rx.UserAgent = c.s.userAgent()
9703 ctx := c.ctx_
9704 if ctx == nil {
9705 ctx = context.TODO()
9706 }
9707 res, err = rx.Upload(ctx)
9708 if err != nil {
9709 return nil, err
9710 }
9711 defer res.Body.Close()
9712 if err := googleapi.CheckResponse(res); err != nil {
9713 return nil, gensupport.WrapError(err)
9714 }
9715 }
9716 ret := &Bundle{
9717 ServerResponse: googleapi.ServerResponse{
9718 Header: res.Header,
9719 HTTPStatusCode: res.StatusCode,
9720 },
9721 }
9722 target := &ret
9723 if err := gensupport.DecodeResponse(target, res); err != nil {
9724 return nil, err
9725 }
9726 return ret, nil
9727 }
9728
9729 type EditsCountryavailabilityGetCall struct {
9730 s *Service
9731 packageName string
9732 editId string
9733 track string
9734 urlParams_ gensupport.URLParams
9735 ifNoneMatch_ string
9736 ctx_ context.Context
9737 header_ http.Header
9738 }
9739
9740
9741
9742
9743
9744
9745 func (r *EditsCountryavailabilityService) Get(packageName string, editId string, track string) *EditsCountryavailabilityGetCall {
9746 c := &EditsCountryavailabilityGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
9747 c.packageName = packageName
9748 c.editId = editId
9749 c.track = track
9750 return c
9751 }
9752
9753
9754
9755
9756 func (c *EditsCountryavailabilityGetCall) Fields(s ...googleapi.Field) *EditsCountryavailabilityGetCall {
9757 c.urlParams_.Set("fields", googleapi.CombineFields(s))
9758 return c
9759 }
9760
9761
9762
9763
9764 func (c *EditsCountryavailabilityGetCall) IfNoneMatch(entityTag string) *EditsCountryavailabilityGetCall {
9765 c.ifNoneMatch_ = entityTag
9766 return c
9767 }
9768
9769
9770 func (c *EditsCountryavailabilityGetCall) Context(ctx context.Context) *EditsCountryavailabilityGetCall {
9771 c.ctx_ = ctx
9772 return c
9773 }
9774
9775
9776
9777 func (c *EditsCountryavailabilityGetCall) Header() http.Header {
9778 if c.header_ == nil {
9779 c.header_ = make(http.Header)
9780 }
9781 return c.header_
9782 }
9783
9784 func (c *EditsCountryavailabilityGetCall) doRequest(alt string) (*http.Response, error) {
9785 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
9786 if c.ifNoneMatch_ != "" {
9787 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
9788 }
9789 var body io.Reader = nil
9790 c.urlParams_.Set("alt", alt)
9791 c.urlParams_.Set("prettyPrint", "false")
9792 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/countryAvailability/{track}")
9793 urls += "?" + c.urlParams_.Encode()
9794 req, err := http.NewRequest("GET", urls, body)
9795 if err != nil {
9796 return nil, err
9797 }
9798 req.Header = reqHeaders
9799 googleapi.Expand(req.URL, map[string]string{
9800 "packageName": c.packageName,
9801 "editId": c.editId,
9802 "track": c.track,
9803 })
9804 return gensupport.SendRequest(c.ctx_, c.s.client, req)
9805 }
9806
9807
9808
9809
9810
9811
9812
9813 func (c *EditsCountryavailabilityGetCall) Do(opts ...googleapi.CallOption) (*TrackCountryAvailability, error) {
9814 gensupport.SetOptions(c.urlParams_, opts...)
9815 res, err := c.doRequest("json")
9816 if res != nil && res.StatusCode == http.StatusNotModified {
9817 if res.Body != nil {
9818 res.Body.Close()
9819 }
9820 return nil, gensupport.WrapError(&googleapi.Error{
9821 Code: res.StatusCode,
9822 Header: res.Header,
9823 })
9824 }
9825 if err != nil {
9826 return nil, err
9827 }
9828 defer googleapi.CloseBody(res)
9829 if err := googleapi.CheckResponse(res); err != nil {
9830 return nil, gensupport.WrapError(err)
9831 }
9832 ret := &TrackCountryAvailability{
9833 ServerResponse: googleapi.ServerResponse{
9834 Header: res.Header,
9835 HTTPStatusCode: res.StatusCode,
9836 },
9837 }
9838 target := &ret
9839 if err := gensupport.DecodeResponse(target, res); err != nil {
9840 return nil, err
9841 }
9842 return ret, nil
9843 }
9844
9845 type EditsDeobfuscationfilesUploadCall struct {
9846 s *Service
9847 packageNameid string
9848 editId string
9849 apkVersionCode int64
9850 deobfuscationFileType string
9851 urlParams_ gensupport.URLParams
9852 mediaInfo_ *gensupport.MediaInfo
9853 ctx_ context.Context
9854 header_ http.Header
9855 }
9856
9857
9858
9859
9860
9861
9862
9863
9864 func (r *EditsDeobfuscationfilesService) Upload(packageNameid string, editId string, apkVersionCode int64, deobfuscationFileType string) *EditsDeobfuscationfilesUploadCall {
9865 c := &EditsDeobfuscationfilesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
9866 c.packageNameid = packageNameid
9867 c.editId = editId
9868 c.apkVersionCode = apkVersionCode
9869 c.deobfuscationFileType = deobfuscationFileType
9870 return c
9871 }
9872
9873
9874
9875
9876
9877
9878
9879
9880 func (c *EditsDeobfuscationfilesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsDeobfuscationfilesUploadCall {
9881 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
9882 return c
9883 }
9884
9885
9886
9887
9888
9889
9890
9891
9892
9893
9894 func (c *EditsDeobfuscationfilesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsDeobfuscationfilesUploadCall {
9895 c.ctx_ = ctx
9896 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
9897 return c
9898 }
9899
9900
9901
9902
9903
9904 func (c *EditsDeobfuscationfilesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsDeobfuscationfilesUploadCall {
9905 c.mediaInfo_.SetProgressUpdater(pu)
9906 return c
9907 }
9908
9909
9910
9911
9912 func (c *EditsDeobfuscationfilesUploadCall) Fields(s ...googleapi.Field) *EditsDeobfuscationfilesUploadCall {
9913 c.urlParams_.Set("fields", googleapi.CombineFields(s))
9914 return c
9915 }
9916
9917
9918
9919
9920 func (c *EditsDeobfuscationfilesUploadCall) Context(ctx context.Context) *EditsDeobfuscationfilesUploadCall {
9921 c.ctx_ = ctx
9922 return c
9923 }
9924
9925
9926
9927 func (c *EditsDeobfuscationfilesUploadCall) Header() http.Header {
9928 if c.header_ == nil {
9929 c.header_ = make(http.Header)
9930 }
9931 return c.header_
9932 }
9933
9934 func (c *EditsDeobfuscationfilesUploadCall) doRequest(alt string) (*http.Response, error) {
9935 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
9936 var body io.Reader = nil
9937 c.urlParams_.Set("alt", alt)
9938 c.urlParams_.Set("prettyPrint", "false")
9939 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/deobfuscationFiles/{deobfuscationFileType}")
9940 if c.mediaInfo_ != nil {
9941 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/deobfuscationFiles/{deobfuscationFileType}")
9942 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
9943 }
9944 if body == nil {
9945 body = new(bytes.Buffer)
9946 reqHeaders.Set("Content-Type", "application/json")
9947 }
9948 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
9949 defer cleanup()
9950 urls += "?" + c.urlParams_.Encode()
9951 req, err := http.NewRequest("POST", urls, body)
9952 if err != nil {
9953 return nil, err
9954 }
9955 req.Header = reqHeaders
9956 req.GetBody = getBody
9957 googleapi.Expand(req.URL, map[string]string{
9958 "packageName": c.packageNameid,
9959 "editId": c.editId,
9960 "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10),
9961 "deobfuscationFileType": c.deobfuscationFileType,
9962 })
9963 return gensupport.SendRequest(c.ctx_, c.s.client, req)
9964 }
9965
9966
9967
9968
9969
9970
9971
9972 func (c *EditsDeobfuscationfilesUploadCall) Do(opts ...googleapi.CallOption) (*DeobfuscationFilesUploadResponse, error) {
9973 gensupport.SetOptions(c.urlParams_, opts...)
9974 res, err := c.doRequest("json")
9975 if res != nil && res.StatusCode == http.StatusNotModified {
9976 if res.Body != nil {
9977 res.Body.Close()
9978 }
9979 return nil, gensupport.WrapError(&googleapi.Error{
9980 Code: res.StatusCode,
9981 Header: res.Header,
9982 })
9983 }
9984 if err != nil {
9985 return nil, err
9986 }
9987 defer googleapi.CloseBody(res)
9988 if err := googleapi.CheckResponse(res); err != nil {
9989 return nil, gensupport.WrapError(err)
9990 }
9991 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
9992 if rx != nil {
9993 rx.Client = c.s.client
9994 rx.UserAgent = c.s.userAgent()
9995 ctx := c.ctx_
9996 if ctx == nil {
9997 ctx = context.TODO()
9998 }
9999 res, err = rx.Upload(ctx)
10000 if err != nil {
10001 return nil, err
10002 }
10003 defer res.Body.Close()
10004 if err := googleapi.CheckResponse(res); err != nil {
10005 return nil, gensupport.WrapError(err)
10006 }
10007 }
10008 ret := &DeobfuscationFilesUploadResponse{
10009 ServerResponse: googleapi.ServerResponse{
10010 Header: res.Header,
10011 HTTPStatusCode: res.StatusCode,
10012 },
10013 }
10014 target := &ret
10015 if err := gensupport.DecodeResponse(target, res); err != nil {
10016 return nil, err
10017 }
10018 return ret, nil
10019 }
10020
10021 type EditsDetailsGetCall struct {
10022 s *Service
10023 packageName string
10024 editId string
10025 urlParams_ gensupport.URLParams
10026 ifNoneMatch_ string
10027 ctx_ context.Context
10028 header_ http.Header
10029 }
10030
10031
10032
10033
10034
10035 func (r *EditsDetailsService) Get(packageName string, editId string) *EditsDetailsGetCall {
10036 c := &EditsDetailsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10037 c.packageName = packageName
10038 c.editId = editId
10039 return c
10040 }
10041
10042
10043
10044
10045 func (c *EditsDetailsGetCall) Fields(s ...googleapi.Field) *EditsDetailsGetCall {
10046 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10047 return c
10048 }
10049
10050
10051
10052
10053 func (c *EditsDetailsGetCall) IfNoneMatch(entityTag string) *EditsDetailsGetCall {
10054 c.ifNoneMatch_ = entityTag
10055 return c
10056 }
10057
10058
10059 func (c *EditsDetailsGetCall) Context(ctx context.Context) *EditsDetailsGetCall {
10060 c.ctx_ = ctx
10061 return c
10062 }
10063
10064
10065
10066 func (c *EditsDetailsGetCall) Header() http.Header {
10067 if c.header_ == nil {
10068 c.header_ = make(http.Header)
10069 }
10070 return c.header_
10071 }
10072
10073 func (c *EditsDetailsGetCall) doRequest(alt string) (*http.Response, error) {
10074 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
10075 if c.ifNoneMatch_ != "" {
10076 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
10077 }
10078 var body io.Reader = nil
10079 c.urlParams_.Set("alt", alt)
10080 c.urlParams_.Set("prettyPrint", "false")
10081 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details")
10082 urls += "?" + c.urlParams_.Encode()
10083 req, err := http.NewRequest("GET", urls, body)
10084 if err != nil {
10085 return nil, err
10086 }
10087 req.Header = reqHeaders
10088 googleapi.Expand(req.URL, map[string]string{
10089 "packageName": c.packageName,
10090 "editId": c.editId,
10091 })
10092 return gensupport.SendRequest(c.ctx_, c.s.client, req)
10093 }
10094
10095
10096
10097
10098
10099
10100 func (c *EditsDetailsGetCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) {
10101 gensupport.SetOptions(c.urlParams_, opts...)
10102 res, err := c.doRequest("json")
10103 if res != nil && res.StatusCode == http.StatusNotModified {
10104 if res.Body != nil {
10105 res.Body.Close()
10106 }
10107 return nil, gensupport.WrapError(&googleapi.Error{
10108 Code: res.StatusCode,
10109 Header: res.Header,
10110 })
10111 }
10112 if err != nil {
10113 return nil, err
10114 }
10115 defer googleapi.CloseBody(res)
10116 if err := googleapi.CheckResponse(res); err != nil {
10117 return nil, gensupport.WrapError(err)
10118 }
10119 ret := &AppDetails{
10120 ServerResponse: googleapi.ServerResponse{
10121 Header: res.Header,
10122 HTTPStatusCode: res.StatusCode,
10123 },
10124 }
10125 target := &ret
10126 if err := gensupport.DecodeResponse(target, res); err != nil {
10127 return nil, err
10128 }
10129 return ret, nil
10130 }
10131
10132 type EditsDetailsPatchCall struct {
10133 s *Service
10134 packageName string
10135 editId string
10136 appdetails *AppDetails
10137 urlParams_ gensupport.URLParams
10138 ctx_ context.Context
10139 header_ http.Header
10140 }
10141
10142
10143
10144
10145
10146 func (r *EditsDetailsService) Patch(packageName string, editId string, appdetails *AppDetails) *EditsDetailsPatchCall {
10147 c := &EditsDetailsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10148 c.packageName = packageName
10149 c.editId = editId
10150 c.appdetails = appdetails
10151 return c
10152 }
10153
10154
10155
10156
10157 func (c *EditsDetailsPatchCall) Fields(s ...googleapi.Field) *EditsDetailsPatchCall {
10158 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10159 return c
10160 }
10161
10162
10163 func (c *EditsDetailsPatchCall) Context(ctx context.Context) *EditsDetailsPatchCall {
10164 c.ctx_ = ctx
10165 return c
10166 }
10167
10168
10169
10170 func (c *EditsDetailsPatchCall) Header() http.Header {
10171 if c.header_ == nil {
10172 c.header_ = make(http.Header)
10173 }
10174 return c.header_
10175 }
10176
10177 func (c *EditsDetailsPatchCall) doRequest(alt string) (*http.Response, error) {
10178 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
10179 var body io.Reader = nil
10180 body, err := googleapi.WithoutDataWrapper.JSONReader(c.appdetails)
10181 if err != nil {
10182 return nil, err
10183 }
10184 c.urlParams_.Set("alt", alt)
10185 c.urlParams_.Set("prettyPrint", "false")
10186 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details")
10187 urls += "?" + c.urlParams_.Encode()
10188 req, err := http.NewRequest("PATCH", urls, body)
10189 if err != nil {
10190 return nil, err
10191 }
10192 req.Header = reqHeaders
10193 googleapi.Expand(req.URL, map[string]string{
10194 "packageName": c.packageName,
10195 "editId": c.editId,
10196 })
10197 return gensupport.SendRequest(c.ctx_, c.s.client, req)
10198 }
10199
10200
10201
10202
10203
10204
10205 func (c *EditsDetailsPatchCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) {
10206 gensupport.SetOptions(c.urlParams_, opts...)
10207 res, err := c.doRequest("json")
10208 if res != nil && res.StatusCode == http.StatusNotModified {
10209 if res.Body != nil {
10210 res.Body.Close()
10211 }
10212 return nil, gensupport.WrapError(&googleapi.Error{
10213 Code: res.StatusCode,
10214 Header: res.Header,
10215 })
10216 }
10217 if err != nil {
10218 return nil, err
10219 }
10220 defer googleapi.CloseBody(res)
10221 if err := googleapi.CheckResponse(res); err != nil {
10222 return nil, gensupport.WrapError(err)
10223 }
10224 ret := &AppDetails{
10225 ServerResponse: googleapi.ServerResponse{
10226 Header: res.Header,
10227 HTTPStatusCode: res.StatusCode,
10228 },
10229 }
10230 target := &ret
10231 if err := gensupport.DecodeResponse(target, res); err != nil {
10232 return nil, err
10233 }
10234 return ret, nil
10235 }
10236
10237 type EditsDetailsUpdateCall struct {
10238 s *Service
10239 packageName string
10240 editId string
10241 appdetails *AppDetails
10242 urlParams_ gensupport.URLParams
10243 ctx_ context.Context
10244 header_ http.Header
10245 }
10246
10247
10248
10249
10250
10251 func (r *EditsDetailsService) Update(packageName string, editId string, appdetails *AppDetails) *EditsDetailsUpdateCall {
10252 c := &EditsDetailsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10253 c.packageName = packageName
10254 c.editId = editId
10255 c.appdetails = appdetails
10256 return c
10257 }
10258
10259
10260
10261
10262 func (c *EditsDetailsUpdateCall) Fields(s ...googleapi.Field) *EditsDetailsUpdateCall {
10263 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10264 return c
10265 }
10266
10267
10268 func (c *EditsDetailsUpdateCall) Context(ctx context.Context) *EditsDetailsUpdateCall {
10269 c.ctx_ = ctx
10270 return c
10271 }
10272
10273
10274
10275 func (c *EditsDetailsUpdateCall) Header() http.Header {
10276 if c.header_ == nil {
10277 c.header_ = make(http.Header)
10278 }
10279 return c.header_
10280 }
10281
10282 func (c *EditsDetailsUpdateCall) doRequest(alt string) (*http.Response, error) {
10283 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
10284 var body io.Reader = nil
10285 body, err := googleapi.WithoutDataWrapper.JSONReader(c.appdetails)
10286 if err != nil {
10287 return nil, err
10288 }
10289 c.urlParams_.Set("alt", alt)
10290 c.urlParams_.Set("prettyPrint", "false")
10291 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details")
10292 urls += "?" + c.urlParams_.Encode()
10293 req, err := http.NewRequest("PUT", urls, body)
10294 if err != nil {
10295 return nil, err
10296 }
10297 req.Header = reqHeaders
10298 googleapi.Expand(req.URL, map[string]string{
10299 "packageName": c.packageName,
10300 "editId": c.editId,
10301 })
10302 return gensupport.SendRequest(c.ctx_, c.s.client, req)
10303 }
10304
10305
10306
10307
10308
10309
10310 func (c *EditsDetailsUpdateCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) {
10311 gensupport.SetOptions(c.urlParams_, opts...)
10312 res, err := c.doRequest("json")
10313 if res != nil && res.StatusCode == http.StatusNotModified {
10314 if res.Body != nil {
10315 res.Body.Close()
10316 }
10317 return nil, gensupport.WrapError(&googleapi.Error{
10318 Code: res.StatusCode,
10319 Header: res.Header,
10320 })
10321 }
10322 if err != nil {
10323 return nil, err
10324 }
10325 defer googleapi.CloseBody(res)
10326 if err := googleapi.CheckResponse(res); err != nil {
10327 return nil, gensupport.WrapError(err)
10328 }
10329 ret := &AppDetails{
10330 ServerResponse: googleapi.ServerResponse{
10331 Header: res.Header,
10332 HTTPStatusCode: res.StatusCode,
10333 },
10334 }
10335 target := &ret
10336 if err := gensupport.DecodeResponse(target, res); err != nil {
10337 return nil, err
10338 }
10339 return ret, nil
10340 }
10341
10342 type EditsExpansionfilesGetCall struct {
10343 s *Service
10344 packageName string
10345 editId string
10346 apkVersionCode int64
10347 expansionFileType string
10348 urlParams_ gensupport.URLParams
10349 ifNoneMatch_ string
10350 ctx_ context.Context
10351 header_ http.Header
10352 }
10353
10354
10355
10356
10357
10358
10359
10360
10361
10362 func (r *EditsExpansionfilesService) Get(packageName string, editId string, apkVersionCode int64, expansionFileType string) *EditsExpansionfilesGetCall {
10363 c := &EditsExpansionfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10364 c.packageName = packageName
10365 c.editId = editId
10366 c.apkVersionCode = apkVersionCode
10367 c.expansionFileType = expansionFileType
10368 return c
10369 }
10370
10371
10372
10373
10374 func (c *EditsExpansionfilesGetCall) Fields(s ...googleapi.Field) *EditsExpansionfilesGetCall {
10375 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10376 return c
10377 }
10378
10379
10380
10381
10382 func (c *EditsExpansionfilesGetCall) IfNoneMatch(entityTag string) *EditsExpansionfilesGetCall {
10383 c.ifNoneMatch_ = entityTag
10384 return c
10385 }
10386
10387
10388 func (c *EditsExpansionfilesGetCall) Context(ctx context.Context) *EditsExpansionfilesGetCall {
10389 c.ctx_ = ctx
10390 return c
10391 }
10392
10393
10394
10395 func (c *EditsExpansionfilesGetCall) Header() http.Header {
10396 if c.header_ == nil {
10397 c.header_ = make(http.Header)
10398 }
10399 return c.header_
10400 }
10401
10402 func (c *EditsExpansionfilesGetCall) doRequest(alt string) (*http.Response, error) {
10403 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
10404 if c.ifNoneMatch_ != "" {
10405 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
10406 }
10407 var body io.Reader = nil
10408 c.urlParams_.Set("alt", alt)
10409 c.urlParams_.Set("prettyPrint", "false")
10410 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}")
10411 urls += "?" + c.urlParams_.Encode()
10412 req, err := http.NewRequest("GET", urls, body)
10413 if err != nil {
10414 return nil, err
10415 }
10416 req.Header = reqHeaders
10417 googleapi.Expand(req.URL, map[string]string{
10418 "packageName": c.packageName,
10419 "editId": c.editId,
10420 "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10),
10421 "expansionFileType": c.expansionFileType,
10422 })
10423 return gensupport.SendRequest(c.ctx_, c.s.client, req)
10424 }
10425
10426
10427
10428
10429
10430
10431 func (c *EditsExpansionfilesGetCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, error) {
10432 gensupport.SetOptions(c.urlParams_, opts...)
10433 res, err := c.doRequest("json")
10434 if res != nil && res.StatusCode == http.StatusNotModified {
10435 if res.Body != nil {
10436 res.Body.Close()
10437 }
10438 return nil, gensupport.WrapError(&googleapi.Error{
10439 Code: res.StatusCode,
10440 Header: res.Header,
10441 })
10442 }
10443 if err != nil {
10444 return nil, err
10445 }
10446 defer googleapi.CloseBody(res)
10447 if err := googleapi.CheckResponse(res); err != nil {
10448 return nil, gensupport.WrapError(err)
10449 }
10450 ret := &ExpansionFile{
10451 ServerResponse: googleapi.ServerResponse{
10452 Header: res.Header,
10453 HTTPStatusCode: res.StatusCode,
10454 },
10455 }
10456 target := &ret
10457 if err := gensupport.DecodeResponse(target, res); err != nil {
10458 return nil, err
10459 }
10460 return ret, nil
10461 }
10462
10463 type EditsExpansionfilesPatchCall struct {
10464 s *Service
10465 packageName string
10466 editId string
10467 apkVersionCode int64
10468 expansionFileType string
10469 expansionfile *ExpansionFile
10470 urlParams_ gensupport.URLParams
10471 ctx_ context.Context
10472 header_ http.Header
10473 }
10474
10475
10476
10477
10478
10479
10480
10481
10482
10483
10484 func (r *EditsExpansionfilesService) Patch(packageName string, editId string, apkVersionCode int64, expansionFileType string, expansionfile *ExpansionFile) *EditsExpansionfilesPatchCall {
10485 c := &EditsExpansionfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10486 c.packageName = packageName
10487 c.editId = editId
10488 c.apkVersionCode = apkVersionCode
10489 c.expansionFileType = expansionFileType
10490 c.expansionfile = expansionfile
10491 return c
10492 }
10493
10494
10495
10496
10497 func (c *EditsExpansionfilesPatchCall) Fields(s ...googleapi.Field) *EditsExpansionfilesPatchCall {
10498 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10499 return c
10500 }
10501
10502
10503 func (c *EditsExpansionfilesPatchCall) Context(ctx context.Context) *EditsExpansionfilesPatchCall {
10504 c.ctx_ = ctx
10505 return c
10506 }
10507
10508
10509
10510 func (c *EditsExpansionfilesPatchCall) Header() http.Header {
10511 if c.header_ == nil {
10512 c.header_ = make(http.Header)
10513 }
10514 return c.header_
10515 }
10516
10517 func (c *EditsExpansionfilesPatchCall) doRequest(alt string) (*http.Response, error) {
10518 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
10519 var body io.Reader = nil
10520 body, err := googleapi.WithoutDataWrapper.JSONReader(c.expansionfile)
10521 if err != nil {
10522 return nil, err
10523 }
10524 c.urlParams_.Set("alt", alt)
10525 c.urlParams_.Set("prettyPrint", "false")
10526 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}")
10527 urls += "?" + c.urlParams_.Encode()
10528 req, err := http.NewRequest("PATCH", urls, body)
10529 if err != nil {
10530 return nil, err
10531 }
10532 req.Header = reqHeaders
10533 googleapi.Expand(req.URL, map[string]string{
10534 "packageName": c.packageName,
10535 "editId": c.editId,
10536 "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10),
10537 "expansionFileType": c.expansionFileType,
10538 })
10539 return gensupport.SendRequest(c.ctx_, c.s.client, req)
10540 }
10541
10542
10543
10544
10545
10546
10547 func (c *EditsExpansionfilesPatchCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, error) {
10548 gensupport.SetOptions(c.urlParams_, opts...)
10549 res, err := c.doRequest("json")
10550 if res != nil && res.StatusCode == http.StatusNotModified {
10551 if res.Body != nil {
10552 res.Body.Close()
10553 }
10554 return nil, gensupport.WrapError(&googleapi.Error{
10555 Code: res.StatusCode,
10556 Header: res.Header,
10557 })
10558 }
10559 if err != nil {
10560 return nil, err
10561 }
10562 defer googleapi.CloseBody(res)
10563 if err := googleapi.CheckResponse(res); err != nil {
10564 return nil, gensupport.WrapError(err)
10565 }
10566 ret := &ExpansionFile{
10567 ServerResponse: googleapi.ServerResponse{
10568 Header: res.Header,
10569 HTTPStatusCode: res.StatusCode,
10570 },
10571 }
10572 target := &ret
10573 if err := gensupport.DecodeResponse(target, res); err != nil {
10574 return nil, err
10575 }
10576 return ret, nil
10577 }
10578
10579 type EditsExpansionfilesUpdateCall struct {
10580 s *Service
10581 packageName string
10582 editId string
10583 apkVersionCode int64
10584 expansionFileType string
10585 expansionfile *ExpansionFile
10586 urlParams_ gensupport.URLParams
10587 ctx_ context.Context
10588 header_ http.Header
10589 }
10590
10591
10592
10593
10594
10595
10596
10597
10598
10599
10600 func (r *EditsExpansionfilesService) Update(packageName string, editId string, apkVersionCode int64, expansionFileType string, expansionfile *ExpansionFile) *EditsExpansionfilesUpdateCall {
10601 c := &EditsExpansionfilesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10602 c.packageName = packageName
10603 c.editId = editId
10604 c.apkVersionCode = apkVersionCode
10605 c.expansionFileType = expansionFileType
10606 c.expansionfile = expansionfile
10607 return c
10608 }
10609
10610
10611
10612
10613 func (c *EditsExpansionfilesUpdateCall) Fields(s ...googleapi.Field) *EditsExpansionfilesUpdateCall {
10614 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10615 return c
10616 }
10617
10618
10619 func (c *EditsExpansionfilesUpdateCall) Context(ctx context.Context) *EditsExpansionfilesUpdateCall {
10620 c.ctx_ = ctx
10621 return c
10622 }
10623
10624
10625
10626 func (c *EditsExpansionfilesUpdateCall) Header() http.Header {
10627 if c.header_ == nil {
10628 c.header_ = make(http.Header)
10629 }
10630 return c.header_
10631 }
10632
10633 func (c *EditsExpansionfilesUpdateCall) doRequest(alt string) (*http.Response, error) {
10634 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
10635 var body io.Reader = nil
10636 body, err := googleapi.WithoutDataWrapper.JSONReader(c.expansionfile)
10637 if err != nil {
10638 return nil, err
10639 }
10640 c.urlParams_.Set("alt", alt)
10641 c.urlParams_.Set("prettyPrint", "false")
10642 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}")
10643 urls += "?" + c.urlParams_.Encode()
10644 req, err := http.NewRequest("PUT", urls, body)
10645 if err != nil {
10646 return nil, err
10647 }
10648 req.Header = reqHeaders
10649 googleapi.Expand(req.URL, map[string]string{
10650 "packageName": c.packageName,
10651 "editId": c.editId,
10652 "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10),
10653 "expansionFileType": c.expansionFileType,
10654 })
10655 return gensupport.SendRequest(c.ctx_, c.s.client, req)
10656 }
10657
10658
10659
10660
10661
10662
10663 func (c *EditsExpansionfilesUpdateCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, error) {
10664 gensupport.SetOptions(c.urlParams_, opts...)
10665 res, err := c.doRequest("json")
10666 if res != nil && res.StatusCode == http.StatusNotModified {
10667 if res.Body != nil {
10668 res.Body.Close()
10669 }
10670 return nil, gensupport.WrapError(&googleapi.Error{
10671 Code: res.StatusCode,
10672 Header: res.Header,
10673 })
10674 }
10675 if err != nil {
10676 return nil, err
10677 }
10678 defer googleapi.CloseBody(res)
10679 if err := googleapi.CheckResponse(res); err != nil {
10680 return nil, gensupport.WrapError(err)
10681 }
10682 ret := &ExpansionFile{
10683 ServerResponse: googleapi.ServerResponse{
10684 Header: res.Header,
10685 HTTPStatusCode: res.StatusCode,
10686 },
10687 }
10688 target := &ret
10689 if err := gensupport.DecodeResponse(target, res); err != nil {
10690 return nil, err
10691 }
10692 return ret, nil
10693 }
10694
10695 type EditsExpansionfilesUploadCall struct {
10696 s *Service
10697 packageName string
10698 editId string
10699 apkVersionCode int64
10700 expansionFileType string
10701 urlParams_ gensupport.URLParams
10702 mediaInfo_ *gensupport.MediaInfo
10703 ctx_ context.Context
10704 header_ http.Header
10705 }
10706
10707
10708
10709
10710
10711
10712
10713
10714
10715 func (r *EditsExpansionfilesService) Upload(packageName string, editId string, apkVersionCode int64, expansionFileType string) *EditsExpansionfilesUploadCall {
10716 c := &EditsExpansionfilesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10717 c.packageName = packageName
10718 c.editId = editId
10719 c.apkVersionCode = apkVersionCode
10720 c.expansionFileType = expansionFileType
10721 return c
10722 }
10723
10724
10725
10726
10727
10728
10729
10730
10731 func (c *EditsExpansionfilesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsExpansionfilesUploadCall {
10732 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
10733 return c
10734 }
10735
10736
10737
10738
10739
10740
10741
10742
10743
10744
10745 func (c *EditsExpansionfilesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsExpansionfilesUploadCall {
10746 c.ctx_ = ctx
10747 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
10748 return c
10749 }
10750
10751
10752
10753
10754
10755 func (c *EditsExpansionfilesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsExpansionfilesUploadCall {
10756 c.mediaInfo_.SetProgressUpdater(pu)
10757 return c
10758 }
10759
10760
10761
10762
10763 func (c *EditsExpansionfilesUploadCall) Fields(s ...googleapi.Field) *EditsExpansionfilesUploadCall {
10764 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10765 return c
10766 }
10767
10768
10769
10770
10771 func (c *EditsExpansionfilesUploadCall) Context(ctx context.Context) *EditsExpansionfilesUploadCall {
10772 c.ctx_ = ctx
10773 return c
10774 }
10775
10776
10777
10778 func (c *EditsExpansionfilesUploadCall) Header() http.Header {
10779 if c.header_ == nil {
10780 c.header_ = make(http.Header)
10781 }
10782 return c.header_
10783 }
10784
10785 func (c *EditsExpansionfilesUploadCall) doRequest(alt string) (*http.Response, error) {
10786 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
10787 var body io.Reader = nil
10788 c.urlParams_.Set("alt", alt)
10789 c.urlParams_.Set("prettyPrint", "false")
10790 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}")
10791 if c.mediaInfo_ != nil {
10792 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}")
10793 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
10794 }
10795 if body == nil {
10796 body = new(bytes.Buffer)
10797 reqHeaders.Set("Content-Type", "application/json")
10798 }
10799 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
10800 defer cleanup()
10801 urls += "?" + c.urlParams_.Encode()
10802 req, err := http.NewRequest("POST", urls, body)
10803 if err != nil {
10804 return nil, err
10805 }
10806 req.Header = reqHeaders
10807 req.GetBody = getBody
10808 googleapi.Expand(req.URL, map[string]string{
10809 "packageName": c.packageName,
10810 "editId": c.editId,
10811 "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10),
10812 "expansionFileType": c.expansionFileType,
10813 })
10814 return gensupport.SendRequest(c.ctx_, c.s.client, req)
10815 }
10816
10817
10818
10819
10820
10821
10822
10823 func (c *EditsExpansionfilesUploadCall) Do(opts ...googleapi.CallOption) (*ExpansionFilesUploadResponse, error) {
10824 gensupport.SetOptions(c.urlParams_, opts...)
10825 res, err := c.doRequest("json")
10826 if res != nil && res.StatusCode == http.StatusNotModified {
10827 if res.Body != nil {
10828 res.Body.Close()
10829 }
10830 return nil, gensupport.WrapError(&googleapi.Error{
10831 Code: res.StatusCode,
10832 Header: res.Header,
10833 })
10834 }
10835 if err != nil {
10836 return nil, err
10837 }
10838 defer googleapi.CloseBody(res)
10839 if err := googleapi.CheckResponse(res); err != nil {
10840 return nil, gensupport.WrapError(err)
10841 }
10842 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
10843 if rx != nil {
10844 rx.Client = c.s.client
10845 rx.UserAgent = c.s.userAgent()
10846 ctx := c.ctx_
10847 if ctx == nil {
10848 ctx = context.TODO()
10849 }
10850 res, err = rx.Upload(ctx)
10851 if err != nil {
10852 return nil, err
10853 }
10854 defer res.Body.Close()
10855 if err := googleapi.CheckResponse(res); err != nil {
10856 return nil, gensupport.WrapError(err)
10857 }
10858 }
10859 ret := &ExpansionFilesUploadResponse{
10860 ServerResponse: googleapi.ServerResponse{
10861 Header: res.Header,
10862 HTTPStatusCode: res.StatusCode,
10863 },
10864 }
10865 target := &ret
10866 if err := gensupport.DecodeResponse(target, res); err != nil {
10867 return nil, err
10868 }
10869 return ret, nil
10870 }
10871
10872 type EditsImagesDeleteCall struct {
10873 s *Service
10874 packageName string
10875 editId string
10876 language string
10877 imageType string
10878 imageId string
10879 urlParams_ gensupport.URLParams
10880 ctx_ context.Context
10881 header_ http.Header
10882 }
10883
10884
10885
10886
10887
10888
10889
10890
10891
10892
10893 func (r *EditsImagesService) Delete(packageName string, editId string, language string, imageType string, imageId string) *EditsImagesDeleteCall {
10894 c := &EditsImagesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10895 c.packageName = packageName
10896 c.editId = editId
10897 c.language = language
10898 c.imageType = imageType
10899 c.imageId = imageId
10900 return c
10901 }
10902
10903
10904
10905
10906 func (c *EditsImagesDeleteCall) Fields(s ...googleapi.Field) *EditsImagesDeleteCall {
10907 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10908 return c
10909 }
10910
10911
10912 func (c *EditsImagesDeleteCall) Context(ctx context.Context) *EditsImagesDeleteCall {
10913 c.ctx_ = ctx
10914 return c
10915 }
10916
10917
10918
10919 func (c *EditsImagesDeleteCall) Header() http.Header {
10920 if c.header_ == nil {
10921 c.header_ = make(http.Header)
10922 }
10923 return c.header_
10924 }
10925
10926 func (c *EditsImagesDeleteCall) doRequest(alt string) (*http.Response, error) {
10927 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
10928 var body io.Reader = nil
10929 c.urlParams_.Set("alt", alt)
10930 c.urlParams_.Set("prettyPrint", "false")
10931 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}/{imageId}")
10932 urls += "?" + c.urlParams_.Encode()
10933 req, err := http.NewRequest("DELETE", urls, body)
10934 if err != nil {
10935 return nil, err
10936 }
10937 req.Header = reqHeaders
10938 googleapi.Expand(req.URL, map[string]string{
10939 "packageName": c.packageName,
10940 "editId": c.editId,
10941 "language": c.language,
10942 "imageType": c.imageType,
10943 "imageId": c.imageId,
10944 })
10945 return gensupport.SendRequest(c.ctx_, c.s.client, req)
10946 }
10947
10948
10949 func (c *EditsImagesDeleteCall) Do(opts ...googleapi.CallOption) error {
10950 gensupport.SetOptions(c.urlParams_, opts...)
10951 res, err := c.doRequest("json")
10952 if err != nil {
10953 return err
10954 }
10955 defer googleapi.CloseBody(res)
10956 if err := googleapi.CheckResponse(res); err != nil {
10957 return gensupport.WrapError(err)
10958 }
10959 return nil
10960 }
10961
10962 type EditsImagesDeleteallCall struct {
10963 s *Service
10964 packageName string
10965 editId string
10966 language string
10967 imageType string
10968 urlParams_ gensupport.URLParams
10969 ctx_ context.Context
10970 header_ http.Header
10971 }
10972
10973
10974
10975
10976
10977
10978
10979
10980
10981
10982
10983 func (r *EditsImagesService) Deleteall(packageName string, editId string, language string, imageType string) *EditsImagesDeleteallCall {
10984 c := &EditsImagesDeleteallCall{s: r.s, urlParams_: make(gensupport.URLParams)}
10985 c.packageName = packageName
10986 c.editId = editId
10987 c.language = language
10988 c.imageType = imageType
10989 return c
10990 }
10991
10992
10993
10994
10995 func (c *EditsImagesDeleteallCall) Fields(s ...googleapi.Field) *EditsImagesDeleteallCall {
10996 c.urlParams_.Set("fields", googleapi.CombineFields(s))
10997 return c
10998 }
10999
11000
11001 func (c *EditsImagesDeleteallCall) Context(ctx context.Context) *EditsImagesDeleteallCall {
11002 c.ctx_ = ctx
11003 return c
11004 }
11005
11006
11007
11008 func (c *EditsImagesDeleteallCall) Header() http.Header {
11009 if c.header_ == nil {
11010 c.header_ = make(http.Header)
11011 }
11012 return c.header_
11013 }
11014
11015 func (c *EditsImagesDeleteallCall) doRequest(alt string) (*http.Response, error) {
11016 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
11017 var body io.Reader = nil
11018 c.urlParams_.Set("alt", alt)
11019 c.urlParams_.Set("prettyPrint", "false")
11020 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}")
11021 urls += "?" + c.urlParams_.Encode()
11022 req, err := http.NewRequest("DELETE", urls, body)
11023 if err != nil {
11024 return nil, err
11025 }
11026 req.Header = reqHeaders
11027 googleapi.Expand(req.URL, map[string]string{
11028 "packageName": c.packageName,
11029 "editId": c.editId,
11030 "language": c.language,
11031 "imageType": c.imageType,
11032 })
11033 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11034 }
11035
11036
11037
11038
11039
11040
11041
11042 func (c *EditsImagesDeleteallCall) Do(opts ...googleapi.CallOption) (*ImagesDeleteAllResponse, error) {
11043 gensupport.SetOptions(c.urlParams_, opts...)
11044 res, err := c.doRequest("json")
11045 if res != nil && res.StatusCode == http.StatusNotModified {
11046 if res.Body != nil {
11047 res.Body.Close()
11048 }
11049 return nil, gensupport.WrapError(&googleapi.Error{
11050 Code: res.StatusCode,
11051 Header: res.Header,
11052 })
11053 }
11054 if err != nil {
11055 return nil, err
11056 }
11057 defer googleapi.CloseBody(res)
11058 if err := googleapi.CheckResponse(res); err != nil {
11059 return nil, gensupport.WrapError(err)
11060 }
11061 ret := &ImagesDeleteAllResponse{
11062 ServerResponse: googleapi.ServerResponse{
11063 Header: res.Header,
11064 HTTPStatusCode: res.StatusCode,
11065 },
11066 }
11067 target := &ret
11068 if err := gensupport.DecodeResponse(target, res); err != nil {
11069 return nil, err
11070 }
11071 return ret, nil
11072 }
11073
11074 type EditsImagesListCall struct {
11075 s *Service
11076 packageName string
11077 editId string
11078 language string
11079 imageType string
11080 urlParams_ gensupport.URLParams
11081 ifNoneMatch_ string
11082 ctx_ context.Context
11083 header_ http.Header
11084 }
11085
11086
11087
11088
11089
11090
11091
11092
11093
11094
11095 func (r *EditsImagesService) List(packageName string, editId string, language string, imageType string) *EditsImagesListCall {
11096 c := &EditsImagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11097 c.packageName = packageName
11098 c.editId = editId
11099 c.language = language
11100 c.imageType = imageType
11101 return c
11102 }
11103
11104
11105
11106
11107 func (c *EditsImagesListCall) Fields(s ...googleapi.Field) *EditsImagesListCall {
11108 c.urlParams_.Set("fields", googleapi.CombineFields(s))
11109 return c
11110 }
11111
11112
11113
11114
11115 func (c *EditsImagesListCall) IfNoneMatch(entityTag string) *EditsImagesListCall {
11116 c.ifNoneMatch_ = entityTag
11117 return c
11118 }
11119
11120
11121 func (c *EditsImagesListCall) Context(ctx context.Context) *EditsImagesListCall {
11122 c.ctx_ = ctx
11123 return c
11124 }
11125
11126
11127
11128 func (c *EditsImagesListCall) Header() http.Header {
11129 if c.header_ == nil {
11130 c.header_ = make(http.Header)
11131 }
11132 return c.header_
11133 }
11134
11135 func (c *EditsImagesListCall) doRequest(alt string) (*http.Response, error) {
11136 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
11137 if c.ifNoneMatch_ != "" {
11138 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
11139 }
11140 var body io.Reader = nil
11141 c.urlParams_.Set("alt", alt)
11142 c.urlParams_.Set("prettyPrint", "false")
11143 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}")
11144 urls += "?" + c.urlParams_.Encode()
11145 req, err := http.NewRequest("GET", urls, body)
11146 if err != nil {
11147 return nil, err
11148 }
11149 req.Header = reqHeaders
11150 googleapi.Expand(req.URL, map[string]string{
11151 "packageName": c.packageName,
11152 "editId": c.editId,
11153 "language": c.language,
11154 "imageType": c.imageType,
11155 })
11156 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11157 }
11158
11159
11160
11161
11162
11163
11164
11165 func (c *EditsImagesListCall) Do(opts ...googleapi.CallOption) (*ImagesListResponse, error) {
11166 gensupport.SetOptions(c.urlParams_, opts...)
11167 res, err := c.doRequest("json")
11168 if res != nil && res.StatusCode == http.StatusNotModified {
11169 if res.Body != nil {
11170 res.Body.Close()
11171 }
11172 return nil, gensupport.WrapError(&googleapi.Error{
11173 Code: res.StatusCode,
11174 Header: res.Header,
11175 })
11176 }
11177 if err != nil {
11178 return nil, err
11179 }
11180 defer googleapi.CloseBody(res)
11181 if err := googleapi.CheckResponse(res); err != nil {
11182 return nil, gensupport.WrapError(err)
11183 }
11184 ret := &ImagesListResponse{
11185 ServerResponse: googleapi.ServerResponse{
11186 Header: res.Header,
11187 HTTPStatusCode: res.StatusCode,
11188 },
11189 }
11190 target := &ret
11191 if err := gensupport.DecodeResponse(target, res); err != nil {
11192 return nil, err
11193 }
11194 return ret, nil
11195 }
11196
11197 type EditsImagesUploadCall struct {
11198 s *Service
11199 packageName string
11200 editId string
11201 language string
11202 imageType string
11203 urlParams_ gensupport.URLParams
11204 mediaInfo_ *gensupport.MediaInfo
11205 ctx_ context.Context
11206 header_ http.Header
11207 }
11208
11209
11210
11211
11212
11213
11214
11215
11216
11217
11218 func (r *EditsImagesService) Upload(packageName string, editId string, language string, imageType string) *EditsImagesUploadCall {
11219 c := &EditsImagesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11220 c.packageName = packageName
11221 c.editId = editId
11222 c.language = language
11223 c.imageType = imageType
11224 return c
11225 }
11226
11227
11228
11229
11230
11231
11232
11233
11234 func (c *EditsImagesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsImagesUploadCall {
11235 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
11236 return c
11237 }
11238
11239
11240
11241
11242
11243
11244
11245
11246
11247
11248 func (c *EditsImagesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsImagesUploadCall {
11249 c.ctx_ = ctx
11250 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
11251 return c
11252 }
11253
11254
11255
11256
11257
11258 func (c *EditsImagesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsImagesUploadCall {
11259 c.mediaInfo_.SetProgressUpdater(pu)
11260 return c
11261 }
11262
11263
11264
11265
11266 func (c *EditsImagesUploadCall) Fields(s ...googleapi.Field) *EditsImagesUploadCall {
11267 c.urlParams_.Set("fields", googleapi.CombineFields(s))
11268 return c
11269 }
11270
11271
11272
11273
11274 func (c *EditsImagesUploadCall) Context(ctx context.Context) *EditsImagesUploadCall {
11275 c.ctx_ = ctx
11276 return c
11277 }
11278
11279
11280
11281 func (c *EditsImagesUploadCall) Header() http.Header {
11282 if c.header_ == nil {
11283 c.header_ = make(http.Header)
11284 }
11285 return c.header_
11286 }
11287
11288 func (c *EditsImagesUploadCall) doRequest(alt string) (*http.Response, error) {
11289 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
11290 var body io.Reader = nil
11291 c.urlParams_.Set("alt", alt)
11292 c.urlParams_.Set("prettyPrint", "false")
11293 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}")
11294 if c.mediaInfo_ != nil {
11295 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}")
11296 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
11297 }
11298 if body == nil {
11299 body = new(bytes.Buffer)
11300 reqHeaders.Set("Content-Type", "application/json")
11301 }
11302 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
11303 defer cleanup()
11304 urls += "?" + c.urlParams_.Encode()
11305 req, err := http.NewRequest("POST", urls, body)
11306 if err != nil {
11307 return nil, err
11308 }
11309 req.Header = reqHeaders
11310 req.GetBody = getBody
11311 googleapi.Expand(req.URL, map[string]string{
11312 "packageName": c.packageName,
11313 "editId": c.editId,
11314 "language": c.language,
11315 "imageType": c.imageType,
11316 })
11317 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11318 }
11319
11320
11321
11322
11323
11324
11325
11326 func (c *EditsImagesUploadCall) Do(opts ...googleapi.CallOption) (*ImagesUploadResponse, error) {
11327 gensupport.SetOptions(c.urlParams_, opts...)
11328 res, err := c.doRequest("json")
11329 if res != nil && res.StatusCode == http.StatusNotModified {
11330 if res.Body != nil {
11331 res.Body.Close()
11332 }
11333 return nil, gensupport.WrapError(&googleapi.Error{
11334 Code: res.StatusCode,
11335 Header: res.Header,
11336 })
11337 }
11338 if err != nil {
11339 return nil, err
11340 }
11341 defer googleapi.CloseBody(res)
11342 if err := googleapi.CheckResponse(res); err != nil {
11343 return nil, gensupport.WrapError(err)
11344 }
11345 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
11346 if rx != nil {
11347 rx.Client = c.s.client
11348 rx.UserAgent = c.s.userAgent()
11349 ctx := c.ctx_
11350 if ctx == nil {
11351 ctx = context.TODO()
11352 }
11353 res, err = rx.Upload(ctx)
11354 if err != nil {
11355 return nil, err
11356 }
11357 defer res.Body.Close()
11358 if err := googleapi.CheckResponse(res); err != nil {
11359 return nil, gensupport.WrapError(err)
11360 }
11361 }
11362 ret := &ImagesUploadResponse{
11363 ServerResponse: googleapi.ServerResponse{
11364 Header: res.Header,
11365 HTTPStatusCode: res.StatusCode,
11366 },
11367 }
11368 target := &ret
11369 if err := gensupport.DecodeResponse(target, res); err != nil {
11370 return nil, err
11371 }
11372 return ret, nil
11373 }
11374
11375 type EditsListingsDeleteCall struct {
11376 s *Service
11377 packageName string
11378 editId string
11379 language string
11380 urlParams_ gensupport.URLParams
11381 ctx_ context.Context
11382 header_ http.Header
11383 }
11384
11385
11386
11387
11388
11389
11390
11391 func (r *EditsListingsService) Delete(packageName string, editId string, language string) *EditsListingsDeleteCall {
11392 c := &EditsListingsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11393 c.packageName = packageName
11394 c.editId = editId
11395 c.language = language
11396 return c
11397 }
11398
11399
11400
11401
11402 func (c *EditsListingsDeleteCall) Fields(s ...googleapi.Field) *EditsListingsDeleteCall {
11403 c.urlParams_.Set("fields", googleapi.CombineFields(s))
11404 return c
11405 }
11406
11407
11408 func (c *EditsListingsDeleteCall) Context(ctx context.Context) *EditsListingsDeleteCall {
11409 c.ctx_ = ctx
11410 return c
11411 }
11412
11413
11414
11415 func (c *EditsListingsDeleteCall) Header() http.Header {
11416 if c.header_ == nil {
11417 c.header_ = make(http.Header)
11418 }
11419 return c.header_
11420 }
11421
11422 func (c *EditsListingsDeleteCall) doRequest(alt string) (*http.Response, error) {
11423 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
11424 var body io.Reader = nil
11425 c.urlParams_.Set("alt", alt)
11426 c.urlParams_.Set("prettyPrint", "false")
11427 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}")
11428 urls += "?" + c.urlParams_.Encode()
11429 req, err := http.NewRequest("DELETE", urls, body)
11430 if err != nil {
11431 return nil, err
11432 }
11433 req.Header = reqHeaders
11434 googleapi.Expand(req.URL, map[string]string{
11435 "packageName": c.packageName,
11436 "editId": c.editId,
11437 "language": c.language,
11438 })
11439 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11440 }
11441
11442
11443 func (c *EditsListingsDeleteCall) Do(opts ...googleapi.CallOption) error {
11444 gensupport.SetOptions(c.urlParams_, opts...)
11445 res, err := c.doRequest("json")
11446 if err != nil {
11447 return err
11448 }
11449 defer googleapi.CloseBody(res)
11450 if err := googleapi.CheckResponse(res); err != nil {
11451 return gensupport.WrapError(err)
11452 }
11453 return nil
11454 }
11455
11456 type EditsListingsDeleteallCall struct {
11457 s *Service
11458 packageName string
11459 editId string
11460 urlParams_ gensupport.URLParams
11461 ctx_ context.Context
11462 header_ http.Header
11463 }
11464
11465
11466
11467
11468
11469 func (r *EditsListingsService) Deleteall(packageName string, editId string) *EditsListingsDeleteallCall {
11470 c := &EditsListingsDeleteallCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11471 c.packageName = packageName
11472 c.editId = editId
11473 return c
11474 }
11475
11476
11477
11478
11479 func (c *EditsListingsDeleteallCall) Fields(s ...googleapi.Field) *EditsListingsDeleteallCall {
11480 c.urlParams_.Set("fields", googleapi.CombineFields(s))
11481 return c
11482 }
11483
11484
11485 func (c *EditsListingsDeleteallCall) Context(ctx context.Context) *EditsListingsDeleteallCall {
11486 c.ctx_ = ctx
11487 return c
11488 }
11489
11490
11491
11492 func (c *EditsListingsDeleteallCall) Header() http.Header {
11493 if c.header_ == nil {
11494 c.header_ = make(http.Header)
11495 }
11496 return c.header_
11497 }
11498
11499 func (c *EditsListingsDeleteallCall) doRequest(alt string) (*http.Response, error) {
11500 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
11501 var body io.Reader = nil
11502 c.urlParams_.Set("alt", alt)
11503 c.urlParams_.Set("prettyPrint", "false")
11504 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings")
11505 urls += "?" + c.urlParams_.Encode()
11506 req, err := http.NewRequest("DELETE", urls, body)
11507 if err != nil {
11508 return nil, err
11509 }
11510 req.Header = reqHeaders
11511 googleapi.Expand(req.URL, map[string]string{
11512 "packageName": c.packageName,
11513 "editId": c.editId,
11514 })
11515 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11516 }
11517
11518
11519 func (c *EditsListingsDeleteallCall) Do(opts ...googleapi.CallOption) error {
11520 gensupport.SetOptions(c.urlParams_, opts...)
11521 res, err := c.doRequest("json")
11522 if err != nil {
11523 return err
11524 }
11525 defer googleapi.CloseBody(res)
11526 if err := googleapi.CheckResponse(res); err != nil {
11527 return gensupport.WrapError(err)
11528 }
11529 return nil
11530 }
11531
11532 type EditsListingsGetCall struct {
11533 s *Service
11534 packageName string
11535 editId string
11536 language string
11537 urlParams_ gensupport.URLParams
11538 ifNoneMatch_ string
11539 ctx_ context.Context
11540 header_ http.Header
11541 }
11542
11543
11544
11545
11546
11547
11548
11549 func (r *EditsListingsService) Get(packageName string, editId string, language string) *EditsListingsGetCall {
11550 c := &EditsListingsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11551 c.packageName = packageName
11552 c.editId = editId
11553 c.language = language
11554 return c
11555 }
11556
11557
11558
11559
11560 func (c *EditsListingsGetCall) Fields(s ...googleapi.Field) *EditsListingsGetCall {
11561 c.urlParams_.Set("fields", googleapi.CombineFields(s))
11562 return c
11563 }
11564
11565
11566
11567
11568 func (c *EditsListingsGetCall) IfNoneMatch(entityTag string) *EditsListingsGetCall {
11569 c.ifNoneMatch_ = entityTag
11570 return c
11571 }
11572
11573
11574 func (c *EditsListingsGetCall) Context(ctx context.Context) *EditsListingsGetCall {
11575 c.ctx_ = ctx
11576 return c
11577 }
11578
11579
11580
11581 func (c *EditsListingsGetCall) Header() http.Header {
11582 if c.header_ == nil {
11583 c.header_ = make(http.Header)
11584 }
11585 return c.header_
11586 }
11587
11588 func (c *EditsListingsGetCall) doRequest(alt string) (*http.Response, error) {
11589 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
11590 if c.ifNoneMatch_ != "" {
11591 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
11592 }
11593 var body io.Reader = nil
11594 c.urlParams_.Set("alt", alt)
11595 c.urlParams_.Set("prettyPrint", "false")
11596 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}")
11597 urls += "?" + c.urlParams_.Encode()
11598 req, err := http.NewRequest("GET", urls, body)
11599 if err != nil {
11600 return nil, err
11601 }
11602 req.Header = reqHeaders
11603 googleapi.Expand(req.URL, map[string]string{
11604 "packageName": c.packageName,
11605 "editId": c.editId,
11606 "language": c.language,
11607 })
11608 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11609 }
11610
11611
11612
11613
11614
11615
11616 func (c *EditsListingsGetCall) Do(opts ...googleapi.CallOption) (*Listing, error) {
11617 gensupport.SetOptions(c.urlParams_, opts...)
11618 res, err := c.doRequest("json")
11619 if res != nil && res.StatusCode == http.StatusNotModified {
11620 if res.Body != nil {
11621 res.Body.Close()
11622 }
11623 return nil, gensupport.WrapError(&googleapi.Error{
11624 Code: res.StatusCode,
11625 Header: res.Header,
11626 })
11627 }
11628 if err != nil {
11629 return nil, err
11630 }
11631 defer googleapi.CloseBody(res)
11632 if err := googleapi.CheckResponse(res); err != nil {
11633 return nil, gensupport.WrapError(err)
11634 }
11635 ret := &Listing{
11636 ServerResponse: googleapi.ServerResponse{
11637 Header: res.Header,
11638 HTTPStatusCode: res.StatusCode,
11639 },
11640 }
11641 target := &ret
11642 if err := gensupport.DecodeResponse(target, res); err != nil {
11643 return nil, err
11644 }
11645 return ret, nil
11646 }
11647
11648 type EditsListingsListCall struct {
11649 s *Service
11650 packageName string
11651 editId string
11652 urlParams_ gensupport.URLParams
11653 ifNoneMatch_ string
11654 ctx_ context.Context
11655 header_ http.Header
11656 }
11657
11658
11659
11660
11661
11662 func (r *EditsListingsService) List(packageName string, editId string) *EditsListingsListCall {
11663 c := &EditsListingsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11664 c.packageName = packageName
11665 c.editId = editId
11666 return c
11667 }
11668
11669
11670
11671
11672 func (c *EditsListingsListCall) Fields(s ...googleapi.Field) *EditsListingsListCall {
11673 c.urlParams_.Set("fields", googleapi.CombineFields(s))
11674 return c
11675 }
11676
11677
11678
11679
11680 func (c *EditsListingsListCall) IfNoneMatch(entityTag string) *EditsListingsListCall {
11681 c.ifNoneMatch_ = entityTag
11682 return c
11683 }
11684
11685
11686 func (c *EditsListingsListCall) Context(ctx context.Context) *EditsListingsListCall {
11687 c.ctx_ = ctx
11688 return c
11689 }
11690
11691
11692
11693 func (c *EditsListingsListCall) Header() http.Header {
11694 if c.header_ == nil {
11695 c.header_ = make(http.Header)
11696 }
11697 return c.header_
11698 }
11699
11700 func (c *EditsListingsListCall) doRequest(alt string) (*http.Response, error) {
11701 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
11702 if c.ifNoneMatch_ != "" {
11703 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
11704 }
11705 var body io.Reader = nil
11706 c.urlParams_.Set("alt", alt)
11707 c.urlParams_.Set("prettyPrint", "false")
11708 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings")
11709 urls += "?" + c.urlParams_.Encode()
11710 req, err := http.NewRequest("GET", urls, body)
11711 if err != nil {
11712 return nil, err
11713 }
11714 req.Header = reqHeaders
11715 googleapi.Expand(req.URL, map[string]string{
11716 "packageName": c.packageName,
11717 "editId": c.editId,
11718 })
11719 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11720 }
11721
11722
11723
11724
11725
11726
11727
11728 func (c *EditsListingsListCall) Do(opts ...googleapi.CallOption) (*ListingsListResponse, error) {
11729 gensupport.SetOptions(c.urlParams_, opts...)
11730 res, err := c.doRequest("json")
11731 if res != nil && res.StatusCode == http.StatusNotModified {
11732 if res.Body != nil {
11733 res.Body.Close()
11734 }
11735 return nil, gensupport.WrapError(&googleapi.Error{
11736 Code: res.StatusCode,
11737 Header: res.Header,
11738 })
11739 }
11740 if err != nil {
11741 return nil, err
11742 }
11743 defer googleapi.CloseBody(res)
11744 if err := googleapi.CheckResponse(res); err != nil {
11745 return nil, gensupport.WrapError(err)
11746 }
11747 ret := &ListingsListResponse{
11748 ServerResponse: googleapi.ServerResponse{
11749 Header: res.Header,
11750 HTTPStatusCode: res.StatusCode,
11751 },
11752 }
11753 target := &ret
11754 if err := gensupport.DecodeResponse(target, res); err != nil {
11755 return nil, err
11756 }
11757 return ret, nil
11758 }
11759
11760 type EditsListingsPatchCall struct {
11761 s *Service
11762 packageName string
11763 editId string
11764 language string
11765 listing *Listing
11766 urlParams_ gensupport.URLParams
11767 ctx_ context.Context
11768 header_ http.Header
11769 }
11770
11771
11772
11773
11774
11775
11776
11777 func (r *EditsListingsService) Patch(packageName string, editId string, language string, listing *Listing) *EditsListingsPatchCall {
11778 c := &EditsListingsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11779 c.packageName = packageName
11780 c.editId = editId
11781 c.language = language
11782 c.listing = listing
11783 return c
11784 }
11785
11786
11787
11788
11789 func (c *EditsListingsPatchCall) Fields(s ...googleapi.Field) *EditsListingsPatchCall {
11790 c.urlParams_.Set("fields", googleapi.CombineFields(s))
11791 return c
11792 }
11793
11794
11795 func (c *EditsListingsPatchCall) Context(ctx context.Context) *EditsListingsPatchCall {
11796 c.ctx_ = ctx
11797 return c
11798 }
11799
11800
11801
11802 func (c *EditsListingsPatchCall) Header() http.Header {
11803 if c.header_ == nil {
11804 c.header_ = make(http.Header)
11805 }
11806 return c.header_
11807 }
11808
11809 func (c *EditsListingsPatchCall) doRequest(alt string) (*http.Response, error) {
11810 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
11811 var body io.Reader = nil
11812 body, err := googleapi.WithoutDataWrapper.JSONReader(c.listing)
11813 if err != nil {
11814 return nil, err
11815 }
11816 c.urlParams_.Set("alt", alt)
11817 c.urlParams_.Set("prettyPrint", "false")
11818 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}")
11819 urls += "?" + c.urlParams_.Encode()
11820 req, err := http.NewRequest("PATCH", urls, body)
11821 if err != nil {
11822 return nil, err
11823 }
11824 req.Header = reqHeaders
11825 googleapi.Expand(req.URL, map[string]string{
11826 "packageName": c.packageName,
11827 "editId": c.editId,
11828 "language": c.language,
11829 })
11830 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11831 }
11832
11833
11834
11835
11836
11837
11838 func (c *EditsListingsPatchCall) Do(opts ...googleapi.CallOption) (*Listing, error) {
11839 gensupport.SetOptions(c.urlParams_, opts...)
11840 res, err := c.doRequest("json")
11841 if res != nil && res.StatusCode == http.StatusNotModified {
11842 if res.Body != nil {
11843 res.Body.Close()
11844 }
11845 return nil, gensupport.WrapError(&googleapi.Error{
11846 Code: res.StatusCode,
11847 Header: res.Header,
11848 })
11849 }
11850 if err != nil {
11851 return nil, err
11852 }
11853 defer googleapi.CloseBody(res)
11854 if err := googleapi.CheckResponse(res); err != nil {
11855 return nil, gensupport.WrapError(err)
11856 }
11857 ret := &Listing{
11858 ServerResponse: googleapi.ServerResponse{
11859 Header: res.Header,
11860 HTTPStatusCode: res.StatusCode,
11861 },
11862 }
11863 target := &ret
11864 if err := gensupport.DecodeResponse(target, res); err != nil {
11865 return nil, err
11866 }
11867 return ret, nil
11868 }
11869
11870 type EditsListingsUpdateCall struct {
11871 s *Service
11872 packageName string
11873 editId string
11874 language string
11875 listing *Listing
11876 urlParams_ gensupport.URLParams
11877 ctx_ context.Context
11878 header_ http.Header
11879 }
11880
11881
11882
11883
11884
11885
11886
11887 func (r *EditsListingsService) Update(packageName string, editId string, language string, listing *Listing) *EditsListingsUpdateCall {
11888 c := &EditsListingsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11889 c.packageName = packageName
11890 c.editId = editId
11891 c.language = language
11892 c.listing = listing
11893 return c
11894 }
11895
11896
11897
11898
11899 func (c *EditsListingsUpdateCall) Fields(s ...googleapi.Field) *EditsListingsUpdateCall {
11900 c.urlParams_.Set("fields", googleapi.CombineFields(s))
11901 return c
11902 }
11903
11904
11905 func (c *EditsListingsUpdateCall) Context(ctx context.Context) *EditsListingsUpdateCall {
11906 c.ctx_ = ctx
11907 return c
11908 }
11909
11910
11911
11912 func (c *EditsListingsUpdateCall) Header() http.Header {
11913 if c.header_ == nil {
11914 c.header_ = make(http.Header)
11915 }
11916 return c.header_
11917 }
11918
11919 func (c *EditsListingsUpdateCall) doRequest(alt string) (*http.Response, error) {
11920 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
11921 var body io.Reader = nil
11922 body, err := googleapi.WithoutDataWrapper.JSONReader(c.listing)
11923 if err != nil {
11924 return nil, err
11925 }
11926 c.urlParams_.Set("alt", alt)
11927 c.urlParams_.Set("prettyPrint", "false")
11928 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}")
11929 urls += "?" + c.urlParams_.Encode()
11930 req, err := http.NewRequest("PUT", urls, body)
11931 if err != nil {
11932 return nil, err
11933 }
11934 req.Header = reqHeaders
11935 googleapi.Expand(req.URL, map[string]string{
11936 "packageName": c.packageName,
11937 "editId": c.editId,
11938 "language": c.language,
11939 })
11940 return gensupport.SendRequest(c.ctx_, c.s.client, req)
11941 }
11942
11943
11944
11945
11946
11947
11948 func (c *EditsListingsUpdateCall) Do(opts ...googleapi.CallOption) (*Listing, error) {
11949 gensupport.SetOptions(c.urlParams_, opts...)
11950 res, err := c.doRequest("json")
11951 if res != nil && res.StatusCode == http.StatusNotModified {
11952 if res.Body != nil {
11953 res.Body.Close()
11954 }
11955 return nil, gensupport.WrapError(&googleapi.Error{
11956 Code: res.StatusCode,
11957 Header: res.Header,
11958 })
11959 }
11960 if err != nil {
11961 return nil, err
11962 }
11963 defer googleapi.CloseBody(res)
11964 if err := googleapi.CheckResponse(res); err != nil {
11965 return nil, gensupport.WrapError(err)
11966 }
11967 ret := &Listing{
11968 ServerResponse: googleapi.ServerResponse{
11969 Header: res.Header,
11970 HTTPStatusCode: res.StatusCode,
11971 },
11972 }
11973 target := &ret
11974 if err := gensupport.DecodeResponse(target, res); err != nil {
11975 return nil, err
11976 }
11977 return ret, nil
11978 }
11979
11980 type EditsTestersGetCall struct {
11981 s *Service
11982 packageName string
11983 editId string
11984 track string
11985 urlParams_ gensupport.URLParams
11986 ifNoneMatch_ string
11987 ctx_ context.Context
11988 header_ http.Header
11989 }
11990
11991
11992
11993
11994
11995
11996 func (r *EditsTestersService) Get(packageName string, editId string, track string) *EditsTestersGetCall {
11997 c := &EditsTestersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
11998 c.packageName = packageName
11999 c.editId = editId
12000 c.track = track
12001 return c
12002 }
12003
12004
12005
12006
12007 func (c *EditsTestersGetCall) Fields(s ...googleapi.Field) *EditsTestersGetCall {
12008 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12009 return c
12010 }
12011
12012
12013
12014
12015 func (c *EditsTestersGetCall) IfNoneMatch(entityTag string) *EditsTestersGetCall {
12016 c.ifNoneMatch_ = entityTag
12017 return c
12018 }
12019
12020
12021 func (c *EditsTestersGetCall) Context(ctx context.Context) *EditsTestersGetCall {
12022 c.ctx_ = ctx
12023 return c
12024 }
12025
12026
12027
12028 func (c *EditsTestersGetCall) Header() http.Header {
12029 if c.header_ == nil {
12030 c.header_ = make(http.Header)
12031 }
12032 return c.header_
12033 }
12034
12035 func (c *EditsTestersGetCall) doRequest(alt string) (*http.Response, error) {
12036 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
12037 if c.ifNoneMatch_ != "" {
12038 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
12039 }
12040 var body io.Reader = nil
12041 c.urlParams_.Set("alt", alt)
12042 c.urlParams_.Set("prettyPrint", "false")
12043 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}")
12044 urls += "?" + c.urlParams_.Encode()
12045 req, err := http.NewRequest("GET", urls, body)
12046 if err != nil {
12047 return nil, err
12048 }
12049 req.Header = reqHeaders
12050 googleapi.Expand(req.URL, map[string]string{
12051 "packageName": c.packageName,
12052 "editId": c.editId,
12053 "track": c.track,
12054 })
12055 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12056 }
12057
12058
12059
12060
12061
12062
12063 func (c *EditsTestersGetCall) Do(opts ...googleapi.CallOption) (*Testers, error) {
12064 gensupport.SetOptions(c.urlParams_, opts...)
12065 res, err := c.doRequest("json")
12066 if res != nil && res.StatusCode == http.StatusNotModified {
12067 if res.Body != nil {
12068 res.Body.Close()
12069 }
12070 return nil, gensupport.WrapError(&googleapi.Error{
12071 Code: res.StatusCode,
12072 Header: res.Header,
12073 })
12074 }
12075 if err != nil {
12076 return nil, err
12077 }
12078 defer googleapi.CloseBody(res)
12079 if err := googleapi.CheckResponse(res); err != nil {
12080 return nil, gensupport.WrapError(err)
12081 }
12082 ret := &Testers{
12083 ServerResponse: googleapi.ServerResponse{
12084 Header: res.Header,
12085 HTTPStatusCode: res.StatusCode,
12086 },
12087 }
12088 target := &ret
12089 if err := gensupport.DecodeResponse(target, res); err != nil {
12090 return nil, err
12091 }
12092 return ret, nil
12093 }
12094
12095 type EditsTestersPatchCall struct {
12096 s *Service
12097 packageName string
12098 editId string
12099 track string
12100 testers *Testers
12101 urlParams_ gensupport.URLParams
12102 ctx_ context.Context
12103 header_ http.Header
12104 }
12105
12106
12107
12108
12109
12110
12111 func (r *EditsTestersService) Patch(packageName string, editId string, track string, testers *Testers) *EditsTestersPatchCall {
12112 c := &EditsTestersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12113 c.packageName = packageName
12114 c.editId = editId
12115 c.track = track
12116 c.testers = testers
12117 return c
12118 }
12119
12120
12121
12122
12123 func (c *EditsTestersPatchCall) Fields(s ...googleapi.Field) *EditsTestersPatchCall {
12124 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12125 return c
12126 }
12127
12128
12129 func (c *EditsTestersPatchCall) Context(ctx context.Context) *EditsTestersPatchCall {
12130 c.ctx_ = ctx
12131 return c
12132 }
12133
12134
12135
12136 func (c *EditsTestersPatchCall) Header() http.Header {
12137 if c.header_ == nil {
12138 c.header_ = make(http.Header)
12139 }
12140 return c.header_
12141 }
12142
12143 func (c *EditsTestersPatchCall) doRequest(alt string) (*http.Response, error) {
12144 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
12145 var body io.Reader = nil
12146 body, err := googleapi.WithoutDataWrapper.JSONReader(c.testers)
12147 if err != nil {
12148 return nil, err
12149 }
12150 c.urlParams_.Set("alt", alt)
12151 c.urlParams_.Set("prettyPrint", "false")
12152 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}")
12153 urls += "?" + c.urlParams_.Encode()
12154 req, err := http.NewRequest("PATCH", urls, body)
12155 if err != nil {
12156 return nil, err
12157 }
12158 req.Header = reqHeaders
12159 googleapi.Expand(req.URL, map[string]string{
12160 "packageName": c.packageName,
12161 "editId": c.editId,
12162 "track": c.track,
12163 })
12164 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12165 }
12166
12167
12168
12169
12170
12171
12172 func (c *EditsTestersPatchCall) Do(opts ...googleapi.CallOption) (*Testers, error) {
12173 gensupport.SetOptions(c.urlParams_, opts...)
12174 res, err := c.doRequest("json")
12175 if res != nil && res.StatusCode == http.StatusNotModified {
12176 if res.Body != nil {
12177 res.Body.Close()
12178 }
12179 return nil, gensupport.WrapError(&googleapi.Error{
12180 Code: res.StatusCode,
12181 Header: res.Header,
12182 })
12183 }
12184 if err != nil {
12185 return nil, err
12186 }
12187 defer googleapi.CloseBody(res)
12188 if err := googleapi.CheckResponse(res); err != nil {
12189 return nil, gensupport.WrapError(err)
12190 }
12191 ret := &Testers{
12192 ServerResponse: googleapi.ServerResponse{
12193 Header: res.Header,
12194 HTTPStatusCode: res.StatusCode,
12195 },
12196 }
12197 target := &ret
12198 if err := gensupport.DecodeResponse(target, res); err != nil {
12199 return nil, err
12200 }
12201 return ret, nil
12202 }
12203
12204 type EditsTestersUpdateCall struct {
12205 s *Service
12206 packageName string
12207 editId string
12208 track string
12209 testers *Testers
12210 urlParams_ gensupport.URLParams
12211 ctx_ context.Context
12212 header_ http.Header
12213 }
12214
12215
12216
12217
12218
12219
12220
12221 func (r *EditsTestersService) Update(packageName string, editId string, track string, testers *Testers) *EditsTestersUpdateCall {
12222 c := &EditsTestersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12223 c.packageName = packageName
12224 c.editId = editId
12225 c.track = track
12226 c.testers = testers
12227 return c
12228 }
12229
12230
12231
12232
12233 func (c *EditsTestersUpdateCall) Fields(s ...googleapi.Field) *EditsTestersUpdateCall {
12234 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12235 return c
12236 }
12237
12238
12239 func (c *EditsTestersUpdateCall) Context(ctx context.Context) *EditsTestersUpdateCall {
12240 c.ctx_ = ctx
12241 return c
12242 }
12243
12244
12245
12246 func (c *EditsTestersUpdateCall) Header() http.Header {
12247 if c.header_ == nil {
12248 c.header_ = make(http.Header)
12249 }
12250 return c.header_
12251 }
12252
12253 func (c *EditsTestersUpdateCall) doRequest(alt string) (*http.Response, error) {
12254 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
12255 var body io.Reader = nil
12256 body, err := googleapi.WithoutDataWrapper.JSONReader(c.testers)
12257 if err != nil {
12258 return nil, err
12259 }
12260 c.urlParams_.Set("alt", alt)
12261 c.urlParams_.Set("prettyPrint", "false")
12262 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}")
12263 urls += "?" + c.urlParams_.Encode()
12264 req, err := http.NewRequest("PUT", urls, body)
12265 if err != nil {
12266 return nil, err
12267 }
12268 req.Header = reqHeaders
12269 googleapi.Expand(req.URL, map[string]string{
12270 "packageName": c.packageName,
12271 "editId": c.editId,
12272 "track": c.track,
12273 })
12274 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12275 }
12276
12277
12278
12279
12280
12281
12282 func (c *EditsTestersUpdateCall) Do(opts ...googleapi.CallOption) (*Testers, error) {
12283 gensupport.SetOptions(c.urlParams_, opts...)
12284 res, err := c.doRequest("json")
12285 if res != nil && res.StatusCode == http.StatusNotModified {
12286 if res.Body != nil {
12287 res.Body.Close()
12288 }
12289 return nil, gensupport.WrapError(&googleapi.Error{
12290 Code: res.StatusCode,
12291 Header: res.Header,
12292 })
12293 }
12294 if err != nil {
12295 return nil, err
12296 }
12297 defer googleapi.CloseBody(res)
12298 if err := googleapi.CheckResponse(res); err != nil {
12299 return nil, gensupport.WrapError(err)
12300 }
12301 ret := &Testers{
12302 ServerResponse: googleapi.ServerResponse{
12303 Header: res.Header,
12304 HTTPStatusCode: res.StatusCode,
12305 },
12306 }
12307 target := &ret
12308 if err := gensupport.DecodeResponse(target, res); err != nil {
12309 return nil, err
12310 }
12311 return ret, nil
12312 }
12313
12314 type EditsTracksCreateCall struct {
12315 s *Service
12316 packageName string
12317 editId string
12318 trackconfig *TrackConfig
12319 urlParams_ gensupport.URLParams
12320 ctx_ context.Context
12321 header_ http.Header
12322 }
12323
12324
12325
12326
12327
12328 func (r *EditsTracksService) Create(packageName string, editId string, trackconfig *TrackConfig) *EditsTracksCreateCall {
12329 c := &EditsTracksCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12330 c.packageName = packageName
12331 c.editId = editId
12332 c.trackconfig = trackconfig
12333 return c
12334 }
12335
12336
12337
12338
12339 func (c *EditsTracksCreateCall) Fields(s ...googleapi.Field) *EditsTracksCreateCall {
12340 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12341 return c
12342 }
12343
12344
12345 func (c *EditsTracksCreateCall) Context(ctx context.Context) *EditsTracksCreateCall {
12346 c.ctx_ = ctx
12347 return c
12348 }
12349
12350
12351
12352 func (c *EditsTracksCreateCall) Header() http.Header {
12353 if c.header_ == nil {
12354 c.header_ = make(http.Header)
12355 }
12356 return c.header_
12357 }
12358
12359 func (c *EditsTracksCreateCall) doRequest(alt string) (*http.Response, error) {
12360 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
12361 var body io.Reader = nil
12362 body, err := googleapi.WithoutDataWrapper.JSONReader(c.trackconfig)
12363 if err != nil {
12364 return nil, err
12365 }
12366 c.urlParams_.Set("alt", alt)
12367 c.urlParams_.Set("prettyPrint", "false")
12368 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks")
12369 urls += "?" + c.urlParams_.Encode()
12370 req, err := http.NewRequest("POST", urls, body)
12371 if err != nil {
12372 return nil, err
12373 }
12374 req.Header = reqHeaders
12375 googleapi.Expand(req.URL, map[string]string{
12376 "packageName": c.packageName,
12377 "editId": c.editId,
12378 })
12379 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12380 }
12381
12382
12383
12384
12385
12386
12387 func (c *EditsTracksCreateCall) Do(opts ...googleapi.CallOption) (*Track, error) {
12388 gensupport.SetOptions(c.urlParams_, opts...)
12389 res, err := c.doRequest("json")
12390 if res != nil && res.StatusCode == http.StatusNotModified {
12391 if res.Body != nil {
12392 res.Body.Close()
12393 }
12394 return nil, gensupport.WrapError(&googleapi.Error{
12395 Code: res.StatusCode,
12396 Header: res.Header,
12397 })
12398 }
12399 if err != nil {
12400 return nil, err
12401 }
12402 defer googleapi.CloseBody(res)
12403 if err := googleapi.CheckResponse(res); err != nil {
12404 return nil, gensupport.WrapError(err)
12405 }
12406 ret := &Track{
12407 ServerResponse: googleapi.ServerResponse{
12408 Header: res.Header,
12409 HTTPStatusCode: res.StatusCode,
12410 },
12411 }
12412 target := &ret
12413 if err := gensupport.DecodeResponse(target, res); err != nil {
12414 return nil, err
12415 }
12416 return ret, nil
12417 }
12418
12419 type EditsTracksGetCall struct {
12420 s *Service
12421 packageName string
12422 editId string
12423 track string
12424 urlParams_ gensupport.URLParams
12425 ifNoneMatch_ string
12426 ctx_ context.Context
12427 header_ http.Header
12428 }
12429
12430
12431
12432
12433
12434
12435
12436 func (r *EditsTracksService) Get(packageName string, editId string, track string) *EditsTracksGetCall {
12437 c := &EditsTracksGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12438 c.packageName = packageName
12439 c.editId = editId
12440 c.track = track
12441 return c
12442 }
12443
12444
12445
12446
12447 func (c *EditsTracksGetCall) Fields(s ...googleapi.Field) *EditsTracksGetCall {
12448 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12449 return c
12450 }
12451
12452
12453
12454
12455 func (c *EditsTracksGetCall) IfNoneMatch(entityTag string) *EditsTracksGetCall {
12456 c.ifNoneMatch_ = entityTag
12457 return c
12458 }
12459
12460
12461 func (c *EditsTracksGetCall) Context(ctx context.Context) *EditsTracksGetCall {
12462 c.ctx_ = ctx
12463 return c
12464 }
12465
12466
12467
12468 func (c *EditsTracksGetCall) Header() http.Header {
12469 if c.header_ == nil {
12470 c.header_ = make(http.Header)
12471 }
12472 return c.header_
12473 }
12474
12475 func (c *EditsTracksGetCall) doRequest(alt string) (*http.Response, error) {
12476 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
12477 if c.ifNoneMatch_ != "" {
12478 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
12479 }
12480 var body io.Reader = nil
12481 c.urlParams_.Set("alt", alt)
12482 c.urlParams_.Set("prettyPrint", "false")
12483 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}")
12484 urls += "?" + c.urlParams_.Encode()
12485 req, err := http.NewRequest("GET", urls, body)
12486 if err != nil {
12487 return nil, err
12488 }
12489 req.Header = reqHeaders
12490 googleapi.Expand(req.URL, map[string]string{
12491 "packageName": c.packageName,
12492 "editId": c.editId,
12493 "track": c.track,
12494 })
12495 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12496 }
12497
12498
12499
12500
12501
12502
12503 func (c *EditsTracksGetCall) Do(opts ...googleapi.CallOption) (*Track, error) {
12504 gensupport.SetOptions(c.urlParams_, opts...)
12505 res, err := c.doRequest("json")
12506 if res != nil && res.StatusCode == http.StatusNotModified {
12507 if res.Body != nil {
12508 res.Body.Close()
12509 }
12510 return nil, gensupport.WrapError(&googleapi.Error{
12511 Code: res.StatusCode,
12512 Header: res.Header,
12513 })
12514 }
12515 if err != nil {
12516 return nil, err
12517 }
12518 defer googleapi.CloseBody(res)
12519 if err := googleapi.CheckResponse(res); err != nil {
12520 return nil, gensupport.WrapError(err)
12521 }
12522 ret := &Track{
12523 ServerResponse: googleapi.ServerResponse{
12524 Header: res.Header,
12525 HTTPStatusCode: res.StatusCode,
12526 },
12527 }
12528 target := &ret
12529 if err := gensupport.DecodeResponse(target, res); err != nil {
12530 return nil, err
12531 }
12532 return ret, nil
12533 }
12534
12535 type EditsTracksListCall struct {
12536 s *Service
12537 packageName string
12538 editId string
12539 urlParams_ gensupport.URLParams
12540 ifNoneMatch_ string
12541 ctx_ context.Context
12542 header_ http.Header
12543 }
12544
12545
12546
12547
12548
12549 func (r *EditsTracksService) List(packageName string, editId string) *EditsTracksListCall {
12550 c := &EditsTracksListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12551 c.packageName = packageName
12552 c.editId = editId
12553 return c
12554 }
12555
12556
12557
12558
12559 func (c *EditsTracksListCall) Fields(s ...googleapi.Field) *EditsTracksListCall {
12560 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12561 return c
12562 }
12563
12564
12565
12566
12567 func (c *EditsTracksListCall) IfNoneMatch(entityTag string) *EditsTracksListCall {
12568 c.ifNoneMatch_ = entityTag
12569 return c
12570 }
12571
12572
12573 func (c *EditsTracksListCall) Context(ctx context.Context) *EditsTracksListCall {
12574 c.ctx_ = ctx
12575 return c
12576 }
12577
12578
12579
12580 func (c *EditsTracksListCall) Header() http.Header {
12581 if c.header_ == nil {
12582 c.header_ = make(http.Header)
12583 }
12584 return c.header_
12585 }
12586
12587 func (c *EditsTracksListCall) doRequest(alt string) (*http.Response, error) {
12588 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
12589 if c.ifNoneMatch_ != "" {
12590 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
12591 }
12592 var body io.Reader = nil
12593 c.urlParams_.Set("alt", alt)
12594 c.urlParams_.Set("prettyPrint", "false")
12595 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks")
12596 urls += "?" + c.urlParams_.Encode()
12597 req, err := http.NewRequest("GET", urls, body)
12598 if err != nil {
12599 return nil, err
12600 }
12601 req.Header = reqHeaders
12602 googleapi.Expand(req.URL, map[string]string{
12603 "packageName": c.packageName,
12604 "editId": c.editId,
12605 })
12606 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12607 }
12608
12609
12610
12611
12612
12613
12614
12615 func (c *EditsTracksListCall) Do(opts ...googleapi.CallOption) (*TracksListResponse, error) {
12616 gensupport.SetOptions(c.urlParams_, opts...)
12617 res, err := c.doRequest("json")
12618 if res != nil && res.StatusCode == http.StatusNotModified {
12619 if res.Body != nil {
12620 res.Body.Close()
12621 }
12622 return nil, gensupport.WrapError(&googleapi.Error{
12623 Code: res.StatusCode,
12624 Header: res.Header,
12625 })
12626 }
12627 if err != nil {
12628 return nil, err
12629 }
12630 defer googleapi.CloseBody(res)
12631 if err := googleapi.CheckResponse(res); err != nil {
12632 return nil, gensupport.WrapError(err)
12633 }
12634 ret := &TracksListResponse{
12635 ServerResponse: googleapi.ServerResponse{
12636 Header: res.Header,
12637 HTTPStatusCode: res.StatusCode,
12638 },
12639 }
12640 target := &ret
12641 if err := gensupport.DecodeResponse(target, res); err != nil {
12642 return nil, err
12643 }
12644 return ret, nil
12645 }
12646
12647 type EditsTracksPatchCall struct {
12648 s *Service
12649 packageName string
12650 editId string
12651 track string
12652 track2 *Track
12653 urlParams_ gensupport.URLParams
12654 ctx_ context.Context
12655 header_ http.Header
12656 }
12657
12658
12659
12660
12661
12662
12663
12664 func (r *EditsTracksService) Patch(packageName string, editId string, track string, track2 *Track) *EditsTracksPatchCall {
12665 c := &EditsTracksPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12666 c.packageName = packageName
12667 c.editId = editId
12668 c.track = track
12669 c.track2 = track2
12670 return c
12671 }
12672
12673
12674
12675
12676 func (c *EditsTracksPatchCall) Fields(s ...googleapi.Field) *EditsTracksPatchCall {
12677 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12678 return c
12679 }
12680
12681
12682 func (c *EditsTracksPatchCall) Context(ctx context.Context) *EditsTracksPatchCall {
12683 c.ctx_ = ctx
12684 return c
12685 }
12686
12687
12688
12689 func (c *EditsTracksPatchCall) Header() http.Header {
12690 if c.header_ == nil {
12691 c.header_ = make(http.Header)
12692 }
12693 return c.header_
12694 }
12695
12696 func (c *EditsTracksPatchCall) doRequest(alt string) (*http.Response, error) {
12697 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
12698 var body io.Reader = nil
12699 body, err := googleapi.WithoutDataWrapper.JSONReader(c.track2)
12700 if err != nil {
12701 return nil, err
12702 }
12703 c.urlParams_.Set("alt", alt)
12704 c.urlParams_.Set("prettyPrint", "false")
12705 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}")
12706 urls += "?" + c.urlParams_.Encode()
12707 req, err := http.NewRequest("PATCH", urls, body)
12708 if err != nil {
12709 return nil, err
12710 }
12711 req.Header = reqHeaders
12712 googleapi.Expand(req.URL, map[string]string{
12713 "packageName": c.packageName,
12714 "editId": c.editId,
12715 "track": c.track,
12716 })
12717 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12718 }
12719
12720
12721
12722
12723
12724
12725 func (c *EditsTracksPatchCall) Do(opts ...googleapi.CallOption) (*Track, error) {
12726 gensupport.SetOptions(c.urlParams_, opts...)
12727 res, err := c.doRequest("json")
12728 if res != nil && res.StatusCode == http.StatusNotModified {
12729 if res.Body != nil {
12730 res.Body.Close()
12731 }
12732 return nil, gensupport.WrapError(&googleapi.Error{
12733 Code: res.StatusCode,
12734 Header: res.Header,
12735 })
12736 }
12737 if err != nil {
12738 return nil, err
12739 }
12740 defer googleapi.CloseBody(res)
12741 if err := googleapi.CheckResponse(res); err != nil {
12742 return nil, gensupport.WrapError(err)
12743 }
12744 ret := &Track{
12745 ServerResponse: googleapi.ServerResponse{
12746 Header: res.Header,
12747 HTTPStatusCode: res.StatusCode,
12748 },
12749 }
12750 target := &ret
12751 if err := gensupport.DecodeResponse(target, res); err != nil {
12752 return nil, err
12753 }
12754 return ret, nil
12755 }
12756
12757 type EditsTracksUpdateCall struct {
12758 s *Service
12759 packageName string
12760 editId string
12761 track string
12762 track2 *Track
12763 urlParams_ gensupport.URLParams
12764 ctx_ context.Context
12765 header_ http.Header
12766 }
12767
12768
12769
12770
12771
12772
12773
12774 func (r *EditsTracksService) Update(packageName string, editId string, track string, track2 *Track) *EditsTracksUpdateCall {
12775 c := &EditsTracksUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12776 c.packageName = packageName
12777 c.editId = editId
12778 c.track = track
12779 c.track2 = track2
12780 return c
12781 }
12782
12783
12784
12785
12786 func (c *EditsTracksUpdateCall) Fields(s ...googleapi.Field) *EditsTracksUpdateCall {
12787 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12788 return c
12789 }
12790
12791
12792 func (c *EditsTracksUpdateCall) Context(ctx context.Context) *EditsTracksUpdateCall {
12793 c.ctx_ = ctx
12794 return c
12795 }
12796
12797
12798
12799 func (c *EditsTracksUpdateCall) Header() http.Header {
12800 if c.header_ == nil {
12801 c.header_ = make(http.Header)
12802 }
12803 return c.header_
12804 }
12805
12806 func (c *EditsTracksUpdateCall) doRequest(alt string) (*http.Response, error) {
12807 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
12808 var body io.Reader = nil
12809 body, err := googleapi.WithoutDataWrapper.JSONReader(c.track2)
12810 if err != nil {
12811 return nil, err
12812 }
12813 c.urlParams_.Set("alt", alt)
12814 c.urlParams_.Set("prettyPrint", "false")
12815 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}")
12816 urls += "?" + c.urlParams_.Encode()
12817 req, err := http.NewRequest("PUT", urls, body)
12818 if err != nil {
12819 return nil, err
12820 }
12821 req.Header = reqHeaders
12822 googleapi.Expand(req.URL, map[string]string{
12823 "packageName": c.packageName,
12824 "editId": c.editId,
12825 "track": c.track,
12826 })
12827 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12828 }
12829
12830
12831
12832
12833
12834
12835 func (c *EditsTracksUpdateCall) Do(opts ...googleapi.CallOption) (*Track, error) {
12836 gensupport.SetOptions(c.urlParams_, opts...)
12837 res, err := c.doRequest("json")
12838 if res != nil && res.StatusCode == http.StatusNotModified {
12839 if res.Body != nil {
12840 res.Body.Close()
12841 }
12842 return nil, gensupport.WrapError(&googleapi.Error{
12843 Code: res.StatusCode,
12844 Header: res.Header,
12845 })
12846 }
12847 if err != nil {
12848 return nil, err
12849 }
12850 defer googleapi.CloseBody(res)
12851 if err := googleapi.CheckResponse(res); err != nil {
12852 return nil, gensupport.WrapError(err)
12853 }
12854 ret := &Track{
12855 ServerResponse: googleapi.ServerResponse{
12856 Header: res.Header,
12857 HTTPStatusCode: res.StatusCode,
12858 },
12859 }
12860 target := &ret
12861 if err := gensupport.DecodeResponse(target, res); err != nil {
12862 return nil, err
12863 }
12864 return ret, nil
12865 }
12866
12867 type ExternaltransactionsCreateexternaltransactionCall struct {
12868 s *Service
12869 parent string
12870 externaltransaction *ExternalTransaction
12871 urlParams_ gensupport.URLParams
12872 ctx_ context.Context
12873 header_ http.Header
12874 }
12875
12876
12877
12878
12879
12880 func (r *ExternaltransactionsService) Createexternaltransaction(parent string, externaltransaction *ExternalTransaction) *ExternaltransactionsCreateexternaltransactionCall {
12881 c := &ExternaltransactionsCreateexternaltransactionCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12882 c.parent = parent
12883 c.externaltransaction = externaltransaction
12884 return c
12885 }
12886
12887
12888
12889
12890
12891
12892
12893 func (c *ExternaltransactionsCreateexternaltransactionCall) ExternalTransactionId(externalTransactionId string) *ExternaltransactionsCreateexternaltransactionCall {
12894 c.urlParams_.Set("externalTransactionId", externalTransactionId)
12895 return c
12896 }
12897
12898
12899
12900
12901 func (c *ExternaltransactionsCreateexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsCreateexternaltransactionCall {
12902 c.urlParams_.Set("fields", googleapi.CombineFields(s))
12903 return c
12904 }
12905
12906
12907 func (c *ExternaltransactionsCreateexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsCreateexternaltransactionCall {
12908 c.ctx_ = ctx
12909 return c
12910 }
12911
12912
12913
12914 func (c *ExternaltransactionsCreateexternaltransactionCall) Header() http.Header {
12915 if c.header_ == nil {
12916 c.header_ = make(http.Header)
12917 }
12918 return c.header_
12919 }
12920
12921 func (c *ExternaltransactionsCreateexternaltransactionCall) doRequest(alt string) (*http.Response, error) {
12922 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
12923 var body io.Reader = nil
12924 body, err := googleapi.WithoutDataWrapper.JSONReader(c.externaltransaction)
12925 if err != nil {
12926 return nil, err
12927 }
12928 c.urlParams_.Set("alt", alt)
12929 c.urlParams_.Set("prettyPrint", "false")
12930 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+parent}/externalTransactions")
12931 urls += "?" + c.urlParams_.Encode()
12932 req, err := http.NewRequest("POST", urls, body)
12933 if err != nil {
12934 return nil, err
12935 }
12936 req.Header = reqHeaders
12937 googleapi.Expand(req.URL, map[string]string{
12938 "parent": c.parent,
12939 })
12940 return gensupport.SendRequest(c.ctx_, c.s.client, req)
12941 }
12942
12943
12944
12945
12946
12947
12948
12949 func (c *ExternaltransactionsCreateexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) {
12950 gensupport.SetOptions(c.urlParams_, opts...)
12951 res, err := c.doRequest("json")
12952 if res != nil && res.StatusCode == http.StatusNotModified {
12953 if res.Body != nil {
12954 res.Body.Close()
12955 }
12956 return nil, gensupport.WrapError(&googleapi.Error{
12957 Code: res.StatusCode,
12958 Header: res.Header,
12959 })
12960 }
12961 if err != nil {
12962 return nil, err
12963 }
12964 defer googleapi.CloseBody(res)
12965 if err := googleapi.CheckResponse(res); err != nil {
12966 return nil, gensupport.WrapError(err)
12967 }
12968 ret := &ExternalTransaction{
12969 ServerResponse: googleapi.ServerResponse{
12970 Header: res.Header,
12971 HTTPStatusCode: res.StatusCode,
12972 },
12973 }
12974 target := &ret
12975 if err := gensupport.DecodeResponse(target, res); err != nil {
12976 return nil, err
12977 }
12978 return ret, nil
12979 }
12980
12981 type ExternaltransactionsGetexternaltransactionCall struct {
12982 s *Service
12983 name string
12984 urlParams_ gensupport.URLParams
12985 ifNoneMatch_ string
12986 ctx_ context.Context
12987 header_ http.Header
12988 }
12989
12990
12991
12992
12993
12994 func (r *ExternaltransactionsService) Getexternaltransaction(name string) *ExternaltransactionsGetexternaltransactionCall {
12995 c := &ExternaltransactionsGetexternaltransactionCall{s: r.s, urlParams_: make(gensupport.URLParams)}
12996 c.name = name
12997 return c
12998 }
12999
13000
13001
13002
13003 func (c *ExternaltransactionsGetexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsGetexternaltransactionCall {
13004 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13005 return c
13006 }
13007
13008
13009
13010
13011 func (c *ExternaltransactionsGetexternaltransactionCall) IfNoneMatch(entityTag string) *ExternaltransactionsGetexternaltransactionCall {
13012 c.ifNoneMatch_ = entityTag
13013 return c
13014 }
13015
13016
13017 func (c *ExternaltransactionsGetexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsGetexternaltransactionCall {
13018 c.ctx_ = ctx
13019 return c
13020 }
13021
13022
13023
13024 func (c *ExternaltransactionsGetexternaltransactionCall) Header() http.Header {
13025 if c.header_ == nil {
13026 c.header_ = make(http.Header)
13027 }
13028 return c.header_
13029 }
13030
13031 func (c *ExternaltransactionsGetexternaltransactionCall) doRequest(alt string) (*http.Response, error) {
13032 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
13033 if c.ifNoneMatch_ != "" {
13034 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
13035 }
13036 var body io.Reader = nil
13037 c.urlParams_.Set("alt", alt)
13038 c.urlParams_.Set("prettyPrint", "false")
13039 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}")
13040 urls += "?" + c.urlParams_.Encode()
13041 req, err := http.NewRequest("GET", urls, body)
13042 if err != nil {
13043 return nil, err
13044 }
13045 req.Header = reqHeaders
13046 googleapi.Expand(req.URL, map[string]string{
13047 "name": c.name,
13048 })
13049 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13050 }
13051
13052
13053
13054
13055
13056
13057
13058 func (c *ExternaltransactionsGetexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) {
13059 gensupport.SetOptions(c.urlParams_, opts...)
13060 res, err := c.doRequest("json")
13061 if res != nil && res.StatusCode == http.StatusNotModified {
13062 if res.Body != nil {
13063 res.Body.Close()
13064 }
13065 return nil, gensupport.WrapError(&googleapi.Error{
13066 Code: res.StatusCode,
13067 Header: res.Header,
13068 })
13069 }
13070 if err != nil {
13071 return nil, err
13072 }
13073 defer googleapi.CloseBody(res)
13074 if err := googleapi.CheckResponse(res); err != nil {
13075 return nil, gensupport.WrapError(err)
13076 }
13077 ret := &ExternalTransaction{
13078 ServerResponse: googleapi.ServerResponse{
13079 Header: res.Header,
13080 HTTPStatusCode: res.StatusCode,
13081 },
13082 }
13083 target := &ret
13084 if err := gensupport.DecodeResponse(target, res); err != nil {
13085 return nil, err
13086 }
13087 return ret, nil
13088 }
13089
13090 type ExternaltransactionsRefundexternaltransactionCall struct {
13091 s *Service
13092 name string
13093 refundexternaltransactionrequest *RefundExternalTransactionRequest
13094 urlParams_ gensupport.URLParams
13095 ctx_ context.Context
13096 header_ http.Header
13097 }
13098
13099
13100
13101
13102
13103
13104 func (r *ExternaltransactionsService) Refundexternaltransaction(name string, refundexternaltransactionrequest *RefundExternalTransactionRequest) *ExternaltransactionsRefundexternaltransactionCall {
13105 c := &ExternaltransactionsRefundexternaltransactionCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13106 c.name = name
13107 c.refundexternaltransactionrequest = refundexternaltransactionrequest
13108 return c
13109 }
13110
13111
13112
13113
13114 func (c *ExternaltransactionsRefundexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsRefundexternaltransactionCall {
13115 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13116 return c
13117 }
13118
13119
13120 func (c *ExternaltransactionsRefundexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsRefundexternaltransactionCall {
13121 c.ctx_ = ctx
13122 return c
13123 }
13124
13125
13126
13127 func (c *ExternaltransactionsRefundexternaltransactionCall) Header() http.Header {
13128 if c.header_ == nil {
13129 c.header_ = make(http.Header)
13130 }
13131 return c.header_
13132 }
13133
13134 func (c *ExternaltransactionsRefundexternaltransactionCall) doRequest(alt string) (*http.Response, error) {
13135 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
13136 var body io.Reader = nil
13137 body, err := googleapi.WithoutDataWrapper.JSONReader(c.refundexternaltransactionrequest)
13138 if err != nil {
13139 return nil, err
13140 }
13141 c.urlParams_.Set("alt", alt)
13142 c.urlParams_.Set("prettyPrint", "false")
13143 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}:refund")
13144 urls += "?" + c.urlParams_.Encode()
13145 req, err := http.NewRequest("POST", urls, body)
13146 if err != nil {
13147 return nil, err
13148 }
13149 req.Header = reqHeaders
13150 googleapi.Expand(req.URL, map[string]string{
13151 "name": c.name,
13152 })
13153 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13154 }
13155
13156
13157
13158
13159
13160
13161
13162 func (c *ExternaltransactionsRefundexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) {
13163 gensupport.SetOptions(c.urlParams_, opts...)
13164 res, err := c.doRequest("json")
13165 if res != nil && res.StatusCode == http.StatusNotModified {
13166 if res.Body != nil {
13167 res.Body.Close()
13168 }
13169 return nil, gensupport.WrapError(&googleapi.Error{
13170 Code: res.StatusCode,
13171 Header: res.Header,
13172 })
13173 }
13174 if err != nil {
13175 return nil, err
13176 }
13177 defer googleapi.CloseBody(res)
13178 if err := googleapi.CheckResponse(res); err != nil {
13179 return nil, gensupport.WrapError(err)
13180 }
13181 ret := &ExternalTransaction{
13182 ServerResponse: googleapi.ServerResponse{
13183 Header: res.Header,
13184 HTTPStatusCode: res.StatusCode,
13185 },
13186 }
13187 target := &ret
13188 if err := gensupport.DecodeResponse(target, res); err != nil {
13189 return nil, err
13190 }
13191 return ret, nil
13192 }
13193
13194 type GeneratedapksDownloadCall struct {
13195 s *Service
13196 packageName string
13197 versionCode int64
13198 downloadId string
13199 urlParams_ gensupport.URLParams
13200 ifNoneMatch_ string
13201 ctx_ context.Context
13202 header_ http.Header
13203 }
13204
13205
13206
13207
13208
13209
13210
13211 func (r *GeneratedapksService) Download(packageName string, versionCode int64, downloadId string) *GeneratedapksDownloadCall {
13212 c := &GeneratedapksDownloadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13213 c.packageName = packageName
13214 c.versionCode = versionCode
13215 c.downloadId = downloadId
13216 return c
13217 }
13218
13219
13220
13221
13222 func (c *GeneratedapksDownloadCall) Fields(s ...googleapi.Field) *GeneratedapksDownloadCall {
13223 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13224 return c
13225 }
13226
13227
13228
13229
13230 func (c *GeneratedapksDownloadCall) IfNoneMatch(entityTag string) *GeneratedapksDownloadCall {
13231 c.ifNoneMatch_ = entityTag
13232 return c
13233 }
13234
13235
13236 func (c *GeneratedapksDownloadCall) Context(ctx context.Context) *GeneratedapksDownloadCall {
13237 c.ctx_ = ctx
13238 return c
13239 }
13240
13241
13242
13243 func (c *GeneratedapksDownloadCall) Header() http.Header {
13244 if c.header_ == nil {
13245 c.header_ = make(http.Header)
13246 }
13247 return c.header_
13248 }
13249
13250 func (c *GeneratedapksDownloadCall) doRequest(alt string) (*http.Response, error) {
13251 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
13252 if c.ifNoneMatch_ != "" {
13253 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
13254 }
13255 var body io.Reader = nil
13256 c.urlParams_.Set("alt", alt)
13257 c.urlParams_.Set("prettyPrint", "false")
13258 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/generatedApks/{versionCode}/downloads/{downloadId}:download")
13259 urls += "?" + c.urlParams_.Encode()
13260 req, err := http.NewRequest("GET", urls, body)
13261 if err != nil {
13262 return nil, err
13263 }
13264 req.Header = reqHeaders
13265 googleapi.Expand(req.URL, map[string]string{
13266 "packageName": c.packageName,
13267 "versionCode": strconv.FormatInt(c.versionCode, 10),
13268 "downloadId": c.downloadId,
13269 })
13270 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13271 }
13272
13273
13274
13275
13276 func (c *GeneratedapksDownloadCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
13277 gensupport.SetOptions(c.urlParams_, opts...)
13278 res, err := c.doRequest("media")
13279 if err != nil {
13280 return nil, err
13281 }
13282 if err := googleapi.CheckResponse(res); err != nil {
13283 res.Body.Close()
13284 return nil, gensupport.WrapError(err)
13285 }
13286 return res, nil
13287 }
13288
13289
13290 func (c *GeneratedapksDownloadCall) Do(opts ...googleapi.CallOption) error {
13291 gensupport.SetOptions(c.urlParams_, opts...)
13292 res, err := c.doRequest("json")
13293 if err != nil {
13294 return err
13295 }
13296 defer googleapi.CloseBody(res)
13297 if err := googleapi.CheckResponse(res); err != nil {
13298 return gensupport.WrapError(err)
13299 }
13300 return nil
13301 }
13302
13303 type GeneratedapksListCall struct {
13304 s *Service
13305 packageName string
13306 versionCode int64
13307 urlParams_ gensupport.URLParams
13308 ifNoneMatch_ string
13309 ctx_ context.Context
13310 header_ http.Header
13311 }
13312
13313
13314
13315
13316
13317
13318 func (r *GeneratedapksService) List(packageName string, versionCode int64) *GeneratedapksListCall {
13319 c := &GeneratedapksListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13320 c.packageName = packageName
13321 c.versionCode = versionCode
13322 return c
13323 }
13324
13325
13326
13327
13328 func (c *GeneratedapksListCall) Fields(s ...googleapi.Field) *GeneratedapksListCall {
13329 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13330 return c
13331 }
13332
13333
13334
13335
13336 func (c *GeneratedapksListCall) IfNoneMatch(entityTag string) *GeneratedapksListCall {
13337 c.ifNoneMatch_ = entityTag
13338 return c
13339 }
13340
13341
13342 func (c *GeneratedapksListCall) Context(ctx context.Context) *GeneratedapksListCall {
13343 c.ctx_ = ctx
13344 return c
13345 }
13346
13347
13348
13349 func (c *GeneratedapksListCall) Header() http.Header {
13350 if c.header_ == nil {
13351 c.header_ = make(http.Header)
13352 }
13353 return c.header_
13354 }
13355
13356 func (c *GeneratedapksListCall) doRequest(alt string) (*http.Response, error) {
13357 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
13358 if c.ifNoneMatch_ != "" {
13359 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
13360 }
13361 var body io.Reader = nil
13362 c.urlParams_.Set("alt", alt)
13363 c.urlParams_.Set("prettyPrint", "false")
13364 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/generatedApks/{versionCode}")
13365 urls += "?" + c.urlParams_.Encode()
13366 req, err := http.NewRequest("GET", urls, body)
13367 if err != nil {
13368 return nil, err
13369 }
13370 req.Header = reqHeaders
13371 googleapi.Expand(req.URL, map[string]string{
13372 "packageName": c.packageName,
13373 "versionCode": strconv.FormatInt(c.versionCode, 10),
13374 })
13375 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13376 }
13377
13378
13379
13380
13381
13382
13383
13384 func (c *GeneratedapksListCall) Do(opts ...googleapi.CallOption) (*GeneratedApksListResponse, error) {
13385 gensupport.SetOptions(c.urlParams_, opts...)
13386 res, err := c.doRequest("json")
13387 if res != nil && res.StatusCode == http.StatusNotModified {
13388 if res.Body != nil {
13389 res.Body.Close()
13390 }
13391 return nil, gensupport.WrapError(&googleapi.Error{
13392 Code: res.StatusCode,
13393 Header: res.Header,
13394 })
13395 }
13396 if err != nil {
13397 return nil, err
13398 }
13399 defer googleapi.CloseBody(res)
13400 if err := googleapi.CheckResponse(res); err != nil {
13401 return nil, gensupport.WrapError(err)
13402 }
13403 ret := &GeneratedApksListResponse{
13404 ServerResponse: googleapi.ServerResponse{
13405 Header: res.Header,
13406 HTTPStatusCode: res.StatusCode,
13407 },
13408 }
13409 target := &ret
13410 if err := gensupport.DecodeResponse(target, res); err != nil {
13411 return nil, err
13412 }
13413 return ret, nil
13414 }
13415
13416 type GrantsCreateCall struct {
13417 s *Service
13418 parent string
13419 grant *Grant
13420 urlParams_ gensupport.URLParams
13421 ctx_ context.Context
13422 header_ http.Header
13423 }
13424
13425
13426
13427
13428
13429 func (r *GrantsService) Create(parent string, grant *Grant) *GrantsCreateCall {
13430 c := &GrantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13431 c.parent = parent
13432 c.grant = grant
13433 return c
13434 }
13435
13436
13437
13438
13439 func (c *GrantsCreateCall) Fields(s ...googleapi.Field) *GrantsCreateCall {
13440 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13441 return c
13442 }
13443
13444
13445 func (c *GrantsCreateCall) Context(ctx context.Context) *GrantsCreateCall {
13446 c.ctx_ = ctx
13447 return c
13448 }
13449
13450
13451
13452 func (c *GrantsCreateCall) Header() http.Header {
13453 if c.header_ == nil {
13454 c.header_ = make(http.Header)
13455 }
13456 return c.header_
13457 }
13458
13459 func (c *GrantsCreateCall) doRequest(alt string) (*http.Response, error) {
13460 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
13461 var body io.Reader = nil
13462 body, err := googleapi.WithoutDataWrapper.JSONReader(c.grant)
13463 if err != nil {
13464 return nil, err
13465 }
13466 c.urlParams_.Set("alt", alt)
13467 c.urlParams_.Set("prettyPrint", "false")
13468 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+parent}/grants")
13469 urls += "?" + c.urlParams_.Encode()
13470 req, err := http.NewRequest("POST", urls, body)
13471 if err != nil {
13472 return nil, err
13473 }
13474 req.Header = reqHeaders
13475 googleapi.Expand(req.URL, map[string]string{
13476 "parent": c.parent,
13477 })
13478 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13479 }
13480
13481
13482
13483
13484
13485
13486 func (c *GrantsCreateCall) Do(opts ...googleapi.CallOption) (*Grant, error) {
13487 gensupport.SetOptions(c.urlParams_, opts...)
13488 res, err := c.doRequest("json")
13489 if res != nil && res.StatusCode == http.StatusNotModified {
13490 if res.Body != nil {
13491 res.Body.Close()
13492 }
13493 return nil, gensupport.WrapError(&googleapi.Error{
13494 Code: res.StatusCode,
13495 Header: res.Header,
13496 })
13497 }
13498 if err != nil {
13499 return nil, err
13500 }
13501 defer googleapi.CloseBody(res)
13502 if err := googleapi.CheckResponse(res); err != nil {
13503 return nil, gensupport.WrapError(err)
13504 }
13505 ret := &Grant{
13506 ServerResponse: googleapi.ServerResponse{
13507 Header: res.Header,
13508 HTTPStatusCode: res.StatusCode,
13509 },
13510 }
13511 target := &ret
13512 if err := gensupport.DecodeResponse(target, res); err != nil {
13513 return nil, err
13514 }
13515 return ret, nil
13516 }
13517
13518 type GrantsDeleteCall struct {
13519 s *Service
13520 name string
13521 urlParams_ gensupport.URLParams
13522 ctx_ context.Context
13523 header_ http.Header
13524 }
13525
13526
13527
13528
13529
13530
13531 func (r *GrantsService) Delete(name string) *GrantsDeleteCall {
13532 c := &GrantsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13533 c.name = name
13534 return c
13535 }
13536
13537
13538
13539
13540 func (c *GrantsDeleteCall) Fields(s ...googleapi.Field) *GrantsDeleteCall {
13541 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13542 return c
13543 }
13544
13545
13546 func (c *GrantsDeleteCall) Context(ctx context.Context) *GrantsDeleteCall {
13547 c.ctx_ = ctx
13548 return c
13549 }
13550
13551
13552
13553 func (c *GrantsDeleteCall) Header() http.Header {
13554 if c.header_ == nil {
13555 c.header_ = make(http.Header)
13556 }
13557 return c.header_
13558 }
13559
13560 func (c *GrantsDeleteCall) doRequest(alt string) (*http.Response, error) {
13561 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
13562 var body io.Reader = nil
13563 c.urlParams_.Set("alt", alt)
13564 c.urlParams_.Set("prettyPrint", "false")
13565 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}")
13566 urls += "?" + c.urlParams_.Encode()
13567 req, err := http.NewRequest("DELETE", urls, body)
13568 if err != nil {
13569 return nil, err
13570 }
13571 req.Header = reqHeaders
13572 googleapi.Expand(req.URL, map[string]string{
13573 "name": c.name,
13574 })
13575 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13576 }
13577
13578
13579 func (c *GrantsDeleteCall) Do(opts ...googleapi.CallOption) error {
13580 gensupport.SetOptions(c.urlParams_, opts...)
13581 res, err := c.doRequest("json")
13582 if err != nil {
13583 return err
13584 }
13585 defer googleapi.CloseBody(res)
13586 if err := googleapi.CheckResponse(res); err != nil {
13587 return gensupport.WrapError(err)
13588 }
13589 return nil
13590 }
13591
13592 type GrantsPatchCall struct {
13593 s *Service
13594 name string
13595 grant *Grant
13596 urlParams_ gensupport.URLParams
13597 ctx_ context.Context
13598 header_ http.Header
13599 }
13600
13601
13602
13603
13604
13605
13606
13607 func (r *GrantsService) Patch(name string, grant *Grant) *GrantsPatchCall {
13608 c := &GrantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13609 c.name = name
13610 c.grant = grant
13611 return c
13612 }
13613
13614
13615
13616 func (c *GrantsPatchCall) UpdateMask(updateMask string) *GrantsPatchCall {
13617 c.urlParams_.Set("updateMask", updateMask)
13618 return c
13619 }
13620
13621
13622
13623
13624 func (c *GrantsPatchCall) Fields(s ...googleapi.Field) *GrantsPatchCall {
13625 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13626 return c
13627 }
13628
13629
13630 func (c *GrantsPatchCall) Context(ctx context.Context) *GrantsPatchCall {
13631 c.ctx_ = ctx
13632 return c
13633 }
13634
13635
13636
13637 func (c *GrantsPatchCall) Header() http.Header {
13638 if c.header_ == nil {
13639 c.header_ = make(http.Header)
13640 }
13641 return c.header_
13642 }
13643
13644 func (c *GrantsPatchCall) doRequest(alt string) (*http.Response, error) {
13645 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
13646 var body io.Reader = nil
13647 body, err := googleapi.WithoutDataWrapper.JSONReader(c.grant)
13648 if err != nil {
13649 return nil, err
13650 }
13651 c.urlParams_.Set("alt", alt)
13652 c.urlParams_.Set("prettyPrint", "false")
13653 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}")
13654 urls += "?" + c.urlParams_.Encode()
13655 req, err := http.NewRequest("PATCH", urls, body)
13656 if err != nil {
13657 return nil, err
13658 }
13659 req.Header = reqHeaders
13660 googleapi.Expand(req.URL, map[string]string{
13661 "name": c.name,
13662 })
13663 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13664 }
13665
13666
13667
13668
13669
13670
13671 func (c *GrantsPatchCall) Do(opts ...googleapi.CallOption) (*Grant, error) {
13672 gensupport.SetOptions(c.urlParams_, opts...)
13673 res, err := c.doRequest("json")
13674 if res != nil && res.StatusCode == http.StatusNotModified {
13675 if res.Body != nil {
13676 res.Body.Close()
13677 }
13678 return nil, gensupport.WrapError(&googleapi.Error{
13679 Code: res.StatusCode,
13680 Header: res.Header,
13681 })
13682 }
13683 if err != nil {
13684 return nil, err
13685 }
13686 defer googleapi.CloseBody(res)
13687 if err := googleapi.CheckResponse(res); err != nil {
13688 return nil, gensupport.WrapError(err)
13689 }
13690 ret := &Grant{
13691 ServerResponse: googleapi.ServerResponse{
13692 Header: res.Header,
13693 HTTPStatusCode: res.StatusCode,
13694 },
13695 }
13696 target := &ret
13697 if err := gensupport.DecodeResponse(target, res); err != nil {
13698 return nil, err
13699 }
13700 return ret, nil
13701 }
13702
13703 type InappproductsBatchDeleteCall struct {
13704 s *Service
13705 packageName string
13706 inappproductsbatchdeleterequest *InappproductsBatchDeleteRequest
13707 urlParams_ gensupport.URLParams
13708 ctx_ context.Context
13709 header_ http.Header
13710 }
13711
13712
13713
13714
13715
13716
13717
13718
13719
13720
13721 func (r *InappproductsService) BatchDelete(packageName string, inappproductsbatchdeleterequest *InappproductsBatchDeleteRequest) *InappproductsBatchDeleteCall {
13722 c := &InappproductsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13723 c.packageName = packageName
13724 c.inappproductsbatchdeleterequest = inappproductsbatchdeleterequest
13725 return c
13726 }
13727
13728
13729
13730
13731 func (c *InappproductsBatchDeleteCall) Fields(s ...googleapi.Field) *InappproductsBatchDeleteCall {
13732 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13733 return c
13734 }
13735
13736
13737 func (c *InappproductsBatchDeleteCall) Context(ctx context.Context) *InappproductsBatchDeleteCall {
13738 c.ctx_ = ctx
13739 return c
13740 }
13741
13742
13743
13744 func (c *InappproductsBatchDeleteCall) Header() http.Header {
13745 if c.header_ == nil {
13746 c.header_ = make(http.Header)
13747 }
13748 return c.header_
13749 }
13750
13751 func (c *InappproductsBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
13752 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
13753 var body io.Reader = nil
13754 body, err := googleapi.WithoutDataWrapper.JSONReader(c.inappproductsbatchdeleterequest)
13755 if err != nil {
13756 return nil, err
13757 }
13758 c.urlParams_.Set("alt", alt)
13759 c.urlParams_.Set("prettyPrint", "false")
13760 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchDelete")
13761 urls += "?" + c.urlParams_.Encode()
13762 req, err := http.NewRequest("POST", urls, body)
13763 if err != nil {
13764 return nil, err
13765 }
13766 req.Header = reqHeaders
13767 googleapi.Expand(req.URL, map[string]string{
13768 "packageName": c.packageName,
13769 })
13770 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13771 }
13772
13773
13774 func (c *InappproductsBatchDeleteCall) Do(opts ...googleapi.CallOption) error {
13775 gensupport.SetOptions(c.urlParams_, opts...)
13776 res, err := c.doRequest("json")
13777 if err != nil {
13778 return err
13779 }
13780 defer googleapi.CloseBody(res)
13781 if err := googleapi.CheckResponse(res); err != nil {
13782 return gensupport.WrapError(err)
13783 }
13784 return nil
13785 }
13786
13787 type InappproductsBatchGetCall struct {
13788 s *Service
13789 packageName string
13790 urlParams_ gensupport.URLParams
13791 ifNoneMatch_ string
13792 ctx_ context.Context
13793 header_ http.Header
13794 }
13795
13796
13797
13798
13799
13800
13801
13802
13803 func (r *InappproductsService) BatchGet(packageName string) *InappproductsBatchGetCall {
13804 c := &InappproductsBatchGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13805 c.packageName = packageName
13806 return c
13807 }
13808
13809
13810
13811 func (c *InappproductsBatchGetCall) Sku(sku ...string) *InappproductsBatchGetCall {
13812 c.urlParams_.SetMulti("sku", append([]string{}, sku...))
13813 return c
13814 }
13815
13816
13817
13818
13819 func (c *InappproductsBatchGetCall) Fields(s ...googleapi.Field) *InappproductsBatchGetCall {
13820 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13821 return c
13822 }
13823
13824
13825
13826
13827 func (c *InappproductsBatchGetCall) IfNoneMatch(entityTag string) *InappproductsBatchGetCall {
13828 c.ifNoneMatch_ = entityTag
13829 return c
13830 }
13831
13832
13833 func (c *InappproductsBatchGetCall) Context(ctx context.Context) *InappproductsBatchGetCall {
13834 c.ctx_ = ctx
13835 return c
13836 }
13837
13838
13839
13840 func (c *InappproductsBatchGetCall) Header() http.Header {
13841 if c.header_ == nil {
13842 c.header_ = make(http.Header)
13843 }
13844 return c.header_
13845 }
13846
13847 func (c *InappproductsBatchGetCall) doRequest(alt string) (*http.Response, error) {
13848 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
13849 if c.ifNoneMatch_ != "" {
13850 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
13851 }
13852 var body io.Reader = nil
13853 c.urlParams_.Set("alt", alt)
13854 c.urlParams_.Set("prettyPrint", "false")
13855 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchGet")
13856 urls += "?" + c.urlParams_.Encode()
13857 req, err := http.NewRequest("GET", urls, body)
13858 if err != nil {
13859 return nil, err
13860 }
13861 req.Header = reqHeaders
13862 googleapi.Expand(req.URL, map[string]string{
13863 "packageName": c.packageName,
13864 })
13865 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13866 }
13867
13868
13869
13870
13871
13872
13873
13874 func (c *InappproductsBatchGetCall) Do(opts ...googleapi.CallOption) (*InappproductsBatchGetResponse, error) {
13875 gensupport.SetOptions(c.urlParams_, opts...)
13876 res, err := c.doRequest("json")
13877 if res != nil && res.StatusCode == http.StatusNotModified {
13878 if res.Body != nil {
13879 res.Body.Close()
13880 }
13881 return nil, gensupport.WrapError(&googleapi.Error{
13882 Code: res.StatusCode,
13883 Header: res.Header,
13884 })
13885 }
13886 if err != nil {
13887 return nil, err
13888 }
13889 defer googleapi.CloseBody(res)
13890 if err := googleapi.CheckResponse(res); err != nil {
13891 return nil, gensupport.WrapError(err)
13892 }
13893 ret := &InappproductsBatchGetResponse{
13894 ServerResponse: googleapi.ServerResponse{
13895 Header: res.Header,
13896 HTTPStatusCode: res.StatusCode,
13897 },
13898 }
13899 target := &ret
13900 if err := gensupport.DecodeResponse(target, res); err != nil {
13901 return nil, err
13902 }
13903 return ret, nil
13904 }
13905
13906 type InappproductsBatchUpdateCall struct {
13907 s *Service
13908 packageName string
13909 inappproductsbatchupdaterequest *InappproductsBatchUpdateRequest
13910 urlParams_ gensupport.URLParams
13911 ctx_ context.Context
13912 header_ http.Header
13913 }
13914
13915
13916
13917
13918
13919
13920
13921
13922
13923
13924 func (r *InappproductsService) BatchUpdate(packageName string, inappproductsbatchupdaterequest *InappproductsBatchUpdateRequest) *InappproductsBatchUpdateCall {
13925 c := &InappproductsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
13926 c.packageName = packageName
13927 c.inappproductsbatchupdaterequest = inappproductsbatchupdaterequest
13928 return c
13929 }
13930
13931
13932
13933
13934 func (c *InappproductsBatchUpdateCall) Fields(s ...googleapi.Field) *InappproductsBatchUpdateCall {
13935 c.urlParams_.Set("fields", googleapi.CombineFields(s))
13936 return c
13937 }
13938
13939
13940 func (c *InappproductsBatchUpdateCall) Context(ctx context.Context) *InappproductsBatchUpdateCall {
13941 c.ctx_ = ctx
13942 return c
13943 }
13944
13945
13946
13947 func (c *InappproductsBatchUpdateCall) Header() http.Header {
13948 if c.header_ == nil {
13949 c.header_ = make(http.Header)
13950 }
13951 return c.header_
13952 }
13953
13954 func (c *InappproductsBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
13955 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
13956 var body io.Reader = nil
13957 body, err := googleapi.WithoutDataWrapper.JSONReader(c.inappproductsbatchupdaterequest)
13958 if err != nil {
13959 return nil, err
13960 }
13961 c.urlParams_.Set("alt", alt)
13962 c.urlParams_.Set("prettyPrint", "false")
13963 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchUpdate")
13964 urls += "?" + c.urlParams_.Encode()
13965 req, err := http.NewRequest("POST", urls, body)
13966 if err != nil {
13967 return nil, err
13968 }
13969 req.Header = reqHeaders
13970 googleapi.Expand(req.URL, map[string]string{
13971 "packageName": c.packageName,
13972 })
13973 return gensupport.SendRequest(c.ctx_, c.s.client, req)
13974 }
13975
13976
13977
13978
13979
13980
13981
13982 func (c *InappproductsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*InappproductsBatchUpdateResponse, error) {
13983 gensupport.SetOptions(c.urlParams_, opts...)
13984 res, err := c.doRequest("json")
13985 if res != nil && res.StatusCode == http.StatusNotModified {
13986 if res.Body != nil {
13987 res.Body.Close()
13988 }
13989 return nil, gensupport.WrapError(&googleapi.Error{
13990 Code: res.StatusCode,
13991 Header: res.Header,
13992 })
13993 }
13994 if err != nil {
13995 return nil, err
13996 }
13997 defer googleapi.CloseBody(res)
13998 if err := googleapi.CheckResponse(res); err != nil {
13999 return nil, gensupport.WrapError(err)
14000 }
14001 ret := &InappproductsBatchUpdateResponse{
14002 ServerResponse: googleapi.ServerResponse{
14003 Header: res.Header,
14004 HTTPStatusCode: res.StatusCode,
14005 },
14006 }
14007 target := &ret
14008 if err := gensupport.DecodeResponse(target, res); err != nil {
14009 return nil, err
14010 }
14011 return ret, nil
14012 }
14013
14014 type InappproductsDeleteCall struct {
14015 s *Service
14016 packageName string
14017 skuid string
14018 urlParams_ gensupport.URLParams
14019 ctx_ context.Context
14020 header_ http.Header
14021 }
14022
14023
14024
14025
14026
14027
14028
14029
14030
14031 func (r *InappproductsService) Delete(packageName string, skuid string) *InappproductsDeleteCall {
14032 c := &InappproductsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14033 c.packageName = packageName
14034 c.skuid = skuid
14035 return c
14036 }
14037
14038
14039
14040
14041
14042
14043
14044
14045
14046
14047
14048
14049
14050
14051
14052
14053
14054
14055
14056
14057 func (c *InappproductsDeleteCall) LatencyTolerance(latencyTolerance string) *InappproductsDeleteCall {
14058 c.urlParams_.Set("latencyTolerance", latencyTolerance)
14059 return c
14060 }
14061
14062
14063
14064
14065 func (c *InappproductsDeleteCall) Fields(s ...googleapi.Field) *InappproductsDeleteCall {
14066 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14067 return c
14068 }
14069
14070
14071 func (c *InappproductsDeleteCall) Context(ctx context.Context) *InappproductsDeleteCall {
14072 c.ctx_ = ctx
14073 return c
14074 }
14075
14076
14077
14078 func (c *InappproductsDeleteCall) Header() http.Header {
14079 if c.header_ == nil {
14080 c.header_ = make(http.Header)
14081 }
14082 return c.header_
14083 }
14084
14085 func (c *InappproductsDeleteCall) doRequest(alt string) (*http.Response, error) {
14086 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
14087 var body io.Reader = nil
14088 c.urlParams_.Set("alt", alt)
14089 c.urlParams_.Set("prettyPrint", "false")
14090 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}")
14091 urls += "?" + c.urlParams_.Encode()
14092 req, err := http.NewRequest("DELETE", urls, body)
14093 if err != nil {
14094 return nil, err
14095 }
14096 req.Header = reqHeaders
14097 googleapi.Expand(req.URL, map[string]string{
14098 "packageName": c.packageName,
14099 "sku": c.skuid,
14100 })
14101 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14102 }
14103
14104
14105 func (c *InappproductsDeleteCall) Do(opts ...googleapi.CallOption) error {
14106 gensupport.SetOptions(c.urlParams_, opts...)
14107 res, err := c.doRequest("json")
14108 if err != nil {
14109 return err
14110 }
14111 defer googleapi.CloseBody(res)
14112 if err := googleapi.CheckResponse(res); err != nil {
14113 return gensupport.WrapError(err)
14114 }
14115 return nil
14116 }
14117
14118 type InappproductsGetCall struct {
14119 s *Service
14120 packageName string
14121 skuid string
14122 urlParams_ gensupport.URLParams
14123 ifNoneMatch_ string
14124 ctx_ context.Context
14125 header_ http.Header
14126 }
14127
14128
14129
14130
14131
14132
14133
14134
14135
14136 func (r *InappproductsService) Get(packageName string, skuid string) *InappproductsGetCall {
14137 c := &InappproductsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14138 c.packageName = packageName
14139 c.skuid = skuid
14140 return c
14141 }
14142
14143
14144
14145
14146 func (c *InappproductsGetCall) Fields(s ...googleapi.Field) *InappproductsGetCall {
14147 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14148 return c
14149 }
14150
14151
14152
14153
14154 func (c *InappproductsGetCall) IfNoneMatch(entityTag string) *InappproductsGetCall {
14155 c.ifNoneMatch_ = entityTag
14156 return c
14157 }
14158
14159
14160 func (c *InappproductsGetCall) Context(ctx context.Context) *InappproductsGetCall {
14161 c.ctx_ = ctx
14162 return c
14163 }
14164
14165
14166
14167 func (c *InappproductsGetCall) Header() http.Header {
14168 if c.header_ == nil {
14169 c.header_ = make(http.Header)
14170 }
14171 return c.header_
14172 }
14173
14174 func (c *InappproductsGetCall) doRequest(alt string) (*http.Response, error) {
14175 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
14176 if c.ifNoneMatch_ != "" {
14177 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14178 }
14179 var body io.Reader = nil
14180 c.urlParams_.Set("alt", alt)
14181 c.urlParams_.Set("prettyPrint", "false")
14182 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}")
14183 urls += "?" + c.urlParams_.Encode()
14184 req, err := http.NewRequest("GET", urls, body)
14185 if err != nil {
14186 return nil, err
14187 }
14188 req.Header = reqHeaders
14189 googleapi.Expand(req.URL, map[string]string{
14190 "packageName": c.packageName,
14191 "sku": c.skuid,
14192 })
14193 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14194 }
14195
14196
14197
14198
14199
14200
14201 func (c *InappproductsGetCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) {
14202 gensupport.SetOptions(c.urlParams_, opts...)
14203 res, err := c.doRequest("json")
14204 if res != nil && res.StatusCode == http.StatusNotModified {
14205 if res.Body != nil {
14206 res.Body.Close()
14207 }
14208 return nil, gensupport.WrapError(&googleapi.Error{
14209 Code: res.StatusCode,
14210 Header: res.Header,
14211 })
14212 }
14213 if err != nil {
14214 return nil, err
14215 }
14216 defer googleapi.CloseBody(res)
14217 if err := googleapi.CheckResponse(res); err != nil {
14218 return nil, gensupport.WrapError(err)
14219 }
14220 ret := &InAppProduct{
14221 ServerResponse: googleapi.ServerResponse{
14222 Header: res.Header,
14223 HTTPStatusCode: res.StatusCode,
14224 },
14225 }
14226 target := &ret
14227 if err := gensupport.DecodeResponse(target, res); err != nil {
14228 return nil, err
14229 }
14230 return ret, nil
14231 }
14232
14233 type InappproductsInsertCall struct {
14234 s *Service
14235 packageName string
14236 inappproduct *InAppProduct
14237 urlParams_ gensupport.URLParams
14238 ctx_ context.Context
14239 header_ http.Header
14240 }
14241
14242
14243
14244
14245
14246
14247
14248
14249 func (r *InappproductsService) Insert(packageName string, inappproduct *InAppProduct) *InappproductsInsertCall {
14250 c := &InappproductsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14251 c.packageName = packageName
14252 c.inappproduct = inappproduct
14253 return c
14254 }
14255
14256
14257
14258
14259
14260
14261 func (c *InappproductsInsertCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsInsertCall {
14262 c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices))
14263 return c
14264 }
14265
14266
14267
14268
14269 func (c *InappproductsInsertCall) Fields(s ...googleapi.Field) *InappproductsInsertCall {
14270 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14271 return c
14272 }
14273
14274
14275 func (c *InappproductsInsertCall) Context(ctx context.Context) *InappproductsInsertCall {
14276 c.ctx_ = ctx
14277 return c
14278 }
14279
14280
14281
14282 func (c *InappproductsInsertCall) Header() http.Header {
14283 if c.header_ == nil {
14284 c.header_ = make(http.Header)
14285 }
14286 return c.header_
14287 }
14288
14289 func (c *InappproductsInsertCall) doRequest(alt string) (*http.Response, error) {
14290 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
14291 var body io.Reader = nil
14292 body, err := googleapi.WithoutDataWrapper.JSONReader(c.inappproduct)
14293 if err != nil {
14294 return nil, err
14295 }
14296 c.urlParams_.Set("alt", alt)
14297 c.urlParams_.Set("prettyPrint", "false")
14298 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts")
14299 urls += "?" + c.urlParams_.Encode()
14300 req, err := http.NewRequest("POST", urls, body)
14301 if err != nil {
14302 return nil, err
14303 }
14304 req.Header = reqHeaders
14305 googleapi.Expand(req.URL, map[string]string{
14306 "packageName": c.packageName,
14307 })
14308 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14309 }
14310
14311
14312
14313
14314
14315
14316 func (c *InappproductsInsertCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) {
14317 gensupport.SetOptions(c.urlParams_, opts...)
14318 res, err := c.doRequest("json")
14319 if res != nil && res.StatusCode == http.StatusNotModified {
14320 if res.Body != nil {
14321 res.Body.Close()
14322 }
14323 return nil, gensupport.WrapError(&googleapi.Error{
14324 Code: res.StatusCode,
14325 Header: res.Header,
14326 })
14327 }
14328 if err != nil {
14329 return nil, err
14330 }
14331 defer googleapi.CloseBody(res)
14332 if err := googleapi.CheckResponse(res); err != nil {
14333 return nil, gensupport.WrapError(err)
14334 }
14335 ret := &InAppProduct{
14336 ServerResponse: googleapi.ServerResponse{
14337 Header: res.Header,
14338 HTTPStatusCode: res.StatusCode,
14339 },
14340 }
14341 target := &ret
14342 if err := gensupport.DecodeResponse(target, res); err != nil {
14343 return nil, err
14344 }
14345 return ret, nil
14346 }
14347
14348 type InappproductsListCall struct {
14349 s *Service
14350 packageName string
14351 urlParams_ gensupport.URLParams
14352 ifNoneMatch_ string
14353 ctx_ context.Context
14354 header_ http.Header
14355 }
14356
14357
14358
14359
14360
14361
14362
14363
14364
14365
14366
14367 func (r *InappproductsService) List(packageName string) *InappproductsListCall {
14368 c := &InappproductsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14369 c.packageName = packageName
14370 return c
14371 }
14372
14373
14374
14375 func (c *InappproductsListCall) MaxResults(maxResults int64) *InappproductsListCall {
14376 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
14377 return c
14378 }
14379
14380
14381
14382 func (c *InappproductsListCall) StartIndex(startIndex int64) *InappproductsListCall {
14383 c.urlParams_.Set("startIndex", fmt.Sprint(startIndex))
14384 return c
14385 }
14386
14387
14388
14389 func (c *InappproductsListCall) Token(token string) *InappproductsListCall {
14390 c.urlParams_.Set("token", token)
14391 return c
14392 }
14393
14394
14395
14396
14397 func (c *InappproductsListCall) Fields(s ...googleapi.Field) *InappproductsListCall {
14398 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14399 return c
14400 }
14401
14402
14403
14404
14405 func (c *InappproductsListCall) IfNoneMatch(entityTag string) *InappproductsListCall {
14406 c.ifNoneMatch_ = entityTag
14407 return c
14408 }
14409
14410
14411 func (c *InappproductsListCall) Context(ctx context.Context) *InappproductsListCall {
14412 c.ctx_ = ctx
14413 return c
14414 }
14415
14416
14417
14418 func (c *InappproductsListCall) Header() http.Header {
14419 if c.header_ == nil {
14420 c.header_ = make(http.Header)
14421 }
14422 return c.header_
14423 }
14424
14425 func (c *InappproductsListCall) doRequest(alt string) (*http.Response, error) {
14426 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
14427 if c.ifNoneMatch_ != "" {
14428 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14429 }
14430 var body io.Reader = nil
14431 c.urlParams_.Set("alt", alt)
14432 c.urlParams_.Set("prettyPrint", "false")
14433 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts")
14434 urls += "?" + c.urlParams_.Encode()
14435 req, err := http.NewRequest("GET", urls, body)
14436 if err != nil {
14437 return nil, err
14438 }
14439 req.Header = reqHeaders
14440 googleapi.Expand(req.URL, map[string]string{
14441 "packageName": c.packageName,
14442 })
14443 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14444 }
14445
14446
14447
14448
14449
14450
14451
14452 func (c *InappproductsListCall) Do(opts ...googleapi.CallOption) (*InappproductsListResponse, error) {
14453 gensupport.SetOptions(c.urlParams_, opts...)
14454 res, err := c.doRequest("json")
14455 if res != nil && res.StatusCode == http.StatusNotModified {
14456 if res.Body != nil {
14457 res.Body.Close()
14458 }
14459 return nil, gensupport.WrapError(&googleapi.Error{
14460 Code: res.StatusCode,
14461 Header: res.Header,
14462 })
14463 }
14464 if err != nil {
14465 return nil, err
14466 }
14467 defer googleapi.CloseBody(res)
14468 if err := googleapi.CheckResponse(res); err != nil {
14469 return nil, gensupport.WrapError(err)
14470 }
14471 ret := &InappproductsListResponse{
14472 ServerResponse: googleapi.ServerResponse{
14473 Header: res.Header,
14474 HTTPStatusCode: res.StatusCode,
14475 },
14476 }
14477 target := &ret
14478 if err := gensupport.DecodeResponse(target, res); err != nil {
14479 return nil, err
14480 }
14481 return ret, nil
14482 }
14483
14484 type InappproductsPatchCall struct {
14485 s *Service
14486 packageName string
14487 skuid string
14488 inappproduct *InAppProduct
14489 urlParams_ gensupport.URLParams
14490 ctx_ context.Context
14491 header_ http.Header
14492 }
14493
14494
14495
14496
14497
14498
14499
14500
14501 func (r *InappproductsService) Patch(packageName string, skuid string, inappproduct *InAppProduct) *InappproductsPatchCall {
14502 c := &InappproductsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14503 c.packageName = packageName
14504 c.skuid = skuid
14505 c.inappproduct = inappproduct
14506 return c
14507 }
14508
14509
14510
14511
14512
14513
14514 func (c *InappproductsPatchCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsPatchCall {
14515 c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices))
14516 return c
14517 }
14518
14519
14520
14521
14522
14523
14524
14525
14526
14527
14528
14529
14530
14531
14532
14533
14534
14535
14536
14537
14538 func (c *InappproductsPatchCall) LatencyTolerance(latencyTolerance string) *InappproductsPatchCall {
14539 c.urlParams_.Set("latencyTolerance", latencyTolerance)
14540 return c
14541 }
14542
14543
14544
14545
14546 func (c *InappproductsPatchCall) Fields(s ...googleapi.Field) *InappproductsPatchCall {
14547 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14548 return c
14549 }
14550
14551
14552 func (c *InappproductsPatchCall) Context(ctx context.Context) *InappproductsPatchCall {
14553 c.ctx_ = ctx
14554 return c
14555 }
14556
14557
14558
14559 func (c *InappproductsPatchCall) Header() http.Header {
14560 if c.header_ == nil {
14561 c.header_ = make(http.Header)
14562 }
14563 return c.header_
14564 }
14565
14566 func (c *InappproductsPatchCall) doRequest(alt string) (*http.Response, error) {
14567 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
14568 var body io.Reader = nil
14569 body, err := googleapi.WithoutDataWrapper.JSONReader(c.inappproduct)
14570 if err != nil {
14571 return nil, err
14572 }
14573 c.urlParams_.Set("alt", alt)
14574 c.urlParams_.Set("prettyPrint", "false")
14575 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}")
14576 urls += "?" + c.urlParams_.Encode()
14577 req, err := http.NewRequest("PATCH", urls, body)
14578 if err != nil {
14579 return nil, err
14580 }
14581 req.Header = reqHeaders
14582 googleapi.Expand(req.URL, map[string]string{
14583 "packageName": c.packageName,
14584 "sku": c.skuid,
14585 })
14586 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14587 }
14588
14589
14590
14591
14592
14593
14594 func (c *InappproductsPatchCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) {
14595 gensupport.SetOptions(c.urlParams_, opts...)
14596 res, err := c.doRequest("json")
14597 if res != nil && res.StatusCode == http.StatusNotModified {
14598 if res.Body != nil {
14599 res.Body.Close()
14600 }
14601 return nil, gensupport.WrapError(&googleapi.Error{
14602 Code: res.StatusCode,
14603 Header: res.Header,
14604 })
14605 }
14606 if err != nil {
14607 return nil, err
14608 }
14609 defer googleapi.CloseBody(res)
14610 if err := googleapi.CheckResponse(res); err != nil {
14611 return nil, gensupport.WrapError(err)
14612 }
14613 ret := &InAppProduct{
14614 ServerResponse: googleapi.ServerResponse{
14615 Header: res.Header,
14616 HTTPStatusCode: res.StatusCode,
14617 },
14618 }
14619 target := &ret
14620 if err := gensupport.DecodeResponse(target, res); err != nil {
14621 return nil, err
14622 }
14623 return ret, nil
14624 }
14625
14626 type InappproductsUpdateCall struct {
14627 s *Service
14628 packageName string
14629 skuid string
14630 inappproduct *InAppProduct
14631 urlParams_ gensupport.URLParams
14632 ctx_ context.Context
14633 header_ http.Header
14634 }
14635
14636
14637
14638
14639
14640
14641
14642
14643
14644 func (r *InappproductsService) Update(packageName string, skuid string, inappproduct *InAppProduct) *InappproductsUpdateCall {
14645 c := &InappproductsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14646 c.packageName = packageName
14647 c.skuid = skuid
14648 c.inappproduct = inappproduct
14649 return c
14650 }
14651
14652
14653
14654
14655 func (c *InappproductsUpdateCall) AllowMissing(allowMissing bool) *InappproductsUpdateCall {
14656 c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing))
14657 return c
14658 }
14659
14660
14661
14662
14663
14664
14665 func (c *InappproductsUpdateCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsUpdateCall {
14666 c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices))
14667 return c
14668 }
14669
14670
14671
14672
14673
14674
14675
14676
14677
14678
14679
14680
14681
14682
14683
14684
14685
14686
14687
14688
14689 func (c *InappproductsUpdateCall) LatencyTolerance(latencyTolerance string) *InappproductsUpdateCall {
14690 c.urlParams_.Set("latencyTolerance", latencyTolerance)
14691 return c
14692 }
14693
14694
14695
14696
14697 func (c *InappproductsUpdateCall) Fields(s ...googleapi.Field) *InappproductsUpdateCall {
14698 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14699 return c
14700 }
14701
14702
14703 func (c *InappproductsUpdateCall) Context(ctx context.Context) *InappproductsUpdateCall {
14704 c.ctx_ = ctx
14705 return c
14706 }
14707
14708
14709
14710 func (c *InappproductsUpdateCall) Header() http.Header {
14711 if c.header_ == nil {
14712 c.header_ = make(http.Header)
14713 }
14714 return c.header_
14715 }
14716
14717 func (c *InappproductsUpdateCall) doRequest(alt string) (*http.Response, error) {
14718 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
14719 var body io.Reader = nil
14720 body, err := googleapi.WithoutDataWrapper.JSONReader(c.inappproduct)
14721 if err != nil {
14722 return nil, err
14723 }
14724 c.urlParams_.Set("alt", alt)
14725 c.urlParams_.Set("prettyPrint", "false")
14726 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}")
14727 urls += "?" + c.urlParams_.Encode()
14728 req, err := http.NewRequest("PUT", urls, body)
14729 if err != nil {
14730 return nil, err
14731 }
14732 req.Header = reqHeaders
14733 googleapi.Expand(req.URL, map[string]string{
14734 "packageName": c.packageName,
14735 "sku": c.skuid,
14736 })
14737 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14738 }
14739
14740
14741
14742
14743
14744
14745 func (c *InappproductsUpdateCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) {
14746 gensupport.SetOptions(c.urlParams_, opts...)
14747 res, err := c.doRequest("json")
14748 if res != nil && res.StatusCode == http.StatusNotModified {
14749 if res.Body != nil {
14750 res.Body.Close()
14751 }
14752 return nil, gensupport.WrapError(&googleapi.Error{
14753 Code: res.StatusCode,
14754 Header: res.Header,
14755 })
14756 }
14757 if err != nil {
14758 return nil, err
14759 }
14760 defer googleapi.CloseBody(res)
14761 if err := googleapi.CheckResponse(res); err != nil {
14762 return nil, gensupport.WrapError(err)
14763 }
14764 ret := &InAppProduct{
14765 ServerResponse: googleapi.ServerResponse{
14766 Header: res.Header,
14767 HTTPStatusCode: res.StatusCode,
14768 },
14769 }
14770 target := &ret
14771 if err := gensupport.DecodeResponse(target, res); err != nil {
14772 return nil, err
14773 }
14774 return ret, nil
14775 }
14776
14777 type InternalappsharingartifactsUploadapkCall struct {
14778 s *Service
14779 packageName string
14780 urlParams_ gensupport.URLParams
14781 mediaInfo_ *gensupport.MediaInfo
14782 ctx_ context.Context
14783 header_ http.Header
14784 }
14785
14786
14787
14788
14789
14790
14791
14792
14793
14794 func (r *InternalappsharingartifactsService) Uploadapk(packageName string) *InternalappsharingartifactsUploadapkCall {
14795 c := &InternalappsharingartifactsUploadapkCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14796 c.packageName = packageName
14797 return c
14798 }
14799
14800
14801
14802
14803
14804
14805
14806
14807 func (c *InternalappsharingartifactsUploadapkCall) Media(r io.Reader, options ...googleapi.MediaOption) *InternalappsharingartifactsUploadapkCall {
14808 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
14809 return c
14810 }
14811
14812
14813
14814
14815
14816
14817
14818
14819
14820
14821 func (c *InternalappsharingartifactsUploadapkCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *InternalappsharingartifactsUploadapkCall {
14822 c.ctx_ = ctx
14823 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
14824 return c
14825 }
14826
14827
14828
14829
14830
14831 func (c *InternalappsharingartifactsUploadapkCall) ProgressUpdater(pu googleapi.ProgressUpdater) *InternalappsharingartifactsUploadapkCall {
14832 c.mediaInfo_.SetProgressUpdater(pu)
14833 return c
14834 }
14835
14836
14837
14838
14839 func (c *InternalappsharingartifactsUploadapkCall) Fields(s ...googleapi.Field) *InternalappsharingartifactsUploadapkCall {
14840 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14841 return c
14842 }
14843
14844
14845
14846
14847 func (c *InternalappsharingartifactsUploadapkCall) Context(ctx context.Context) *InternalappsharingartifactsUploadapkCall {
14848 c.ctx_ = ctx
14849 return c
14850 }
14851
14852
14853
14854 func (c *InternalappsharingartifactsUploadapkCall) Header() http.Header {
14855 if c.header_ == nil {
14856 c.header_ = make(http.Header)
14857 }
14858 return c.header_
14859 }
14860
14861 func (c *InternalappsharingartifactsUploadapkCall) doRequest(alt string) (*http.Response, error) {
14862 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
14863 var body io.Reader = nil
14864 c.urlParams_.Set("alt", alt)
14865 c.urlParams_.Set("prettyPrint", "false")
14866 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/apk")
14867 if c.mediaInfo_ != nil {
14868 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/apk")
14869 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
14870 }
14871 if body == nil {
14872 body = new(bytes.Buffer)
14873 reqHeaders.Set("Content-Type", "application/json")
14874 }
14875 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
14876 defer cleanup()
14877 urls += "?" + c.urlParams_.Encode()
14878 req, err := http.NewRequest("POST", urls, body)
14879 if err != nil {
14880 return nil, err
14881 }
14882 req.Header = reqHeaders
14883 req.GetBody = getBody
14884 googleapi.Expand(req.URL, map[string]string{
14885 "packageName": c.packageName,
14886 })
14887 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14888 }
14889
14890
14891
14892
14893
14894
14895
14896 func (c *InternalappsharingartifactsUploadapkCall) Do(opts ...googleapi.CallOption) (*InternalAppSharingArtifact, error) {
14897 gensupport.SetOptions(c.urlParams_, opts...)
14898 res, err := c.doRequest("json")
14899 if res != nil && res.StatusCode == http.StatusNotModified {
14900 if res.Body != nil {
14901 res.Body.Close()
14902 }
14903 return nil, gensupport.WrapError(&googleapi.Error{
14904 Code: res.StatusCode,
14905 Header: res.Header,
14906 })
14907 }
14908 if err != nil {
14909 return nil, err
14910 }
14911 defer googleapi.CloseBody(res)
14912 if err := googleapi.CheckResponse(res); err != nil {
14913 return nil, gensupport.WrapError(err)
14914 }
14915 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
14916 if rx != nil {
14917 rx.Client = c.s.client
14918 rx.UserAgent = c.s.userAgent()
14919 ctx := c.ctx_
14920 if ctx == nil {
14921 ctx = context.TODO()
14922 }
14923 res, err = rx.Upload(ctx)
14924 if err != nil {
14925 return nil, err
14926 }
14927 defer res.Body.Close()
14928 if err := googleapi.CheckResponse(res); err != nil {
14929 return nil, gensupport.WrapError(err)
14930 }
14931 }
14932 ret := &InternalAppSharingArtifact{
14933 ServerResponse: googleapi.ServerResponse{
14934 Header: res.Header,
14935 HTTPStatusCode: res.StatusCode,
14936 },
14937 }
14938 target := &ret
14939 if err := gensupport.DecodeResponse(target, res); err != nil {
14940 return nil, err
14941 }
14942 return ret, nil
14943 }
14944
14945 type InternalappsharingartifactsUploadbundleCall struct {
14946 s *Service
14947 packageName string
14948 urlParams_ gensupport.URLParams
14949 mediaInfo_ *gensupport.MediaInfo
14950 ctx_ context.Context
14951 header_ http.Header
14952 }
14953
14954
14955
14956
14957
14958
14959
14960
14961
14962 func (r *InternalappsharingartifactsService) Uploadbundle(packageName string) *InternalappsharingartifactsUploadbundleCall {
14963 c := &InternalappsharingartifactsUploadbundleCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14964 c.packageName = packageName
14965 return c
14966 }
14967
14968
14969
14970
14971
14972
14973
14974
14975 func (c *InternalappsharingartifactsUploadbundleCall) Media(r io.Reader, options ...googleapi.MediaOption) *InternalappsharingartifactsUploadbundleCall {
14976 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
14977 return c
14978 }
14979
14980
14981
14982
14983
14984
14985
14986
14987
14988
14989 func (c *InternalappsharingartifactsUploadbundleCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *InternalappsharingartifactsUploadbundleCall {
14990 c.ctx_ = ctx
14991 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
14992 return c
14993 }
14994
14995
14996
14997
14998
14999 func (c *InternalappsharingartifactsUploadbundleCall) ProgressUpdater(pu googleapi.ProgressUpdater) *InternalappsharingartifactsUploadbundleCall {
15000 c.mediaInfo_.SetProgressUpdater(pu)
15001 return c
15002 }
15003
15004
15005
15006
15007 func (c *InternalappsharingartifactsUploadbundleCall) Fields(s ...googleapi.Field) *InternalappsharingartifactsUploadbundleCall {
15008 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15009 return c
15010 }
15011
15012
15013
15014
15015 func (c *InternalappsharingartifactsUploadbundleCall) Context(ctx context.Context) *InternalappsharingartifactsUploadbundleCall {
15016 c.ctx_ = ctx
15017 return c
15018 }
15019
15020
15021
15022 func (c *InternalappsharingartifactsUploadbundleCall) Header() http.Header {
15023 if c.header_ == nil {
15024 c.header_ = make(http.Header)
15025 }
15026 return c.header_
15027 }
15028
15029 func (c *InternalappsharingartifactsUploadbundleCall) doRequest(alt string) (*http.Response, error) {
15030 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
15031 var body io.Reader = nil
15032 c.urlParams_.Set("alt", alt)
15033 c.urlParams_.Set("prettyPrint", "false")
15034 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/bundle")
15035 if c.mediaInfo_ != nil {
15036 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/bundle")
15037 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
15038 }
15039 if body == nil {
15040 body = new(bytes.Buffer)
15041 reqHeaders.Set("Content-Type", "application/json")
15042 }
15043 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
15044 defer cleanup()
15045 urls += "?" + c.urlParams_.Encode()
15046 req, err := http.NewRequest("POST", urls, body)
15047 if err != nil {
15048 return nil, err
15049 }
15050 req.Header = reqHeaders
15051 req.GetBody = getBody
15052 googleapi.Expand(req.URL, map[string]string{
15053 "packageName": c.packageName,
15054 })
15055 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15056 }
15057
15058
15059
15060
15061
15062
15063
15064 func (c *InternalappsharingartifactsUploadbundleCall) Do(opts ...googleapi.CallOption) (*InternalAppSharingArtifact, error) {
15065 gensupport.SetOptions(c.urlParams_, opts...)
15066 res, err := c.doRequest("json")
15067 if res != nil && res.StatusCode == http.StatusNotModified {
15068 if res.Body != nil {
15069 res.Body.Close()
15070 }
15071 return nil, gensupport.WrapError(&googleapi.Error{
15072 Code: res.StatusCode,
15073 Header: res.Header,
15074 })
15075 }
15076 if err != nil {
15077 return nil, err
15078 }
15079 defer googleapi.CloseBody(res)
15080 if err := googleapi.CheckResponse(res); err != nil {
15081 return nil, gensupport.WrapError(err)
15082 }
15083 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
15084 if rx != nil {
15085 rx.Client = c.s.client
15086 rx.UserAgent = c.s.userAgent()
15087 ctx := c.ctx_
15088 if ctx == nil {
15089 ctx = context.TODO()
15090 }
15091 res, err = rx.Upload(ctx)
15092 if err != nil {
15093 return nil, err
15094 }
15095 defer res.Body.Close()
15096 if err := googleapi.CheckResponse(res); err != nil {
15097 return nil, gensupport.WrapError(err)
15098 }
15099 }
15100 ret := &InternalAppSharingArtifact{
15101 ServerResponse: googleapi.ServerResponse{
15102 Header: res.Header,
15103 HTTPStatusCode: res.StatusCode,
15104 },
15105 }
15106 target := &ret
15107 if err := gensupport.DecodeResponse(target, res); err != nil {
15108 return nil, err
15109 }
15110 return ret, nil
15111 }
15112
15113 type MonetizationConvertRegionPricesCall struct {
15114 s *Service
15115 packageName string
15116 convertregionpricesrequest *ConvertRegionPricesRequest
15117 urlParams_ gensupport.URLParams
15118 ctx_ context.Context
15119 header_ http.Header
15120 }
15121
15122
15123
15124
15125
15126
15127 func (r *MonetizationService) ConvertRegionPrices(packageName string, convertregionpricesrequest *ConvertRegionPricesRequest) *MonetizationConvertRegionPricesCall {
15128 c := &MonetizationConvertRegionPricesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15129 c.packageName = packageName
15130 c.convertregionpricesrequest = convertregionpricesrequest
15131 return c
15132 }
15133
15134
15135
15136
15137 func (c *MonetizationConvertRegionPricesCall) Fields(s ...googleapi.Field) *MonetizationConvertRegionPricesCall {
15138 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15139 return c
15140 }
15141
15142
15143 func (c *MonetizationConvertRegionPricesCall) Context(ctx context.Context) *MonetizationConvertRegionPricesCall {
15144 c.ctx_ = ctx
15145 return c
15146 }
15147
15148
15149
15150 func (c *MonetizationConvertRegionPricesCall) Header() http.Header {
15151 if c.header_ == nil {
15152 c.header_ = make(http.Header)
15153 }
15154 return c.header_
15155 }
15156
15157 func (c *MonetizationConvertRegionPricesCall) doRequest(alt string) (*http.Response, error) {
15158 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
15159 var body io.Reader = nil
15160 body, err := googleapi.WithoutDataWrapper.JSONReader(c.convertregionpricesrequest)
15161 if err != nil {
15162 return nil, err
15163 }
15164 c.urlParams_.Set("alt", alt)
15165 c.urlParams_.Set("prettyPrint", "false")
15166 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/pricing:convertRegionPrices")
15167 urls += "?" + c.urlParams_.Encode()
15168 req, err := http.NewRequest("POST", urls, body)
15169 if err != nil {
15170 return nil, err
15171 }
15172 req.Header = reqHeaders
15173 googleapi.Expand(req.URL, map[string]string{
15174 "packageName": c.packageName,
15175 })
15176 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15177 }
15178
15179
15180
15181
15182
15183
15184
15185 func (c *MonetizationConvertRegionPricesCall) Do(opts ...googleapi.CallOption) (*ConvertRegionPricesResponse, error) {
15186 gensupport.SetOptions(c.urlParams_, opts...)
15187 res, err := c.doRequest("json")
15188 if res != nil && res.StatusCode == http.StatusNotModified {
15189 if res.Body != nil {
15190 res.Body.Close()
15191 }
15192 return nil, gensupport.WrapError(&googleapi.Error{
15193 Code: res.StatusCode,
15194 Header: res.Header,
15195 })
15196 }
15197 if err != nil {
15198 return nil, err
15199 }
15200 defer googleapi.CloseBody(res)
15201 if err := googleapi.CheckResponse(res); err != nil {
15202 return nil, gensupport.WrapError(err)
15203 }
15204 ret := &ConvertRegionPricesResponse{
15205 ServerResponse: googleapi.ServerResponse{
15206 Header: res.Header,
15207 HTTPStatusCode: res.StatusCode,
15208 },
15209 }
15210 target := &ret
15211 if err := gensupport.DecodeResponse(target, res); err != nil {
15212 return nil, err
15213 }
15214 return ret, nil
15215 }
15216
15217 type MonetizationSubscriptionsArchiveCall struct {
15218 s *Service
15219 packageName string
15220 productId string
15221 archivesubscriptionrequest *ArchiveSubscriptionRequest
15222 urlParams_ gensupport.URLParams
15223 ctx_ context.Context
15224 header_ http.Header
15225 }
15226
15227
15228
15229
15230
15231
15232 func (r *MonetizationSubscriptionsService) Archive(packageName string, productId string, archivesubscriptionrequest *ArchiveSubscriptionRequest) *MonetizationSubscriptionsArchiveCall {
15233 c := &MonetizationSubscriptionsArchiveCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15234 c.packageName = packageName
15235 c.productId = productId
15236 c.archivesubscriptionrequest = archivesubscriptionrequest
15237 return c
15238 }
15239
15240
15241
15242
15243 func (c *MonetizationSubscriptionsArchiveCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsArchiveCall {
15244 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15245 return c
15246 }
15247
15248
15249 func (c *MonetizationSubscriptionsArchiveCall) Context(ctx context.Context) *MonetizationSubscriptionsArchiveCall {
15250 c.ctx_ = ctx
15251 return c
15252 }
15253
15254
15255
15256 func (c *MonetizationSubscriptionsArchiveCall) Header() http.Header {
15257 if c.header_ == nil {
15258 c.header_ = make(http.Header)
15259 }
15260 return c.header_
15261 }
15262
15263 func (c *MonetizationSubscriptionsArchiveCall) doRequest(alt string) (*http.Response, error) {
15264 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
15265 var body io.Reader = nil
15266 body, err := googleapi.WithoutDataWrapper.JSONReader(c.archivesubscriptionrequest)
15267 if err != nil {
15268 return nil, err
15269 }
15270 c.urlParams_.Set("alt", alt)
15271 c.urlParams_.Set("prettyPrint", "false")
15272 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}:archive")
15273 urls += "?" + c.urlParams_.Encode()
15274 req, err := http.NewRequest("POST", urls, body)
15275 if err != nil {
15276 return nil, err
15277 }
15278 req.Header = reqHeaders
15279 googleapi.Expand(req.URL, map[string]string{
15280 "packageName": c.packageName,
15281 "productId": c.productId,
15282 })
15283 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15284 }
15285
15286
15287
15288
15289
15290
15291 func (c *MonetizationSubscriptionsArchiveCall) Do(opts ...googleapi.CallOption) (*Subscription, error) {
15292 gensupport.SetOptions(c.urlParams_, opts...)
15293 res, err := c.doRequest("json")
15294 if res != nil && res.StatusCode == http.StatusNotModified {
15295 if res.Body != nil {
15296 res.Body.Close()
15297 }
15298 return nil, gensupport.WrapError(&googleapi.Error{
15299 Code: res.StatusCode,
15300 Header: res.Header,
15301 })
15302 }
15303 if err != nil {
15304 return nil, err
15305 }
15306 defer googleapi.CloseBody(res)
15307 if err := googleapi.CheckResponse(res); err != nil {
15308 return nil, gensupport.WrapError(err)
15309 }
15310 ret := &Subscription{
15311 ServerResponse: googleapi.ServerResponse{
15312 Header: res.Header,
15313 HTTPStatusCode: res.StatusCode,
15314 },
15315 }
15316 target := &ret
15317 if err := gensupport.DecodeResponse(target, res); err != nil {
15318 return nil, err
15319 }
15320 return ret, nil
15321 }
15322
15323 type MonetizationSubscriptionsBatchGetCall struct {
15324 s *Service
15325 packageName string
15326 urlParams_ gensupport.URLParams
15327 ifNoneMatch_ string
15328 ctx_ context.Context
15329 header_ http.Header
15330 }
15331
15332
15333
15334
15335
15336
15337 func (r *MonetizationSubscriptionsService) BatchGet(packageName string) *MonetizationSubscriptionsBatchGetCall {
15338 c := &MonetizationSubscriptionsBatchGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15339 c.packageName = packageName
15340 return c
15341 }
15342
15343
15344
15345 func (c *MonetizationSubscriptionsBatchGetCall) ProductIds(productIds ...string) *MonetizationSubscriptionsBatchGetCall {
15346 c.urlParams_.SetMulti("productIds", append([]string{}, productIds...))
15347 return c
15348 }
15349
15350
15351
15352
15353 func (c *MonetizationSubscriptionsBatchGetCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBatchGetCall {
15354 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15355 return c
15356 }
15357
15358
15359
15360
15361 func (c *MonetizationSubscriptionsBatchGetCall) IfNoneMatch(entityTag string) *MonetizationSubscriptionsBatchGetCall {
15362 c.ifNoneMatch_ = entityTag
15363 return c
15364 }
15365
15366
15367 func (c *MonetizationSubscriptionsBatchGetCall) Context(ctx context.Context) *MonetizationSubscriptionsBatchGetCall {
15368 c.ctx_ = ctx
15369 return c
15370 }
15371
15372
15373
15374 func (c *MonetizationSubscriptionsBatchGetCall) Header() http.Header {
15375 if c.header_ == nil {
15376 c.header_ = make(http.Header)
15377 }
15378 return c.header_
15379 }
15380
15381 func (c *MonetizationSubscriptionsBatchGetCall) doRequest(alt string) (*http.Response, error) {
15382 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
15383 if c.ifNoneMatch_ != "" {
15384 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15385 }
15386 var body io.Reader = nil
15387 c.urlParams_.Set("alt", alt)
15388 c.urlParams_.Set("prettyPrint", "false")
15389 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions:batchGet")
15390 urls += "?" + c.urlParams_.Encode()
15391 req, err := http.NewRequest("GET", urls, body)
15392 if err != nil {
15393 return nil, err
15394 }
15395 req.Header = reqHeaders
15396 googleapi.Expand(req.URL, map[string]string{
15397 "packageName": c.packageName,
15398 })
15399 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15400 }
15401
15402
15403
15404
15405
15406
15407
15408 func (c *MonetizationSubscriptionsBatchGetCall) Do(opts ...googleapi.CallOption) (*BatchGetSubscriptionsResponse, error) {
15409 gensupport.SetOptions(c.urlParams_, opts...)
15410 res, err := c.doRequest("json")
15411 if res != nil && res.StatusCode == http.StatusNotModified {
15412 if res.Body != nil {
15413 res.Body.Close()
15414 }
15415 return nil, gensupport.WrapError(&googleapi.Error{
15416 Code: res.StatusCode,
15417 Header: res.Header,
15418 })
15419 }
15420 if err != nil {
15421 return nil, err
15422 }
15423 defer googleapi.CloseBody(res)
15424 if err := googleapi.CheckResponse(res); err != nil {
15425 return nil, gensupport.WrapError(err)
15426 }
15427 ret := &BatchGetSubscriptionsResponse{
15428 ServerResponse: googleapi.ServerResponse{
15429 Header: res.Header,
15430 HTTPStatusCode: res.StatusCode,
15431 },
15432 }
15433 target := &ret
15434 if err := gensupport.DecodeResponse(target, res); err != nil {
15435 return nil, err
15436 }
15437 return ret, nil
15438 }
15439
15440 type MonetizationSubscriptionsBatchUpdateCall struct {
15441 s *Service
15442 packageName string
15443 batchupdatesubscriptionsrequest *BatchUpdateSubscriptionsRequest
15444 urlParams_ gensupport.URLParams
15445 ctx_ context.Context
15446 header_ http.Header
15447 }
15448
15449
15450
15451
15452
15453
15454
15455
15456
15457 func (r *MonetizationSubscriptionsService) BatchUpdate(packageName string, batchupdatesubscriptionsrequest *BatchUpdateSubscriptionsRequest) *MonetizationSubscriptionsBatchUpdateCall {
15458 c := &MonetizationSubscriptionsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15459 c.packageName = packageName
15460 c.batchupdatesubscriptionsrequest = batchupdatesubscriptionsrequest
15461 return c
15462 }
15463
15464
15465
15466
15467 func (c *MonetizationSubscriptionsBatchUpdateCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBatchUpdateCall {
15468 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15469 return c
15470 }
15471
15472
15473 func (c *MonetizationSubscriptionsBatchUpdateCall) Context(ctx context.Context) *MonetizationSubscriptionsBatchUpdateCall {
15474 c.ctx_ = ctx
15475 return c
15476 }
15477
15478
15479
15480 func (c *MonetizationSubscriptionsBatchUpdateCall) Header() http.Header {
15481 if c.header_ == nil {
15482 c.header_ = make(http.Header)
15483 }
15484 return c.header_
15485 }
15486
15487 func (c *MonetizationSubscriptionsBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
15488 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
15489 var body io.Reader = nil
15490 body, err := googleapi.WithoutDataWrapper.JSONReader(c.batchupdatesubscriptionsrequest)
15491 if err != nil {
15492 return nil, err
15493 }
15494 c.urlParams_.Set("alt", alt)
15495 c.urlParams_.Set("prettyPrint", "false")
15496 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions:batchUpdate")
15497 urls += "?" + c.urlParams_.Encode()
15498 req, err := http.NewRequest("POST", urls, body)
15499 if err != nil {
15500 return nil, err
15501 }
15502 req.Header = reqHeaders
15503 googleapi.Expand(req.URL, map[string]string{
15504 "packageName": c.packageName,
15505 })
15506 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15507 }
15508
15509
15510
15511
15512
15513
15514
15515 func (c *MonetizationSubscriptionsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*BatchUpdateSubscriptionsResponse, error) {
15516 gensupport.SetOptions(c.urlParams_, opts...)
15517 res, err := c.doRequest("json")
15518 if res != nil && res.StatusCode == http.StatusNotModified {
15519 if res.Body != nil {
15520 res.Body.Close()
15521 }
15522 return nil, gensupport.WrapError(&googleapi.Error{
15523 Code: res.StatusCode,
15524 Header: res.Header,
15525 })
15526 }
15527 if err != nil {
15528 return nil, err
15529 }
15530 defer googleapi.CloseBody(res)
15531 if err := googleapi.CheckResponse(res); err != nil {
15532 return nil, gensupport.WrapError(err)
15533 }
15534 ret := &BatchUpdateSubscriptionsResponse{
15535 ServerResponse: googleapi.ServerResponse{
15536 Header: res.Header,
15537 HTTPStatusCode: res.StatusCode,
15538 },
15539 }
15540 target := &ret
15541 if err := gensupport.DecodeResponse(target, res); err != nil {
15542 return nil, err
15543 }
15544 return ret, nil
15545 }
15546
15547 type MonetizationSubscriptionsCreateCall struct {
15548 s *Service
15549 packageName string
15550 subscription *Subscription
15551 urlParams_ gensupport.URLParams
15552 ctx_ context.Context
15553 header_ http.Header
15554 }
15555
15556
15557
15558
15559
15560
15561
15562 func (r *MonetizationSubscriptionsService) Create(packageName string, subscription *Subscription) *MonetizationSubscriptionsCreateCall {
15563 c := &MonetizationSubscriptionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15564 c.packageName = packageName
15565 c.subscription = subscription
15566 return c
15567 }
15568
15569
15570
15571
15572 func (c *MonetizationSubscriptionsCreateCall) ProductId(productId string) *MonetizationSubscriptionsCreateCall {
15573 c.urlParams_.Set("productId", productId)
15574 return c
15575 }
15576
15577
15578
15579
15580
15581
15582
15583
15584
15585
15586
15587 func (c *MonetizationSubscriptionsCreateCall) RegionsVersionVersion(regionsVersionVersion string) *MonetizationSubscriptionsCreateCall {
15588 c.urlParams_.Set("regionsVersion.version", regionsVersionVersion)
15589 return c
15590 }
15591
15592
15593
15594
15595 func (c *MonetizationSubscriptionsCreateCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsCreateCall {
15596 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15597 return c
15598 }
15599
15600
15601 func (c *MonetizationSubscriptionsCreateCall) Context(ctx context.Context) *MonetizationSubscriptionsCreateCall {
15602 c.ctx_ = ctx
15603 return c
15604 }
15605
15606
15607
15608 func (c *MonetizationSubscriptionsCreateCall) Header() http.Header {
15609 if c.header_ == nil {
15610 c.header_ = make(http.Header)
15611 }
15612 return c.header_
15613 }
15614
15615 func (c *MonetizationSubscriptionsCreateCall) doRequest(alt string) (*http.Response, error) {
15616 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
15617 var body io.Reader = nil
15618 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subscription)
15619 if err != nil {
15620 return nil, err
15621 }
15622 c.urlParams_.Set("alt", alt)
15623 c.urlParams_.Set("prettyPrint", "false")
15624 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions")
15625 urls += "?" + c.urlParams_.Encode()
15626 req, err := http.NewRequest("POST", urls, body)
15627 if err != nil {
15628 return nil, err
15629 }
15630 req.Header = reqHeaders
15631 googleapi.Expand(req.URL, map[string]string{
15632 "packageName": c.packageName,
15633 })
15634 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15635 }
15636
15637
15638
15639
15640
15641
15642 func (c *MonetizationSubscriptionsCreateCall) Do(opts ...googleapi.CallOption) (*Subscription, error) {
15643 gensupport.SetOptions(c.urlParams_, opts...)
15644 res, err := c.doRequest("json")
15645 if res != nil && res.StatusCode == http.StatusNotModified {
15646 if res.Body != nil {
15647 res.Body.Close()
15648 }
15649 return nil, gensupport.WrapError(&googleapi.Error{
15650 Code: res.StatusCode,
15651 Header: res.Header,
15652 })
15653 }
15654 if err != nil {
15655 return nil, err
15656 }
15657 defer googleapi.CloseBody(res)
15658 if err := googleapi.CheckResponse(res); err != nil {
15659 return nil, gensupport.WrapError(err)
15660 }
15661 ret := &Subscription{
15662 ServerResponse: googleapi.ServerResponse{
15663 Header: res.Header,
15664 HTTPStatusCode: res.StatusCode,
15665 },
15666 }
15667 target := &ret
15668 if err := gensupport.DecodeResponse(target, res); err != nil {
15669 return nil, err
15670 }
15671 return ret, nil
15672 }
15673
15674 type MonetizationSubscriptionsDeleteCall struct {
15675 s *Service
15676 packageName string
15677 productId string
15678 urlParams_ gensupport.URLParams
15679 ctx_ context.Context
15680 header_ http.Header
15681 }
15682
15683
15684
15685
15686
15687
15688
15689 func (r *MonetizationSubscriptionsService) Delete(packageName string, productId string) *MonetizationSubscriptionsDeleteCall {
15690 c := &MonetizationSubscriptionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15691 c.packageName = packageName
15692 c.productId = productId
15693 return c
15694 }
15695
15696
15697
15698
15699 func (c *MonetizationSubscriptionsDeleteCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsDeleteCall {
15700 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15701 return c
15702 }
15703
15704
15705 func (c *MonetizationSubscriptionsDeleteCall) Context(ctx context.Context) *MonetizationSubscriptionsDeleteCall {
15706 c.ctx_ = ctx
15707 return c
15708 }
15709
15710
15711
15712 func (c *MonetizationSubscriptionsDeleteCall) Header() http.Header {
15713 if c.header_ == nil {
15714 c.header_ = make(http.Header)
15715 }
15716 return c.header_
15717 }
15718
15719 func (c *MonetizationSubscriptionsDeleteCall) doRequest(alt string) (*http.Response, error) {
15720 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
15721 var body io.Reader = nil
15722 c.urlParams_.Set("alt", alt)
15723 c.urlParams_.Set("prettyPrint", "false")
15724 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}")
15725 urls += "?" + c.urlParams_.Encode()
15726 req, err := http.NewRequest("DELETE", urls, body)
15727 if err != nil {
15728 return nil, err
15729 }
15730 req.Header = reqHeaders
15731 googleapi.Expand(req.URL, map[string]string{
15732 "packageName": c.packageName,
15733 "productId": c.productId,
15734 })
15735 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15736 }
15737
15738
15739 func (c *MonetizationSubscriptionsDeleteCall) Do(opts ...googleapi.CallOption) error {
15740 gensupport.SetOptions(c.urlParams_, opts...)
15741 res, err := c.doRequest("json")
15742 if err != nil {
15743 return err
15744 }
15745 defer googleapi.CloseBody(res)
15746 if err := googleapi.CheckResponse(res); err != nil {
15747 return gensupport.WrapError(err)
15748 }
15749 return nil
15750 }
15751
15752 type MonetizationSubscriptionsGetCall struct {
15753 s *Service
15754 packageName string
15755 productId string
15756 urlParams_ gensupport.URLParams
15757 ifNoneMatch_ string
15758 ctx_ context.Context
15759 header_ http.Header
15760 }
15761
15762
15763
15764
15765
15766 func (r *MonetizationSubscriptionsService) Get(packageName string, productId string) *MonetizationSubscriptionsGetCall {
15767 c := &MonetizationSubscriptionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15768 c.packageName = packageName
15769 c.productId = productId
15770 return c
15771 }
15772
15773
15774
15775
15776 func (c *MonetizationSubscriptionsGetCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsGetCall {
15777 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15778 return c
15779 }
15780
15781
15782
15783
15784 func (c *MonetizationSubscriptionsGetCall) IfNoneMatch(entityTag string) *MonetizationSubscriptionsGetCall {
15785 c.ifNoneMatch_ = entityTag
15786 return c
15787 }
15788
15789
15790 func (c *MonetizationSubscriptionsGetCall) Context(ctx context.Context) *MonetizationSubscriptionsGetCall {
15791 c.ctx_ = ctx
15792 return c
15793 }
15794
15795
15796
15797 func (c *MonetizationSubscriptionsGetCall) Header() http.Header {
15798 if c.header_ == nil {
15799 c.header_ = make(http.Header)
15800 }
15801 return c.header_
15802 }
15803
15804 func (c *MonetizationSubscriptionsGetCall) doRequest(alt string) (*http.Response, error) {
15805 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
15806 if c.ifNoneMatch_ != "" {
15807 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15808 }
15809 var body io.Reader = nil
15810 c.urlParams_.Set("alt", alt)
15811 c.urlParams_.Set("prettyPrint", "false")
15812 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}")
15813 urls += "?" + c.urlParams_.Encode()
15814 req, err := http.NewRequest("GET", urls, body)
15815 if err != nil {
15816 return nil, err
15817 }
15818 req.Header = reqHeaders
15819 googleapi.Expand(req.URL, map[string]string{
15820 "packageName": c.packageName,
15821 "productId": c.productId,
15822 })
15823 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15824 }
15825
15826
15827
15828
15829
15830
15831 func (c *MonetizationSubscriptionsGetCall) Do(opts ...googleapi.CallOption) (*Subscription, error) {
15832 gensupport.SetOptions(c.urlParams_, opts...)
15833 res, err := c.doRequest("json")
15834 if res != nil && res.StatusCode == http.StatusNotModified {
15835 if res.Body != nil {
15836 res.Body.Close()
15837 }
15838 return nil, gensupport.WrapError(&googleapi.Error{
15839 Code: res.StatusCode,
15840 Header: res.Header,
15841 })
15842 }
15843 if err != nil {
15844 return nil, err
15845 }
15846 defer googleapi.CloseBody(res)
15847 if err := googleapi.CheckResponse(res); err != nil {
15848 return nil, gensupport.WrapError(err)
15849 }
15850 ret := &Subscription{
15851 ServerResponse: googleapi.ServerResponse{
15852 Header: res.Header,
15853 HTTPStatusCode: res.StatusCode,
15854 },
15855 }
15856 target := &ret
15857 if err := gensupport.DecodeResponse(target, res); err != nil {
15858 return nil, err
15859 }
15860 return ret, nil
15861 }
15862
15863 type MonetizationSubscriptionsListCall struct {
15864 s *Service
15865 packageName string
15866 urlParams_ gensupport.URLParams
15867 ifNoneMatch_ string
15868 ctx_ context.Context
15869 header_ http.Header
15870 }
15871
15872
15873
15874
15875
15876 func (r *MonetizationSubscriptionsService) List(packageName string) *MonetizationSubscriptionsListCall {
15877 c := &MonetizationSubscriptionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15878 c.packageName = packageName
15879 return c
15880 }
15881
15882
15883
15884
15885
15886 func (c *MonetizationSubscriptionsListCall) PageSize(pageSize int64) *MonetizationSubscriptionsListCall {
15887 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
15888 return c
15889 }
15890
15891
15892
15893
15894
15895 func (c *MonetizationSubscriptionsListCall) PageToken(pageToken string) *MonetizationSubscriptionsListCall {
15896 c.urlParams_.Set("pageToken", pageToken)
15897 return c
15898 }
15899
15900
15901
15902 func (c *MonetizationSubscriptionsListCall) ShowArchived(showArchived bool) *MonetizationSubscriptionsListCall {
15903 c.urlParams_.Set("showArchived", fmt.Sprint(showArchived))
15904 return c
15905 }
15906
15907
15908
15909
15910 func (c *MonetizationSubscriptionsListCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsListCall {
15911 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15912 return c
15913 }
15914
15915
15916
15917
15918 func (c *MonetizationSubscriptionsListCall) IfNoneMatch(entityTag string) *MonetizationSubscriptionsListCall {
15919 c.ifNoneMatch_ = entityTag
15920 return c
15921 }
15922
15923
15924 func (c *MonetizationSubscriptionsListCall) Context(ctx context.Context) *MonetizationSubscriptionsListCall {
15925 c.ctx_ = ctx
15926 return c
15927 }
15928
15929
15930
15931 func (c *MonetizationSubscriptionsListCall) Header() http.Header {
15932 if c.header_ == nil {
15933 c.header_ = make(http.Header)
15934 }
15935 return c.header_
15936 }
15937
15938 func (c *MonetizationSubscriptionsListCall) doRequest(alt string) (*http.Response, error) {
15939 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
15940 if c.ifNoneMatch_ != "" {
15941 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15942 }
15943 var body io.Reader = nil
15944 c.urlParams_.Set("alt", alt)
15945 c.urlParams_.Set("prettyPrint", "false")
15946 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions")
15947 urls += "?" + c.urlParams_.Encode()
15948 req, err := http.NewRequest("GET", urls, body)
15949 if err != nil {
15950 return nil, err
15951 }
15952 req.Header = reqHeaders
15953 googleapi.Expand(req.URL, map[string]string{
15954 "packageName": c.packageName,
15955 })
15956 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15957 }
15958
15959
15960
15961
15962
15963
15964
15965 func (c *MonetizationSubscriptionsListCall) Do(opts ...googleapi.CallOption) (*ListSubscriptionsResponse, error) {
15966 gensupport.SetOptions(c.urlParams_, opts...)
15967 res, err := c.doRequest("json")
15968 if res != nil && res.StatusCode == http.StatusNotModified {
15969 if res.Body != nil {
15970 res.Body.Close()
15971 }
15972 return nil, gensupport.WrapError(&googleapi.Error{
15973 Code: res.StatusCode,
15974 Header: res.Header,
15975 })
15976 }
15977 if err != nil {
15978 return nil, err
15979 }
15980 defer googleapi.CloseBody(res)
15981 if err := googleapi.CheckResponse(res); err != nil {
15982 return nil, gensupport.WrapError(err)
15983 }
15984 ret := &ListSubscriptionsResponse{
15985 ServerResponse: googleapi.ServerResponse{
15986 Header: res.Header,
15987 HTTPStatusCode: res.StatusCode,
15988 },
15989 }
15990 target := &ret
15991 if err := gensupport.DecodeResponse(target, res); err != nil {
15992 return nil, err
15993 }
15994 return ret, nil
15995 }
15996
15997
15998
15999
16000 func (c *MonetizationSubscriptionsListCall) Pages(ctx context.Context, f func(*ListSubscriptionsResponse) error) error {
16001 c.ctx_ = ctx
16002 defer c.PageToken(c.urlParams_.Get("pageToken"))
16003 for {
16004 x, err := c.Do()
16005 if err != nil {
16006 return err
16007 }
16008 if err := f(x); err != nil {
16009 return err
16010 }
16011 if x.NextPageToken == "" {
16012 return nil
16013 }
16014 c.PageToken(x.NextPageToken)
16015 }
16016 }
16017
16018 type MonetizationSubscriptionsPatchCall struct {
16019 s *Service
16020 packageName string
16021 productId string
16022 subscription *Subscription
16023 urlParams_ gensupport.URLParams
16024 ctx_ context.Context
16025 header_ http.Header
16026 }
16027
16028
16029
16030
16031
16032
16033
16034
16035
16036 func (r *MonetizationSubscriptionsService) Patch(packageName string, productId string, subscription *Subscription) *MonetizationSubscriptionsPatchCall {
16037 c := &MonetizationSubscriptionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16038 c.packageName = packageName
16039 c.productId = productId
16040 c.subscription = subscription
16041 return c
16042 }
16043
16044
16045
16046
16047
16048 func (c *MonetizationSubscriptionsPatchCall) AllowMissing(allowMissing bool) *MonetizationSubscriptionsPatchCall {
16049 c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing))
16050 return c
16051 }
16052
16053
16054
16055
16056
16057
16058
16059
16060
16061
16062
16063
16064
16065
16066
16067
16068
16069
16070
16071
16072 func (c *MonetizationSubscriptionsPatchCall) LatencyTolerance(latencyTolerance string) *MonetizationSubscriptionsPatchCall {
16073 c.urlParams_.Set("latencyTolerance", latencyTolerance)
16074 return c
16075 }
16076
16077
16078
16079
16080
16081
16082
16083
16084
16085
16086
16087 func (c *MonetizationSubscriptionsPatchCall) RegionsVersionVersion(regionsVersionVersion string) *MonetizationSubscriptionsPatchCall {
16088 c.urlParams_.Set("regionsVersion.version", regionsVersionVersion)
16089 return c
16090 }
16091
16092
16093
16094 func (c *MonetizationSubscriptionsPatchCall) UpdateMask(updateMask string) *MonetizationSubscriptionsPatchCall {
16095 c.urlParams_.Set("updateMask", updateMask)
16096 return c
16097 }
16098
16099
16100
16101
16102 func (c *MonetizationSubscriptionsPatchCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsPatchCall {
16103 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16104 return c
16105 }
16106
16107
16108 func (c *MonetizationSubscriptionsPatchCall) Context(ctx context.Context) *MonetizationSubscriptionsPatchCall {
16109 c.ctx_ = ctx
16110 return c
16111 }
16112
16113
16114
16115 func (c *MonetizationSubscriptionsPatchCall) Header() http.Header {
16116 if c.header_ == nil {
16117 c.header_ = make(http.Header)
16118 }
16119 return c.header_
16120 }
16121
16122 func (c *MonetizationSubscriptionsPatchCall) doRequest(alt string) (*http.Response, error) {
16123 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
16124 var body io.Reader = nil
16125 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subscription)
16126 if err != nil {
16127 return nil, err
16128 }
16129 c.urlParams_.Set("alt", alt)
16130 c.urlParams_.Set("prettyPrint", "false")
16131 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}")
16132 urls += "?" + c.urlParams_.Encode()
16133 req, err := http.NewRequest("PATCH", urls, body)
16134 if err != nil {
16135 return nil, err
16136 }
16137 req.Header = reqHeaders
16138 googleapi.Expand(req.URL, map[string]string{
16139 "packageName": c.packageName,
16140 "productId": c.productId,
16141 })
16142 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16143 }
16144
16145
16146
16147
16148
16149
16150 func (c *MonetizationSubscriptionsPatchCall) Do(opts ...googleapi.CallOption) (*Subscription, error) {
16151 gensupport.SetOptions(c.urlParams_, opts...)
16152 res, err := c.doRequest("json")
16153 if res != nil && res.StatusCode == http.StatusNotModified {
16154 if res.Body != nil {
16155 res.Body.Close()
16156 }
16157 return nil, gensupport.WrapError(&googleapi.Error{
16158 Code: res.StatusCode,
16159 Header: res.Header,
16160 })
16161 }
16162 if err != nil {
16163 return nil, err
16164 }
16165 defer googleapi.CloseBody(res)
16166 if err := googleapi.CheckResponse(res); err != nil {
16167 return nil, gensupport.WrapError(err)
16168 }
16169 ret := &Subscription{
16170 ServerResponse: googleapi.ServerResponse{
16171 Header: res.Header,
16172 HTTPStatusCode: res.StatusCode,
16173 },
16174 }
16175 target := &ret
16176 if err := gensupport.DecodeResponse(target, res); err != nil {
16177 return nil, err
16178 }
16179 return ret, nil
16180 }
16181
16182 type MonetizationSubscriptionsBasePlansActivateCall struct {
16183 s *Service
16184 packageName string
16185 productId string
16186 basePlanId string
16187 activatebaseplanrequest *ActivateBasePlanRequest
16188 urlParams_ gensupport.URLParams
16189 ctx_ context.Context
16190 header_ http.Header
16191 }
16192
16193
16194
16195
16196
16197
16198
16199 func (r *MonetizationSubscriptionsBasePlansService) Activate(packageName string, productId string, basePlanId string, activatebaseplanrequest *ActivateBasePlanRequest) *MonetizationSubscriptionsBasePlansActivateCall {
16200 c := &MonetizationSubscriptionsBasePlansActivateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16201 c.packageName = packageName
16202 c.productId = productId
16203 c.basePlanId = basePlanId
16204 c.activatebaseplanrequest = activatebaseplanrequest
16205 return c
16206 }
16207
16208
16209
16210
16211 func (c *MonetizationSubscriptionsBasePlansActivateCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansActivateCall {
16212 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16213 return c
16214 }
16215
16216
16217 func (c *MonetizationSubscriptionsBasePlansActivateCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansActivateCall {
16218 c.ctx_ = ctx
16219 return c
16220 }
16221
16222
16223
16224 func (c *MonetizationSubscriptionsBasePlansActivateCall) Header() http.Header {
16225 if c.header_ == nil {
16226 c.header_ = make(http.Header)
16227 }
16228 return c.header_
16229 }
16230
16231 func (c *MonetizationSubscriptionsBasePlansActivateCall) doRequest(alt string) (*http.Response, error) {
16232 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
16233 var body io.Reader = nil
16234 body, err := googleapi.WithoutDataWrapper.JSONReader(c.activatebaseplanrequest)
16235 if err != nil {
16236 return nil, err
16237 }
16238 c.urlParams_.Set("alt", alt)
16239 c.urlParams_.Set("prettyPrint", "false")
16240 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}:activate")
16241 urls += "?" + c.urlParams_.Encode()
16242 req, err := http.NewRequest("POST", urls, body)
16243 if err != nil {
16244 return nil, err
16245 }
16246 req.Header = reqHeaders
16247 googleapi.Expand(req.URL, map[string]string{
16248 "packageName": c.packageName,
16249 "productId": c.productId,
16250 "basePlanId": c.basePlanId,
16251 })
16252 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16253 }
16254
16255
16256
16257
16258
16259
16260 func (c *MonetizationSubscriptionsBasePlansActivateCall) Do(opts ...googleapi.CallOption) (*Subscription, error) {
16261 gensupport.SetOptions(c.urlParams_, opts...)
16262 res, err := c.doRequest("json")
16263 if res != nil && res.StatusCode == http.StatusNotModified {
16264 if res.Body != nil {
16265 res.Body.Close()
16266 }
16267 return nil, gensupport.WrapError(&googleapi.Error{
16268 Code: res.StatusCode,
16269 Header: res.Header,
16270 })
16271 }
16272 if err != nil {
16273 return nil, err
16274 }
16275 defer googleapi.CloseBody(res)
16276 if err := googleapi.CheckResponse(res); err != nil {
16277 return nil, gensupport.WrapError(err)
16278 }
16279 ret := &Subscription{
16280 ServerResponse: googleapi.ServerResponse{
16281 Header: res.Header,
16282 HTTPStatusCode: res.StatusCode,
16283 },
16284 }
16285 target := &ret
16286 if err := gensupport.DecodeResponse(target, res); err != nil {
16287 return nil, err
16288 }
16289 return ret, nil
16290 }
16291
16292 type MonetizationSubscriptionsBasePlansBatchMigratePricesCall struct {
16293 s *Service
16294 packageName string
16295 productId string
16296 batchmigratebaseplanpricesrequest *BatchMigrateBasePlanPricesRequest
16297 urlParams_ gensupport.URLParams
16298 ctx_ context.Context
16299 header_ http.Header
16300 }
16301
16302
16303
16304
16305
16306
16307
16308
16309
16310
16311
16312
16313 func (r *MonetizationSubscriptionsBasePlansService) BatchMigratePrices(packageName string, productId string, batchmigratebaseplanpricesrequest *BatchMigrateBasePlanPricesRequest) *MonetizationSubscriptionsBasePlansBatchMigratePricesCall {
16314 c := &MonetizationSubscriptionsBasePlansBatchMigratePricesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16315 c.packageName = packageName
16316 c.productId = productId
16317 c.batchmigratebaseplanpricesrequest = batchmigratebaseplanpricesrequest
16318 return c
16319 }
16320
16321
16322
16323
16324 func (c *MonetizationSubscriptionsBasePlansBatchMigratePricesCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansBatchMigratePricesCall {
16325 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16326 return c
16327 }
16328
16329
16330 func (c *MonetizationSubscriptionsBasePlansBatchMigratePricesCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansBatchMigratePricesCall {
16331 c.ctx_ = ctx
16332 return c
16333 }
16334
16335
16336
16337 func (c *MonetizationSubscriptionsBasePlansBatchMigratePricesCall) Header() http.Header {
16338 if c.header_ == nil {
16339 c.header_ = make(http.Header)
16340 }
16341 return c.header_
16342 }
16343
16344 func (c *MonetizationSubscriptionsBasePlansBatchMigratePricesCall) doRequest(alt string) (*http.Response, error) {
16345 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
16346 var body io.Reader = nil
16347 body, err := googleapi.WithoutDataWrapper.JSONReader(c.batchmigratebaseplanpricesrequest)
16348 if err != nil {
16349 return nil, err
16350 }
16351 c.urlParams_.Set("alt", alt)
16352 c.urlParams_.Set("prettyPrint", "false")
16353 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans:batchMigratePrices")
16354 urls += "?" + c.urlParams_.Encode()
16355 req, err := http.NewRequest("POST", urls, body)
16356 if err != nil {
16357 return nil, err
16358 }
16359 req.Header = reqHeaders
16360 googleapi.Expand(req.URL, map[string]string{
16361 "packageName": c.packageName,
16362 "productId": c.productId,
16363 })
16364 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16365 }
16366
16367
16368
16369
16370
16371
16372
16373 func (c *MonetizationSubscriptionsBasePlansBatchMigratePricesCall) Do(opts ...googleapi.CallOption) (*BatchMigrateBasePlanPricesResponse, error) {
16374 gensupport.SetOptions(c.urlParams_, opts...)
16375 res, err := c.doRequest("json")
16376 if res != nil && res.StatusCode == http.StatusNotModified {
16377 if res.Body != nil {
16378 res.Body.Close()
16379 }
16380 return nil, gensupport.WrapError(&googleapi.Error{
16381 Code: res.StatusCode,
16382 Header: res.Header,
16383 })
16384 }
16385 if err != nil {
16386 return nil, err
16387 }
16388 defer googleapi.CloseBody(res)
16389 if err := googleapi.CheckResponse(res); err != nil {
16390 return nil, gensupport.WrapError(err)
16391 }
16392 ret := &BatchMigrateBasePlanPricesResponse{
16393 ServerResponse: googleapi.ServerResponse{
16394 Header: res.Header,
16395 HTTPStatusCode: res.StatusCode,
16396 },
16397 }
16398 target := &ret
16399 if err := gensupport.DecodeResponse(target, res); err != nil {
16400 return nil, err
16401 }
16402 return ret, nil
16403 }
16404
16405 type MonetizationSubscriptionsBasePlansBatchUpdateStatesCall struct {
16406 s *Service
16407 packageName string
16408 productId string
16409 batchupdatebaseplanstatesrequest *BatchUpdateBasePlanStatesRequest
16410 urlParams_ gensupport.URLParams
16411 ctx_ context.Context
16412 header_ http.Header
16413 }
16414
16415
16416
16417
16418
16419
16420
16421
16422
16423
16424 func (r *MonetizationSubscriptionsBasePlansService) BatchUpdateStates(packageName string, productId string, batchupdatebaseplanstatesrequest *BatchUpdateBasePlanStatesRequest) *MonetizationSubscriptionsBasePlansBatchUpdateStatesCall {
16425 c := &MonetizationSubscriptionsBasePlansBatchUpdateStatesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16426 c.packageName = packageName
16427 c.productId = productId
16428 c.batchupdatebaseplanstatesrequest = batchupdatebaseplanstatesrequest
16429 return c
16430 }
16431
16432
16433
16434
16435 func (c *MonetizationSubscriptionsBasePlansBatchUpdateStatesCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansBatchUpdateStatesCall {
16436 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16437 return c
16438 }
16439
16440
16441 func (c *MonetizationSubscriptionsBasePlansBatchUpdateStatesCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansBatchUpdateStatesCall {
16442 c.ctx_ = ctx
16443 return c
16444 }
16445
16446
16447
16448 func (c *MonetizationSubscriptionsBasePlansBatchUpdateStatesCall) Header() http.Header {
16449 if c.header_ == nil {
16450 c.header_ = make(http.Header)
16451 }
16452 return c.header_
16453 }
16454
16455 func (c *MonetizationSubscriptionsBasePlansBatchUpdateStatesCall) doRequest(alt string) (*http.Response, error) {
16456 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
16457 var body io.Reader = nil
16458 body, err := googleapi.WithoutDataWrapper.JSONReader(c.batchupdatebaseplanstatesrequest)
16459 if err != nil {
16460 return nil, err
16461 }
16462 c.urlParams_.Set("alt", alt)
16463 c.urlParams_.Set("prettyPrint", "false")
16464 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans:batchUpdateStates")
16465 urls += "?" + c.urlParams_.Encode()
16466 req, err := http.NewRequest("POST", urls, body)
16467 if err != nil {
16468 return nil, err
16469 }
16470 req.Header = reqHeaders
16471 googleapi.Expand(req.URL, map[string]string{
16472 "packageName": c.packageName,
16473 "productId": c.productId,
16474 })
16475 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16476 }
16477
16478
16479
16480
16481
16482
16483
16484 func (c *MonetizationSubscriptionsBasePlansBatchUpdateStatesCall) Do(opts ...googleapi.CallOption) (*BatchUpdateBasePlanStatesResponse, error) {
16485 gensupport.SetOptions(c.urlParams_, opts...)
16486 res, err := c.doRequest("json")
16487 if res != nil && res.StatusCode == http.StatusNotModified {
16488 if res.Body != nil {
16489 res.Body.Close()
16490 }
16491 return nil, gensupport.WrapError(&googleapi.Error{
16492 Code: res.StatusCode,
16493 Header: res.Header,
16494 })
16495 }
16496 if err != nil {
16497 return nil, err
16498 }
16499 defer googleapi.CloseBody(res)
16500 if err := googleapi.CheckResponse(res); err != nil {
16501 return nil, gensupport.WrapError(err)
16502 }
16503 ret := &BatchUpdateBasePlanStatesResponse{
16504 ServerResponse: googleapi.ServerResponse{
16505 Header: res.Header,
16506 HTTPStatusCode: res.StatusCode,
16507 },
16508 }
16509 target := &ret
16510 if err := gensupport.DecodeResponse(target, res); err != nil {
16511 return nil, err
16512 }
16513 return ret, nil
16514 }
16515
16516 type MonetizationSubscriptionsBasePlansDeactivateCall struct {
16517 s *Service
16518 packageName string
16519 productId string
16520 basePlanId string
16521 deactivatebaseplanrequest *DeactivateBasePlanRequest
16522 urlParams_ gensupport.URLParams
16523 ctx_ context.Context
16524 header_ http.Header
16525 }
16526
16527
16528
16529
16530
16531
16532
16533
16534 func (r *MonetizationSubscriptionsBasePlansService) Deactivate(packageName string, productId string, basePlanId string, deactivatebaseplanrequest *DeactivateBasePlanRequest) *MonetizationSubscriptionsBasePlansDeactivateCall {
16535 c := &MonetizationSubscriptionsBasePlansDeactivateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16536 c.packageName = packageName
16537 c.productId = productId
16538 c.basePlanId = basePlanId
16539 c.deactivatebaseplanrequest = deactivatebaseplanrequest
16540 return c
16541 }
16542
16543
16544
16545
16546 func (c *MonetizationSubscriptionsBasePlansDeactivateCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansDeactivateCall {
16547 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16548 return c
16549 }
16550
16551
16552 func (c *MonetizationSubscriptionsBasePlansDeactivateCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansDeactivateCall {
16553 c.ctx_ = ctx
16554 return c
16555 }
16556
16557
16558
16559 func (c *MonetizationSubscriptionsBasePlansDeactivateCall) Header() http.Header {
16560 if c.header_ == nil {
16561 c.header_ = make(http.Header)
16562 }
16563 return c.header_
16564 }
16565
16566 func (c *MonetizationSubscriptionsBasePlansDeactivateCall) doRequest(alt string) (*http.Response, error) {
16567 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
16568 var body io.Reader = nil
16569 body, err := googleapi.WithoutDataWrapper.JSONReader(c.deactivatebaseplanrequest)
16570 if err != nil {
16571 return nil, err
16572 }
16573 c.urlParams_.Set("alt", alt)
16574 c.urlParams_.Set("prettyPrint", "false")
16575 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}:deactivate")
16576 urls += "?" + c.urlParams_.Encode()
16577 req, err := http.NewRequest("POST", urls, body)
16578 if err != nil {
16579 return nil, err
16580 }
16581 req.Header = reqHeaders
16582 googleapi.Expand(req.URL, map[string]string{
16583 "packageName": c.packageName,
16584 "productId": c.productId,
16585 "basePlanId": c.basePlanId,
16586 })
16587 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16588 }
16589
16590
16591
16592
16593
16594
16595 func (c *MonetizationSubscriptionsBasePlansDeactivateCall) Do(opts ...googleapi.CallOption) (*Subscription, error) {
16596 gensupport.SetOptions(c.urlParams_, opts...)
16597 res, err := c.doRequest("json")
16598 if res != nil && res.StatusCode == http.StatusNotModified {
16599 if res.Body != nil {
16600 res.Body.Close()
16601 }
16602 return nil, gensupport.WrapError(&googleapi.Error{
16603 Code: res.StatusCode,
16604 Header: res.Header,
16605 })
16606 }
16607 if err != nil {
16608 return nil, err
16609 }
16610 defer googleapi.CloseBody(res)
16611 if err := googleapi.CheckResponse(res); err != nil {
16612 return nil, gensupport.WrapError(err)
16613 }
16614 ret := &Subscription{
16615 ServerResponse: googleapi.ServerResponse{
16616 Header: res.Header,
16617 HTTPStatusCode: res.StatusCode,
16618 },
16619 }
16620 target := &ret
16621 if err := gensupport.DecodeResponse(target, res); err != nil {
16622 return nil, err
16623 }
16624 return ret, nil
16625 }
16626
16627 type MonetizationSubscriptionsBasePlansDeleteCall struct {
16628 s *Service
16629 packageName string
16630 productId string
16631 basePlanId string
16632 urlParams_ gensupport.URLParams
16633 ctx_ context.Context
16634 header_ http.Header
16635 }
16636
16637
16638
16639
16640
16641
16642
16643 func (r *MonetizationSubscriptionsBasePlansService) Delete(packageName string, productId string, basePlanId string) *MonetizationSubscriptionsBasePlansDeleteCall {
16644 c := &MonetizationSubscriptionsBasePlansDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16645 c.packageName = packageName
16646 c.productId = productId
16647 c.basePlanId = basePlanId
16648 return c
16649 }
16650
16651
16652
16653
16654 func (c *MonetizationSubscriptionsBasePlansDeleteCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansDeleteCall {
16655 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16656 return c
16657 }
16658
16659
16660 func (c *MonetizationSubscriptionsBasePlansDeleteCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansDeleteCall {
16661 c.ctx_ = ctx
16662 return c
16663 }
16664
16665
16666
16667 func (c *MonetizationSubscriptionsBasePlansDeleteCall) Header() http.Header {
16668 if c.header_ == nil {
16669 c.header_ = make(http.Header)
16670 }
16671 return c.header_
16672 }
16673
16674 func (c *MonetizationSubscriptionsBasePlansDeleteCall) doRequest(alt string) (*http.Response, error) {
16675 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
16676 var body io.Reader = nil
16677 c.urlParams_.Set("alt", alt)
16678 c.urlParams_.Set("prettyPrint", "false")
16679 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}")
16680 urls += "?" + c.urlParams_.Encode()
16681 req, err := http.NewRequest("DELETE", urls, body)
16682 if err != nil {
16683 return nil, err
16684 }
16685 req.Header = reqHeaders
16686 googleapi.Expand(req.URL, map[string]string{
16687 "packageName": c.packageName,
16688 "productId": c.productId,
16689 "basePlanId": c.basePlanId,
16690 })
16691 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16692 }
16693
16694
16695 func (c *MonetizationSubscriptionsBasePlansDeleteCall) Do(opts ...googleapi.CallOption) error {
16696 gensupport.SetOptions(c.urlParams_, opts...)
16697 res, err := c.doRequest("json")
16698 if err != nil {
16699 return err
16700 }
16701 defer googleapi.CloseBody(res)
16702 if err := googleapi.CheckResponse(res); err != nil {
16703 return gensupport.WrapError(err)
16704 }
16705 return nil
16706 }
16707
16708 type MonetizationSubscriptionsBasePlansMigratePricesCall struct {
16709 s *Service
16710 packageName string
16711 productId string
16712 basePlanId string
16713 migratebaseplanpricesrequest *MigrateBasePlanPricesRequest
16714 urlParams_ gensupport.URLParams
16715 ctx_ context.Context
16716 header_ http.Header
16717 }
16718
16719
16720
16721
16722
16723
16724
16725
16726
16727
16728
16729
16730
16731 func (r *MonetizationSubscriptionsBasePlansService) MigratePrices(packageName string, productId string, basePlanId string, migratebaseplanpricesrequest *MigrateBasePlanPricesRequest) *MonetizationSubscriptionsBasePlansMigratePricesCall {
16732 c := &MonetizationSubscriptionsBasePlansMigratePricesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16733 c.packageName = packageName
16734 c.productId = productId
16735 c.basePlanId = basePlanId
16736 c.migratebaseplanpricesrequest = migratebaseplanpricesrequest
16737 return c
16738 }
16739
16740
16741
16742
16743 func (c *MonetizationSubscriptionsBasePlansMigratePricesCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansMigratePricesCall {
16744 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16745 return c
16746 }
16747
16748
16749 func (c *MonetizationSubscriptionsBasePlansMigratePricesCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansMigratePricesCall {
16750 c.ctx_ = ctx
16751 return c
16752 }
16753
16754
16755
16756 func (c *MonetizationSubscriptionsBasePlansMigratePricesCall) Header() http.Header {
16757 if c.header_ == nil {
16758 c.header_ = make(http.Header)
16759 }
16760 return c.header_
16761 }
16762
16763 func (c *MonetizationSubscriptionsBasePlansMigratePricesCall) doRequest(alt string) (*http.Response, error) {
16764 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
16765 var body io.Reader = nil
16766 body, err := googleapi.WithoutDataWrapper.JSONReader(c.migratebaseplanpricesrequest)
16767 if err != nil {
16768 return nil, err
16769 }
16770 c.urlParams_.Set("alt", alt)
16771 c.urlParams_.Set("prettyPrint", "false")
16772 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}:migratePrices")
16773 urls += "?" + c.urlParams_.Encode()
16774 req, err := http.NewRequest("POST", urls, body)
16775 if err != nil {
16776 return nil, err
16777 }
16778 req.Header = reqHeaders
16779 googleapi.Expand(req.URL, map[string]string{
16780 "packageName": c.packageName,
16781 "productId": c.productId,
16782 "basePlanId": c.basePlanId,
16783 })
16784 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16785 }
16786
16787
16788
16789
16790
16791
16792
16793 func (c *MonetizationSubscriptionsBasePlansMigratePricesCall) Do(opts ...googleapi.CallOption) (*MigrateBasePlanPricesResponse, error) {
16794 gensupport.SetOptions(c.urlParams_, opts...)
16795 res, err := c.doRequest("json")
16796 if res != nil && res.StatusCode == http.StatusNotModified {
16797 if res.Body != nil {
16798 res.Body.Close()
16799 }
16800 return nil, gensupport.WrapError(&googleapi.Error{
16801 Code: res.StatusCode,
16802 Header: res.Header,
16803 })
16804 }
16805 if err != nil {
16806 return nil, err
16807 }
16808 defer googleapi.CloseBody(res)
16809 if err := googleapi.CheckResponse(res); err != nil {
16810 return nil, gensupport.WrapError(err)
16811 }
16812 ret := &MigrateBasePlanPricesResponse{
16813 ServerResponse: googleapi.ServerResponse{
16814 Header: res.Header,
16815 HTTPStatusCode: res.StatusCode,
16816 },
16817 }
16818 target := &ret
16819 if err := gensupport.DecodeResponse(target, res); err != nil {
16820 return nil, err
16821 }
16822 return ret, nil
16823 }
16824
16825 type MonetizationSubscriptionsBasePlansOffersActivateCall struct {
16826 s *Service
16827 packageName string
16828 productId string
16829 basePlanId string
16830 offerId string
16831 activatesubscriptionofferrequest *ActivateSubscriptionOfferRequest
16832 urlParams_ gensupport.URLParams
16833 ctx_ context.Context
16834 header_ http.Header
16835 }
16836
16837
16838
16839
16840
16841
16842
16843
16844 func (r *MonetizationSubscriptionsBasePlansOffersService) Activate(packageName string, productId string, basePlanId string, offerId string, activatesubscriptionofferrequest *ActivateSubscriptionOfferRequest) *MonetizationSubscriptionsBasePlansOffersActivateCall {
16845 c := &MonetizationSubscriptionsBasePlansOffersActivateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16846 c.packageName = packageName
16847 c.productId = productId
16848 c.basePlanId = basePlanId
16849 c.offerId = offerId
16850 c.activatesubscriptionofferrequest = activatesubscriptionofferrequest
16851 return c
16852 }
16853
16854
16855
16856
16857 func (c *MonetizationSubscriptionsBasePlansOffersActivateCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersActivateCall {
16858 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16859 return c
16860 }
16861
16862
16863 func (c *MonetizationSubscriptionsBasePlansOffersActivateCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersActivateCall {
16864 c.ctx_ = ctx
16865 return c
16866 }
16867
16868
16869
16870 func (c *MonetizationSubscriptionsBasePlansOffersActivateCall) Header() http.Header {
16871 if c.header_ == nil {
16872 c.header_ = make(http.Header)
16873 }
16874 return c.header_
16875 }
16876
16877 func (c *MonetizationSubscriptionsBasePlansOffersActivateCall) doRequest(alt string) (*http.Response, error) {
16878 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
16879 var body io.Reader = nil
16880 body, err := googleapi.WithoutDataWrapper.JSONReader(c.activatesubscriptionofferrequest)
16881 if err != nil {
16882 return nil, err
16883 }
16884 c.urlParams_.Set("alt", alt)
16885 c.urlParams_.Set("prettyPrint", "false")
16886 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers/{offerId}:activate")
16887 urls += "?" + c.urlParams_.Encode()
16888 req, err := http.NewRequest("POST", urls, body)
16889 if err != nil {
16890 return nil, err
16891 }
16892 req.Header = reqHeaders
16893 googleapi.Expand(req.URL, map[string]string{
16894 "packageName": c.packageName,
16895 "productId": c.productId,
16896 "basePlanId": c.basePlanId,
16897 "offerId": c.offerId,
16898 })
16899 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16900 }
16901
16902
16903
16904
16905
16906
16907
16908 func (c *MonetizationSubscriptionsBasePlansOffersActivateCall) Do(opts ...googleapi.CallOption) (*SubscriptionOffer, error) {
16909 gensupport.SetOptions(c.urlParams_, opts...)
16910 res, err := c.doRequest("json")
16911 if res != nil && res.StatusCode == http.StatusNotModified {
16912 if res.Body != nil {
16913 res.Body.Close()
16914 }
16915 return nil, gensupport.WrapError(&googleapi.Error{
16916 Code: res.StatusCode,
16917 Header: res.Header,
16918 })
16919 }
16920 if err != nil {
16921 return nil, err
16922 }
16923 defer googleapi.CloseBody(res)
16924 if err := googleapi.CheckResponse(res); err != nil {
16925 return nil, gensupport.WrapError(err)
16926 }
16927 ret := &SubscriptionOffer{
16928 ServerResponse: googleapi.ServerResponse{
16929 Header: res.Header,
16930 HTTPStatusCode: res.StatusCode,
16931 },
16932 }
16933 target := &ret
16934 if err := gensupport.DecodeResponse(target, res); err != nil {
16935 return nil, err
16936 }
16937 return ret, nil
16938 }
16939
16940 type MonetizationSubscriptionsBasePlansOffersBatchGetCall struct {
16941 s *Service
16942 packageName string
16943 productId string
16944 basePlanId string
16945 batchgetsubscriptionoffersrequest *BatchGetSubscriptionOffersRequest
16946 urlParams_ gensupport.URLParams
16947 ctx_ context.Context
16948 header_ http.Header
16949 }
16950
16951
16952
16953
16954
16955
16956
16957
16958
16959
16960
16961 func (r *MonetizationSubscriptionsBasePlansOffersService) BatchGet(packageName string, productId string, basePlanId string, batchgetsubscriptionoffersrequest *BatchGetSubscriptionOffersRequest) *MonetizationSubscriptionsBasePlansOffersBatchGetCall {
16962 c := &MonetizationSubscriptionsBasePlansOffersBatchGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16963 c.packageName = packageName
16964 c.productId = productId
16965 c.basePlanId = basePlanId
16966 c.batchgetsubscriptionoffersrequest = batchgetsubscriptionoffersrequest
16967 return c
16968 }
16969
16970
16971
16972
16973 func (c *MonetizationSubscriptionsBasePlansOffersBatchGetCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersBatchGetCall {
16974 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16975 return c
16976 }
16977
16978
16979 func (c *MonetizationSubscriptionsBasePlansOffersBatchGetCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersBatchGetCall {
16980 c.ctx_ = ctx
16981 return c
16982 }
16983
16984
16985
16986 func (c *MonetizationSubscriptionsBasePlansOffersBatchGetCall) Header() http.Header {
16987 if c.header_ == nil {
16988 c.header_ = make(http.Header)
16989 }
16990 return c.header_
16991 }
16992
16993 func (c *MonetizationSubscriptionsBasePlansOffersBatchGetCall) doRequest(alt string) (*http.Response, error) {
16994 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
16995 var body io.Reader = nil
16996 body, err := googleapi.WithoutDataWrapper.JSONReader(c.batchgetsubscriptionoffersrequest)
16997 if err != nil {
16998 return nil, err
16999 }
17000 c.urlParams_.Set("alt", alt)
17001 c.urlParams_.Set("prettyPrint", "false")
17002 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers:batchGet")
17003 urls += "?" + c.urlParams_.Encode()
17004 req, err := http.NewRequest("POST", urls, body)
17005 if err != nil {
17006 return nil, err
17007 }
17008 req.Header = reqHeaders
17009 googleapi.Expand(req.URL, map[string]string{
17010 "packageName": c.packageName,
17011 "productId": c.productId,
17012 "basePlanId": c.basePlanId,
17013 })
17014 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17015 }
17016
17017
17018
17019
17020
17021
17022
17023 func (c *MonetizationSubscriptionsBasePlansOffersBatchGetCall) Do(opts ...googleapi.CallOption) (*BatchGetSubscriptionOffersResponse, error) {
17024 gensupport.SetOptions(c.urlParams_, opts...)
17025 res, err := c.doRequest("json")
17026 if res != nil && res.StatusCode == http.StatusNotModified {
17027 if res.Body != nil {
17028 res.Body.Close()
17029 }
17030 return nil, gensupport.WrapError(&googleapi.Error{
17031 Code: res.StatusCode,
17032 Header: res.Header,
17033 })
17034 }
17035 if err != nil {
17036 return nil, err
17037 }
17038 defer googleapi.CloseBody(res)
17039 if err := googleapi.CheckResponse(res); err != nil {
17040 return nil, gensupport.WrapError(err)
17041 }
17042 ret := &BatchGetSubscriptionOffersResponse{
17043 ServerResponse: googleapi.ServerResponse{
17044 Header: res.Header,
17045 HTTPStatusCode: res.StatusCode,
17046 },
17047 }
17048 target := &ret
17049 if err := gensupport.DecodeResponse(target, res); err != nil {
17050 return nil, err
17051 }
17052 return ret, nil
17053 }
17054
17055 type MonetizationSubscriptionsBasePlansOffersBatchUpdateCall struct {
17056 s *Service
17057 packageName string
17058 productId string
17059 basePlanId string
17060 batchupdatesubscriptionoffersrequest *BatchUpdateSubscriptionOffersRequest
17061 urlParams_ gensupport.URLParams
17062 ctx_ context.Context
17063 header_ http.Header
17064 }
17065
17066
17067
17068
17069
17070
17071
17072
17073
17074
17075
17076
17077
17078
17079
17080 func (r *MonetizationSubscriptionsBasePlansOffersService) BatchUpdate(packageName string, productId string, basePlanId string, batchupdatesubscriptionoffersrequest *BatchUpdateSubscriptionOffersRequest) *MonetizationSubscriptionsBasePlansOffersBatchUpdateCall {
17081 c := &MonetizationSubscriptionsBasePlansOffersBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17082 c.packageName = packageName
17083 c.productId = productId
17084 c.basePlanId = basePlanId
17085 c.batchupdatesubscriptionoffersrequest = batchupdatesubscriptionoffersrequest
17086 return c
17087 }
17088
17089
17090
17091
17092 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersBatchUpdateCall {
17093 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17094 return c
17095 }
17096
17097
17098 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersBatchUpdateCall {
17099 c.ctx_ = ctx
17100 return c
17101 }
17102
17103
17104
17105 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateCall) Header() http.Header {
17106 if c.header_ == nil {
17107 c.header_ = make(http.Header)
17108 }
17109 return c.header_
17110 }
17111
17112 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
17113 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
17114 var body io.Reader = nil
17115 body, err := googleapi.WithoutDataWrapper.JSONReader(c.batchupdatesubscriptionoffersrequest)
17116 if err != nil {
17117 return nil, err
17118 }
17119 c.urlParams_.Set("alt", alt)
17120 c.urlParams_.Set("prettyPrint", "false")
17121 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers:batchUpdate")
17122 urls += "?" + c.urlParams_.Encode()
17123 req, err := http.NewRequest("POST", urls, body)
17124 if err != nil {
17125 return nil, err
17126 }
17127 req.Header = reqHeaders
17128 googleapi.Expand(req.URL, map[string]string{
17129 "packageName": c.packageName,
17130 "productId": c.productId,
17131 "basePlanId": c.basePlanId,
17132 })
17133 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17134 }
17135
17136
17137
17138
17139
17140
17141
17142 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateCall) Do(opts ...googleapi.CallOption) (*BatchUpdateSubscriptionOffersResponse, error) {
17143 gensupport.SetOptions(c.urlParams_, opts...)
17144 res, err := c.doRequest("json")
17145 if res != nil && res.StatusCode == http.StatusNotModified {
17146 if res.Body != nil {
17147 res.Body.Close()
17148 }
17149 return nil, gensupport.WrapError(&googleapi.Error{
17150 Code: res.StatusCode,
17151 Header: res.Header,
17152 })
17153 }
17154 if err != nil {
17155 return nil, err
17156 }
17157 defer googleapi.CloseBody(res)
17158 if err := googleapi.CheckResponse(res); err != nil {
17159 return nil, gensupport.WrapError(err)
17160 }
17161 ret := &BatchUpdateSubscriptionOffersResponse{
17162 ServerResponse: googleapi.ServerResponse{
17163 Header: res.Header,
17164 HTTPStatusCode: res.StatusCode,
17165 },
17166 }
17167 target := &ret
17168 if err := gensupport.DecodeResponse(target, res); err != nil {
17169 return nil, err
17170 }
17171 return ret, nil
17172 }
17173
17174 type MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall struct {
17175 s *Service
17176 packageName string
17177 productId string
17178 basePlanId string
17179 batchupdatesubscriptionofferstatesrequest *BatchUpdateSubscriptionOfferStatesRequest
17180 urlParams_ gensupport.URLParams
17181 ctx_ context.Context
17182 header_ http.Header
17183 }
17184
17185
17186
17187
17188
17189
17190
17191
17192
17193
17194
17195
17196
17197
17198
17199 func (r *MonetizationSubscriptionsBasePlansOffersService) BatchUpdateStates(packageName string, productId string, basePlanId string, batchupdatesubscriptionofferstatesrequest *BatchUpdateSubscriptionOfferStatesRequest) *MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall {
17200 c := &MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17201 c.packageName = packageName
17202 c.productId = productId
17203 c.basePlanId = basePlanId
17204 c.batchupdatesubscriptionofferstatesrequest = batchupdatesubscriptionofferstatesrequest
17205 return c
17206 }
17207
17208
17209
17210
17211 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall {
17212 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17213 return c
17214 }
17215
17216
17217 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall {
17218 c.ctx_ = ctx
17219 return c
17220 }
17221
17222
17223
17224 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall) Header() http.Header {
17225 if c.header_ == nil {
17226 c.header_ = make(http.Header)
17227 }
17228 return c.header_
17229 }
17230
17231 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall) doRequest(alt string) (*http.Response, error) {
17232 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
17233 var body io.Reader = nil
17234 body, err := googleapi.WithoutDataWrapper.JSONReader(c.batchupdatesubscriptionofferstatesrequest)
17235 if err != nil {
17236 return nil, err
17237 }
17238 c.urlParams_.Set("alt", alt)
17239 c.urlParams_.Set("prettyPrint", "false")
17240 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers:batchUpdateStates")
17241 urls += "?" + c.urlParams_.Encode()
17242 req, err := http.NewRequest("POST", urls, body)
17243 if err != nil {
17244 return nil, err
17245 }
17246 req.Header = reqHeaders
17247 googleapi.Expand(req.URL, map[string]string{
17248 "packageName": c.packageName,
17249 "productId": c.productId,
17250 "basePlanId": c.basePlanId,
17251 })
17252 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17253 }
17254
17255
17256
17257
17258
17259
17260
17261 func (c *MonetizationSubscriptionsBasePlansOffersBatchUpdateStatesCall) Do(opts ...googleapi.CallOption) (*BatchUpdateSubscriptionOfferStatesResponse, error) {
17262 gensupport.SetOptions(c.urlParams_, opts...)
17263 res, err := c.doRequest("json")
17264 if res != nil && res.StatusCode == http.StatusNotModified {
17265 if res.Body != nil {
17266 res.Body.Close()
17267 }
17268 return nil, gensupport.WrapError(&googleapi.Error{
17269 Code: res.StatusCode,
17270 Header: res.Header,
17271 })
17272 }
17273 if err != nil {
17274 return nil, err
17275 }
17276 defer googleapi.CloseBody(res)
17277 if err := googleapi.CheckResponse(res); err != nil {
17278 return nil, gensupport.WrapError(err)
17279 }
17280 ret := &BatchUpdateSubscriptionOfferStatesResponse{
17281 ServerResponse: googleapi.ServerResponse{
17282 Header: res.Header,
17283 HTTPStatusCode: res.StatusCode,
17284 },
17285 }
17286 target := &ret
17287 if err := gensupport.DecodeResponse(target, res); err != nil {
17288 return nil, err
17289 }
17290 return ret, nil
17291 }
17292
17293 type MonetizationSubscriptionsBasePlansOffersCreateCall struct {
17294 s *Service
17295 packageName string
17296 productId string
17297 basePlanId string
17298 subscriptionoffer *SubscriptionOffer
17299 urlParams_ gensupport.URLParams
17300 ctx_ context.Context
17301 header_ http.Header
17302 }
17303
17304
17305
17306
17307
17308
17309
17310
17311
17312
17313
17314
17315
17316
17317 func (r *MonetizationSubscriptionsBasePlansOffersService) Create(packageName string, productId string, basePlanId string, subscriptionoffer *SubscriptionOffer) *MonetizationSubscriptionsBasePlansOffersCreateCall {
17318 c := &MonetizationSubscriptionsBasePlansOffersCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17319 c.packageName = packageName
17320 c.productId = productId
17321 c.basePlanId = basePlanId
17322 c.subscriptionoffer = subscriptionoffer
17323 return c
17324 }
17325
17326
17327
17328
17329 func (c *MonetizationSubscriptionsBasePlansOffersCreateCall) OfferId(offerId string) *MonetizationSubscriptionsBasePlansOffersCreateCall {
17330 c.urlParams_.Set("offerId", offerId)
17331 return c
17332 }
17333
17334
17335
17336
17337
17338
17339
17340
17341
17342
17343
17344 func (c *MonetizationSubscriptionsBasePlansOffersCreateCall) RegionsVersionVersion(regionsVersionVersion string) *MonetizationSubscriptionsBasePlansOffersCreateCall {
17345 c.urlParams_.Set("regionsVersion.version", regionsVersionVersion)
17346 return c
17347 }
17348
17349
17350
17351
17352 func (c *MonetizationSubscriptionsBasePlansOffersCreateCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersCreateCall {
17353 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17354 return c
17355 }
17356
17357
17358 func (c *MonetizationSubscriptionsBasePlansOffersCreateCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersCreateCall {
17359 c.ctx_ = ctx
17360 return c
17361 }
17362
17363
17364
17365 func (c *MonetizationSubscriptionsBasePlansOffersCreateCall) Header() http.Header {
17366 if c.header_ == nil {
17367 c.header_ = make(http.Header)
17368 }
17369 return c.header_
17370 }
17371
17372 func (c *MonetizationSubscriptionsBasePlansOffersCreateCall) doRequest(alt string) (*http.Response, error) {
17373 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
17374 var body io.Reader = nil
17375 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subscriptionoffer)
17376 if err != nil {
17377 return nil, err
17378 }
17379 c.urlParams_.Set("alt", alt)
17380 c.urlParams_.Set("prettyPrint", "false")
17381 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers")
17382 urls += "?" + c.urlParams_.Encode()
17383 req, err := http.NewRequest("POST", urls, body)
17384 if err != nil {
17385 return nil, err
17386 }
17387 req.Header = reqHeaders
17388 googleapi.Expand(req.URL, map[string]string{
17389 "packageName": c.packageName,
17390 "productId": c.productId,
17391 "basePlanId": c.basePlanId,
17392 })
17393 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17394 }
17395
17396
17397
17398
17399
17400
17401
17402 func (c *MonetizationSubscriptionsBasePlansOffersCreateCall) Do(opts ...googleapi.CallOption) (*SubscriptionOffer, error) {
17403 gensupport.SetOptions(c.urlParams_, opts...)
17404 res, err := c.doRequest("json")
17405 if res != nil && res.StatusCode == http.StatusNotModified {
17406 if res.Body != nil {
17407 res.Body.Close()
17408 }
17409 return nil, gensupport.WrapError(&googleapi.Error{
17410 Code: res.StatusCode,
17411 Header: res.Header,
17412 })
17413 }
17414 if err != nil {
17415 return nil, err
17416 }
17417 defer googleapi.CloseBody(res)
17418 if err := googleapi.CheckResponse(res); err != nil {
17419 return nil, gensupport.WrapError(err)
17420 }
17421 ret := &SubscriptionOffer{
17422 ServerResponse: googleapi.ServerResponse{
17423 Header: res.Header,
17424 HTTPStatusCode: res.StatusCode,
17425 },
17426 }
17427 target := &ret
17428 if err := gensupport.DecodeResponse(target, res); err != nil {
17429 return nil, err
17430 }
17431 return ret, nil
17432 }
17433
17434 type MonetizationSubscriptionsBasePlansOffersDeactivateCall struct {
17435 s *Service
17436 packageName string
17437 productId string
17438 basePlanId string
17439 offerId string
17440 deactivatesubscriptionofferrequest *DeactivateSubscriptionOfferRequest
17441 urlParams_ gensupport.URLParams
17442 ctx_ context.Context
17443 header_ http.Header
17444 }
17445
17446
17447
17448
17449
17450
17451
17452
17453
17454 func (r *MonetizationSubscriptionsBasePlansOffersService) Deactivate(packageName string, productId string, basePlanId string, offerId string, deactivatesubscriptionofferrequest *DeactivateSubscriptionOfferRequest) *MonetizationSubscriptionsBasePlansOffersDeactivateCall {
17455 c := &MonetizationSubscriptionsBasePlansOffersDeactivateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17456 c.packageName = packageName
17457 c.productId = productId
17458 c.basePlanId = basePlanId
17459 c.offerId = offerId
17460 c.deactivatesubscriptionofferrequest = deactivatesubscriptionofferrequest
17461 return c
17462 }
17463
17464
17465
17466
17467 func (c *MonetizationSubscriptionsBasePlansOffersDeactivateCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersDeactivateCall {
17468 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17469 return c
17470 }
17471
17472
17473 func (c *MonetizationSubscriptionsBasePlansOffersDeactivateCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersDeactivateCall {
17474 c.ctx_ = ctx
17475 return c
17476 }
17477
17478
17479
17480 func (c *MonetizationSubscriptionsBasePlansOffersDeactivateCall) Header() http.Header {
17481 if c.header_ == nil {
17482 c.header_ = make(http.Header)
17483 }
17484 return c.header_
17485 }
17486
17487 func (c *MonetizationSubscriptionsBasePlansOffersDeactivateCall) doRequest(alt string) (*http.Response, error) {
17488 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
17489 var body io.Reader = nil
17490 body, err := googleapi.WithoutDataWrapper.JSONReader(c.deactivatesubscriptionofferrequest)
17491 if err != nil {
17492 return nil, err
17493 }
17494 c.urlParams_.Set("alt", alt)
17495 c.urlParams_.Set("prettyPrint", "false")
17496 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers/{offerId}:deactivate")
17497 urls += "?" + c.urlParams_.Encode()
17498 req, err := http.NewRequest("POST", urls, body)
17499 if err != nil {
17500 return nil, err
17501 }
17502 req.Header = reqHeaders
17503 googleapi.Expand(req.URL, map[string]string{
17504 "packageName": c.packageName,
17505 "productId": c.productId,
17506 "basePlanId": c.basePlanId,
17507 "offerId": c.offerId,
17508 })
17509 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17510 }
17511
17512
17513
17514
17515
17516
17517
17518 func (c *MonetizationSubscriptionsBasePlansOffersDeactivateCall) Do(opts ...googleapi.CallOption) (*SubscriptionOffer, error) {
17519 gensupport.SetOptions(c.urlParams_, opts...)
17520 res, err := c.doRequest("json")
17521 if res != nil && res.StatusCode == http.StatusNotModified {
17522 if res.Body != nil {
17523 res.Body.Close()
17524 }
17525 return nil, gensupport.WrapError(&googleapi.Error{
17526 Code: res.StatusCode,
17527 Header: res.Header,
17528 })
17529 }
17530 if err != nil {
17531 return nil, err
17532 }
17533 defer googleapi.CloseBody(res)
17534 if err := googleapi.CheckResponse(res); err != nil {
17535 return nil, gensupport.WrapError(err)
17536 }
17537 ret := &SubscriptionOffer{
17538 ServerResponse: googleapi.ServerResponse{
17539 Header: res.Header,
17540 HTTPStatusCode: res.StatusCode,
17541 },
17542 }
17543 target := &ret
17544 if err := gensupport.DecodeResponse(target, res); err != nil {
17545 return nil, err
17546 }
17547 return ret, nil
17548 }
17549
17550 type MonetizationSubscriptionsBasePlansOffersDeleteCall struct {
17551 s *Service
17552 packageName string
17553 productId string
17554 basePlanId string
17555 offerId string
17556 urlParams_ gensupport.URLParams
17557 ctx_ context.Context
17558 header_ http.Header
17559 }
17560
17561
17562
17563
17564
17565
17566
17567
17568 func (r *MonetizationSubscriptionsBasePlansOffersService) Delete(packageName string, productId string, basePlanId string, offerId string) *MonetizationSubscriptionsBasePlansOffersDeleteCall {
17569 c := &MonetizationSubscriptionsBasePlansOffersDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17570 c.packageName = packageName
17571 c.productId = productId
17572 c.basePlanId = basePlanId
17573 c.offerId = offerId
17574 return c
17575 }
17576
17577
17578
17579
17580 func (c *MonetizationSubscriptionsBasePlansOffersDeleteCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersDeleteCall {
17581 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17582 return c
17583 }
17584
17585
17586 func (c *MonetizationSubscriptionsBasePlansOffersDeleteCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersDeleteCall {
17587 c.ctx_ = ctx
17588 return c
17589 }
17590
17591
17592
17593 func (c *MonetizationSubscriptionsBasePlansOffersDeleteCall) Header() http.Header {
17594 if c.header_ == nil {
17595 c.header_ = make(http.Header)
17596 }
17597 return c.header_
17598 }
17599
17600 func (c *MonetizationSubscriptionsBasePlansOffersDeleteCall) doRequest(alt string) (*http.Response, error) {
17601 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
17602 var body io.Reader = nil
17603 c.urlParams_.Set("alt", alt)
17604 c.urlParams_.Set("prettyPrint", "false")
17605 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers/{offerId}")
17606 urls += "?" + c.urlParams_.Encode()
17607 req, err := http.NewRequest("DELETE", urls, body)
17608 if err != nil {
17609 return nil, err
17610 }
17611 req.Header = reqHeaders
17612 googleapi.Expand(req.URL, map[string]string{
17613 "packageName": c.packageName,
17614 "productId": c.productId,
17615 "basePlanId": c.basePlanId,
17616 "offerId": c.offerId,
17617 })
17618 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17619 }
17620
17621
17622 func (c *MonetizationSubscriptionsBasePlansOffersDeleteCall) Do(opts ...googleapi.CallOption) error {
17623 gensupport.SetOptions(c.urlParams_, opts...)
17624 res, err := c.doRequest("json")
17625 if err != nil {
17626 return err
17627 }
17628 defer googleapi.CloseBody(res)
17629 if err := googleapi.CheckResponse(res); err != nil {
17630 return gensupport.WrapError(err)
17631 }
17632 return nil
17633 }
17634
17635 type MonetizationSubscriptionsBasePlansOffersGetCall struct {
17636 s *Service
17637 packageName string
17638 productId string
17639 basePlanId string
17640 offerId string
17641 urlParams_ gensupport.URLParams
17642 ifNoneMatch_ string
17643 ctx_ context.Context
17644 header_ http.Header
17645 }
17646
17647
17648
17649
17650
17651
17652
17653 func (r *MonetizationSubscriptionsBasePlansOffersService) Get(packageName string, productId string, basePlanId string, offerId string) *MonetizationSubscriptionsBasePlansOffersGetCall {
17654 c := &MonetizationSubscriptionsBasePlansOffersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17655 c.packageName = packageName
17656 c.productId = productId
17657 c.basePlanId = basePlanId
17658 c.offerId = offerId
17659 return c
17660 }
17661
17662
17663
17664
17665 func (c *MonetizationSubscriptionsBasePlansOffersGetCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersGetCall {
17666 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17667 return c
17668 }
17669
17670
17671
17672
17673 func (c *MonetizationSubscriptionsBasePlansOffersGetCall) IfNoneMatch(entityTag string) *MonetizationSubscriptionsBasePlansOffersGetCall {
17674 c.ifNoneMatch_ = entityTag
17675 return c
17676 }
17677
17678
17679 func (c *MonetizationSubscriptionsBasePlansOffersGetCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersGetCall {
17680 c.ctx_ = ctx
17681 return c
17682 }
17683
17684
17685
17686 func (c *MonetizationSubscriptionsBasePlansOffersGetCall) Header() http.Header {
17687 if c.header_ == nil {
17688 c.header_ = make(http.Header)
17689 }
17690 return c.header_
17691 }
17692
17693 func (c *MonetizationSubscriptionsBasePlansOffersGetCall) doRequest(alt string) (*http.Response, error) {
17694 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
17695 if c.ifNoneMatch_ != "" {
17696 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17697 }
17698 var body io.Reader = nil
17699 c.urlParams_.Set("alt", alt)
17700 c.urlParams_.Set("prettyPrint", "false")
17701 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers/{offerId}")
17702 urls += "?" + c.urlParams_.Encode()
17703 req, err := http.NewRequest("GET", urls, body)
17704 if err != nil {
17705 return nil, err
17706 }
17707 req.Header = reqHeaders
17708 googleapi.Expand(req.URL, map[string]string{
17709 "packageName": c.packageName,
17710 "productId": c.productId,
17711 "basePlanId": c.basePlanId,
17712 "offerId": c.offerId,
17713 })
17714 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17715 }
17716
17717
17718
17719
17720
17721
17722
17723 func (c *MonetizationSubscriptionsBasePlansOffersGetCall) Do(opts ...googleapi.CallOption) (*SubscriptionOffer, error) {
17724 gensupport.SetOptions(c.urlParams_, opts...)
17725 res, err := c.doRequest("json")
17726 if res != nil && res.StatusCode == http.StatusNotModified {
17727 if res.Body != nil {
17728 res.Body.Close()
17729 }
17730 return nil, gensupport.WrapError(&googleapi.Error{
17731 Code: res.StatusCode,
17732 Header: res.Header,
17733 })
17734 }
17735 if err != nil {
17736 return nil, err
17737 }
17738 defer googleapi.CloseBody(res)
17739 if err := googleapi.CheckResponse(res); err != nil {
17740 return nil, gensupport.WrapError(err)
17741 }
17742 ret := &SubscriptionOffer{
17743 ServerResponse: googleapi.ServerResponse{
17744 Header: res.Header,
17745 HTTPStatusCode: res.StatusCode,
17746 },
17747 }
17748 target := &ret
17749 if err := gensupport.DecodeResponse(target, res); err != nil {
17750 return nil, err
17751 }
17752 return ret, nil
17753 }
17754
17755 type MonetizationSubscriptionsBasePlansOffersListCall struct {
17756 s *Service
17757 packageName string
17758 productId string
17759 basePlanId string
17760 urlParams_ gensupport.URLParams
17761 ifNoneMatch_ string
17762 ctx_ context.Context
17763 header_ http.Header
17764 }
17765
17766
17767
17768
17769
17770
17771
17772
17773
17774
17775 func (r *MonetizationSubscriptionsBasePlansOffersService) List(packageName string, productId string, basePlanId string) *MonetizationSubscriptionsBasePlansOffersListCall {
17776 c := &MonetizationSubscriptionsBasePlansOffersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17777 c.packageName = packageName
17778 c.productId = productId
17779 c.basePlanId = basePlanId
17780 return c
17781 }
17782
17783
17784
17785
17786
17787 func (c *MonetizationSubscriptionsBasePlansOffersListCall) PageSize(pageSize int64) *MonetizationSubscriptionsBasePlansOffersListCall {
17788 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
17789 return c
17790 }
17791
17792
17793
17794
17795
17796 func (c *MonetizationSubscriptionsBasePlansOffersListCall) PageToken(pageToken string) *MonetizationSubscriptionsBasePlansOffersListCall {
17797 c.urlParams_.Set("pageToken", pageToken)
17798 return c
17799 }
17800
17801
17802
17803
17804 func (c *MonetizationSubscriptionsBasePlansOffersListCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersListCall {
17805 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17806 return c
17807 }
17808
17809
17810
17811
17812 func (c *MonetizationSubscriptionsBasePlansOffersListCall) IfNoneMatch(entityTag string) *MonetizationSubscriptionsBasePlansOffersListCall {
17813 c.ifNoneMatch_ = entityTag
17814 return c
17815 }
17816
17817
17818 func (c *MonetizationSubscriptionsBasePlansOffersListCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersListCall {
17819 c.ctx_ = ctx
17820 return c
17821 }
17822
17823
17824
17825 func (c *MonetizationSubscriptionsBasePlansOffersListCall) Header() http.Header {
17826 if c.header_ == nil {
17827 c.header_ = make(http.Header)
17828 }
17829 return c.header_
17830 }
17831
17832 func (c *MonetizationSubscriptionsBasePlansOffersListCall) doRequest(alt string) (*http.Response, error) {
17833 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
17834 if c.ifNoneMatch_ != "" {
17835 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17836 }
17837 var body io.Reader = nil
17838 c.urlParams_.Set("alt", alt)
17839 c.urlParams_.Set("prettyPrint", "false")
17840 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers")
17841 urls += "?" + c.urlParams_.Encode()
17842 req, err := http.NewRequest("GET", urls, body)
17843 if err != nil {
17844 return nil, err
17845 }
17846 req.Header = reqHeaders
17847 googleapi.Expand(req.URL, map[string]string{
17848 "packageName": c.packageName,
17849 "productId": c.productId,
17850 "basePlanId": c.basePlanId,
17851 })
17852 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17853 }
17854
17855
17856
17857
17858
17859
17860
17861 func (c *MonetizationSubscriptionsBasePlansOffersListCall) Do(opts ...googleapi.CallOption) (*ListSubscriptionOffersResponse, error) {
17862 gensupport.SetOptions(c.urlParams_, opts...)
17863 res, err := c.doRequest("json")
17864 if res != nil && res.StatusCode == http.StatusNotModified {
17865 if res.Body != nil {
17866 res.Body.Close()
17867 }
17868 return nil, gensupport.WrapError(&googleapi.Error{
17869 Code: res.StatusCode,
17870 Header: res.Header,
17871 })
17872 }
17873 if err != nil {
17874 return nil, err
17875 }
17876 defer googleapi.CloseBody(res)
17877 if err := googleapi.CheckResponse(res); err != nil {
17878 return nil, gensupport.WrapError(err)
17879 }
17880 ret := &ListSubscriptionOffersResponse{
17881 ServerResponse: googleapi.ServerResponse{
17882 Header: res.Header,
17883 HTTPStatusCode: res.StatusCode,
17884 },
17885 }
17886 target := &ret
17887 if err := gensupport.DecodeResponse(target, res); err != nil {
17888 return nil, err
17889 }
17890 return ret, nil
17891 }
17892
17893
17894
17895
17896 func (c *MonetizationSubscriptionsBasePlansOffersListCall) Pages(ctx context.Context, f func(*ListSubscriptionOffersResponse) error) error {
17897 c.ctx_ = ctx
17898 defer c.PageToken(c.urlParams_.Get("pageToken"))
17899 for {
17900 x, err := c.Do()
17901 if err != nil {
17902 return err
17903 }
17904 if err := f(x); err != nil {
17905 return err
17906 }
17907 if x.NextPageToken == "" {
17908 return nil
17909 }
17910 c.PageToken(x.NextPageToken)
17911 }
17912 }
17913
17914 type MonetizationSubscriptionsBasePlansOffersPatchCall struct {
17915 s *Service
17916 packageName string
17917 productId string
17918 basePlanId string
17919 offerId string
17920 subscriptionoffer *SubscriptionOffer
17921 urlParams_ gensupport.URLParams
17922 ctx_ context.Context
17923 header_ http.Header
17924 }
17925
17926
17927
17928
17929
17930
17931
17932
17933
17934
17935
17936 func (r *MonetizationSubscriptionsBasePlansOffersService) Patch(packageName string, productId string, basePlanId string, offerId string, subscriptionoffer *SubscriptionOffer) *MonetizationSubscriptionsBasePlansOffersPatchCall {
17937 c := &MonetizationSubscriptionsBasePlansOffersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17938 c.packageName = packageName
17939 c.productId = productId
17940 c.basePlanId = basePlanId
17941 c.offerId = offerId
17942 c.subscriptionoffer = subscriptionoffer
17943 return c
17944 }
17945
17946
17947
17948
17949
17950 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) AllowMissing(allowMissing bool) *MonetizationSubscriptionsBasePlansOffersPatchCall {
17951 c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing))
17952 return c
17953 }
17954
17955
17956
17957
17958
17959
17960
17961
17962
17963
17964
17965
17966
17967
17968
17969
17970
17971
17972
17973
17974 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) LatencyTolerance(latencyTolerance string) *MonetizationSubscriptionsBasePlansOffersPatchCall {
17975 c.urlParams_.Set("latencyTolerance", latencyTolerance)
17976 return c
17977 }
17978
17979
17980
17981
17982
17983
17984
17985
17986
17987
17988
17989 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) RegionsVersionVersion(regionsVersionVersion string) *MonetizationSubscriptionsBasePlansOffersPatchCall {
17990 c.urlParams_.Set("regionsVersion.version", regionsVersionVersion)
17991 return c
17992 }
17993
17994
17995
17996 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) UpdateMask(updateMask string) *MonetizationSubscriptionsBasePlansOffersPatchCall {
17997 c.urlParams_.Set("updateMask", updateMask)
17998 return c
17999 }
18000
18001
18002
18003
18004 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) Fields(s ...googleapi.Field) *MonetizationSubscriptionsBasePlansOffersPatchCall {
18005 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18006 return c
18007 }
18008
18009
18010 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) Context(ctx context.Context) *MonetizationSubscriptionsBasePlansOffersPatchCall {
18011 c.ctx_ = ctx
18012 return c
18013 }
18014
18015
18016
18017 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) Header() http.Header {
18018 if c.header_ == nil {
18019 c.header_ = make(http.Header)
18020 }
18021 return c.header_
18022 }
18023
18024 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) doRequest(alt string) (*http.Response, error) {
18025 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
18026 var body io.Reader = nil
18027 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subscriptionoffer)
18028 if err != nil {
18029 return nil, err
18030 }
18031 c.urlParams_.Set("alt", alt)
18032 c.urlParams_.Set("prettyPrint", "false")
18033 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/subscriptions/{productId}/basePlans/{basePlanId}/offers/{offerId}")
18034 urls += "?" + c.urlParams_.Encode()
18035 req, err := http.NewRequest("PATCH", urls, body)
18036 if err != nil {
18037 return nil, err
18038 }
18039 req.Header = reqHeaders
18040 googleapi.Expand(req.URL, map[string]string{
18041 "packageName": c.packageName,
18042 "productId": c.productId,
18043 "basePlanId": c.basePlanId,
18044 "offerId": c.offerId,
18045 })
18046 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18047 }
18048
18049
18050
18051
18052
18053
18054
18055 func (c *MonetizationSubscriptionsBasePlansOffersPatchCall) Do(opts ...googleapi.CallOption) (*SubscriptionOffer, error) {
18056 gensupport.SetOptions(c.urlParams_, opts...)
18057 res, err := c.doRequest("json")
18058 if res != nil && res.StatusCode == http.StatusNotModified {
18059 if res.Body != nil {
18060 res.Body.Close()
18061 }
18062 return nil, gensupport.WrapError(&googleapi.Error{
18063 Code: res.StatusCode,
18064 Header: res.Header,
18065 })
18066 }
18067 if err != nil {
18068 return nil, err
18069 }
18070 defer googleapi.CloseBody(res)
18071 if err := googleapi.CheckResponse(res); err != nil {
18072 return nil, gensupport.WrapError(err)
18073 }
18074 ret := &SubscriptionOffer{
18075 ServerResponse: googleapi.ServerResponse{
18076 Header: res.Header,
18077 HTTPStatusCode: res.StatusCode,
18078 },
18079 }
18080 target := &ret
18081 if err := gensupport.DecodeResponse(target, res); err != nil {
18082 return nil, err
18083 }
18084 return ret, nil
18085 }
18086
18087 type OrdersRefundCall struct {
18088 s *Service
18089 packageName string
18090 orderId string
18091 urlParams_ gensupport.URLParams
18092 ctx_ context.Context
18093 header_ http.Header
18094 }
18095
18096
18097
18098
18099
18100
18101
18102
18103 func (r *OrdersService) Refund(packageName string, orderId string) *OrdersRefundCall {
18104 c := &OrdersRefundCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18105 c.packageName = packageName
18106 c.orderId = orderId
18107 return c
18108 }
18109
18110
18111
18112
18113
18114
18115 func (c *OrdersRefundCall) Revoke(revoke bool) *OrdersRefundCall {
18116 c.urlParams_.Set("revoke", fmt.Sprint(revoke))
18117 return c
18118 }
18119
18120
18121
18122
18123 func (c *OrdersRefundCall) Fields(s ...googleapi.Field) *OrdersRefundCall {
18124 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18125 return c
18126 }
18127
18128
18129 func (c *OrdersRefundCall) Context(ctx context.Context) *OrdersRefundCall {
18130 c.ctx_ = ctx
18131 return c
18132 }
18133
18134
18135
18136 func (c *OrdersRefundCall) Header() http.Header {
18137 if c.header_ == nil {
18138 c.header_ = make(http.Header)
18139 }
18140 return c.header_
18141 }
18142
18143 func (c *OrdersRefundCall) doRequest(alt string) (*http.Response, error) {
18144 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
18145 var body io.Reader = nil
18146 c.urlParams_.Set("alt", alt)
18147 c.urlParams_.Set("prettyPrint", "false")
18148 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/orders/{orderId}:refund")
18149 urls += "?" + c.urlParams_.Encode()
18150 req, err := http.NewRequest("POST", urls, body)
18151 if err != nil {
18152 return nil, err
18153 }
18154 req.Header = reqHeaders
18155 googleapi.Expand(req.URL, map[string]string{
18156 "packageName": c.packageName,
18157 "orderId": c.orderId,
18158 })
18159 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18160 }
18161
18162
18163 func (c *OrdersRefundCall) Do(opts ...googleapi.CallOption) error {
18164 gensupport.SetOptions(c.urlParams_, opts...)
18165 res, err := c.doRequest("json")
18166 if err != nil {
18167 return err
18168 }
18169 defer googleapi.CloseBody(res)
18170 if err := googleapi.CheckResponse(res); err != nil {
18171 return gensupport.WrapError(err)
18172 }
18173 return nil
18174 }
18175
18176 type PurchasesProductsAcknowledgeCall struct {
18177 s *Service
18178 packageName string
18179 productId string
18180 token string
18181 productpurchasesacknowledgerequest *ProductPurchasesAcknowledgeRequest
18182 urlParams_ gensupport.URLParams
18183 ctx_ context.Context
18184 header_ http.Header
18185 }
18186
18187
18188
18189
18190
18191
18192
18193
18194 func (r *PurchasesProductsService) Acknowledge(packageName string, productId string, token string, productpurchasesacknowledgerequest *ProductPurchasesAcknowledgeRequest) *PurchasesProductsAcknowledgeCall {
18195 c := &PurchasesProductsAcknowledgeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18196 c.packageName = packageName
18197 c.productId = productId
18198 c.token = token
18199 c.productpurchasesacknowledgerequest = productpurchasesacknowledgerequest
18200 return c
18201 }
18202
18203
18204
18205
18206 func (c *PurchasesProductsAcknowledgeCall) Fields(s ...googleapi.Field) *PurchasesProductsAcknowledgeCall {
18207 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18208 return c
18209 }
18210
18211
18212 func (c *PurchasesProductsAcknowledgeCall) Context(ctx context.Context) *PurchasesProductsAcknowledgeCall {
18213 c.ctx_ = ctx
18214 return c
18215 }
18216
18217
18218
18219 func (c *PurchasesProductsAcknowledgeCall) Header() http.Header {
18220 if c.header_ == nil {
18221 c.header_ = make(http.Header)
18222 }
18223 return c.header_
18224 }
18225
18226 func (c *PurchasesProductsAcknowledgeCall) doRequest(alt string) (*http.Response, error) {
18227 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
18228 var body io.Reader = nil
18229 body, err := googleapi.WithoutDataWrapper.JSONReader(c.productpurchasesacknowledgerequest)
18230 if err != nil {
18231 return nil, err
18232 }
18233 c.urlParams_.Set("alt", alt)
18234 c.urlParams_.Set("prettyPrint", "false")
18235 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/products/{productId}/tokens/{token}:acknowledge")
18236 urls += "?" + c.urlParams_.Encode()
18237 req, err := http.NewRequest("POST", urls, body)
18238 if err != nil {
18239 return nil, err
18240 }
18241 req.Header = reqHeaders
18242 googleapi.Expand(req.URL, map[string]string{
18243 "packageName": c.packageName,
18244 "productId": c.productId,
18245 "token": c.token,
18246 })
18247 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18248 }
18249
18250
18251 func (c *PurchasesProductsAcknowledgeCall) Do(opts ...googleapi.CallOption) error {
18252 gensupport.SetOptions(c.urlParams_, opts...)
18253 res, err := c.doRequest("json")
18254 if err != nil {
18255 return err
18256 }
18257 defer googleapi.CloseBody(res)
18258 if err := googleapi.CheckResponse(res); err != nil {
18259 return gensupport.WrapError(err)
18260 }
18261 return nil
18262 }
18263
18264 type PurchasesProductsConsumeCall struct {
18265 s *Service
18266 packageName string
18267 productId string
18268 token string
18269 urlParams_ gensupport.URLParams
18270 ctx_ context.Context
18271 header_ http.Header
18272 }
18273
18274
18275
18276
18277
18278
18279
18280
18281 func (r *PurchasesProductsService) Consume(packageName string, productId string, token string) *PurchasesProductsConsumeCall {
18282 c := &PurchasesProductsConsumeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18283 c.packageName = packageName
18284 c.productId = productId
18285 c.token = token
18286 return c
18287 }
18288
18289
18290
18291
18292 func (c *PurchasesProductsConsumeCall) Fields(s ...googleapi.Field) *PurchasesProductsConsumeCall {
18293 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18294 return c
18295 }
18296
18297
18298 func (c *PurchasesProductsConsumeCall) Context(ctx context.Context) *PurchasesProductsConsumeCall {
18299 c.ctx_ = ctx
18300 return c
18301 }
18302
18303
18304
18305 func (c *PurchasesProductsConsumeCall) Header() http.Header {
18306 if c.header_ == nil {
18307 c.header_ = make(http.Header)
18308 }
18309 return c.header_
18310 }
18311
18312 func (c *PurchasesProductsConsumeCall) doRequest(alt string) (*http.Response, error) {
18313 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
18314 var body io.Reader = nil
18315 c.urlParams_.Set("alt", alt)
18316 c.urlParams_.Set("prettyPrint", "false")
18317 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/products/{productId}/tokens/{token}:consume")
18318 urls += "?" + c.urlParams_.Encode()
18319 req, err := http.NewRequest("POST", urls, body)
18320 if err != nil {
18321 return nil, err
18322 }
18323 req.Header = reqHeaders
18324 googleapi.Expand(req.URL, map[string]string{
18325 "packageName": c.packageName,
18326 "productId": c.productId,
18327 "token": c.token,
18328 })
18329 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18330 }
18331
18332
18333 func (c *PurchasesProductsConsumeCall) Do(opts ...googleapi.CallOption) error {
18334 gensupport.SetOptions(c.urlParams_, opts...)
18335 res, err := c.doRequest("json")
18336 if err != nil {
18337 return err
18338 }
18339 defer googleapi.CloseBody(res)
18340 if err := googleapi.CheckResponse(res); err != nil {
18341 return gensupport.WrapError(err)
18342 }
18343 return nil
18344 }
18345
18346 type PurchasesProductsGetCall struct {
18347 s *Service
18348 packageName string
18349 productId string
18350 token string
18351 urlParams_ gensupport.URLParams
18352 ifNoneMatch_ string
18353 ctx_ context.Context
18354 header_ http.Header
18355 }
18356
18357
18358
18359
18360
18361
18362
18363
18364 func (r *PurchasesProductsService) Get(packageName string, productId string, token string) *PurchasesProductsGetCall {
18365 c := &PurchasesProductsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18366 c.packageName = packageName
18367 c.productId = productId
18368 c.token = token
18369 return c
18370 }
18371
18372
18373
18374
18375 func (c *PurchasesProductsGetCall) Fields(s ...googleapi.Field) *PurchasesProductsGetCall {
18376 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18377 return c
18378 }
18379
18380
18381
18382
18383 func (c *PurchasesProductsGetCall) IfNoneMatch(entityTag string) *PurchasesProductsGetCall {
18384 c.ifNoneMatch_ = entityTag
18385 return c
18386 }
18387
18388
18389 func (c *PurchasesProductsGetCall) Context(ctx context.Context) *PurchasesProductsGetCall {
18390 c.ctx_ = ctx
18391 return c
18392 }
18393
18394
18395
18396 func (c *PurchasesProductsGetCall) Header() http.Header {
18397 if c.header_ == nil {
18398 c.header_ = make(http.Header)
18399 }
18400 return c.header_
18401 }
18402
18403 func (c *PurchasesProductsGetCall) doRequest(alt string) (*http.Response, error) {
18404 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
18405 if c.ifNoneMatch_ != "" {
18406 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18407 }
18408 var body io.Reader = nil
18409 c.urlParams_.Set("alt", alt)
18410 c.urlParams_.Set("prettyPrint", "false")
18411 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/products/{productId}/tokens/{token}")
18412 urls += "?" + c.urlParams_.Encode()
18413 req, err := http.NewRequest("GET", urls, body)
18414 if err != nil {
18415 return nil, err
18416 }
18417 req.Header = reqHeaders
18418 googleapi.Expand(req.URL, map[string]string{
18419 "packageName": c.packageName,
18420 "productId": c.productId,
18421 "token": c.token,
18422 })
18423 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18424 }
18425
18426
18427
18428
18429
18430
18431
18432 func (c *PurchasesProductsGetCall) Do(opts ...googleapi.CallOption) (*ProductPurchase, error) {
18433 gensupport.SetOptions(c.urlParams_, opts...)
18434 res, err := c.doRequest("json")
18435 if res != nil && res.StatusCode == http.StatusNotModified {
18436 if res.Body != nil {
18437 res.Body.Close()
18438 }
18439 return nil, gensupport.WrapError(&googleapi.Error{
18440 Code: res.StatusCode,
18441 Header: res.Header,
18442 })
18443 }
18444 if err != nil {
18445 return nil, err
18446 }
18447 defer googleapi.CloseBody(res)
18448 if err := googleapi.CheckResponse(res); err != nil {
18449 return nil, gensupport.WrapError(err)
18450 }
18451 ret := &ProductPurchase{
18452 ServerResponse: googleapi.ServerResponse{
18453 Header: res.Header,
18454 HTTPStatusCode: res.StatusCode,
18455 },
18456 }
18457 target := &ret
18458 if err := gensupport.DecodeResponse(target, res); err != nil {
18459 return nil, err
18460 }
18461 return ret, nil
18462 }
18463
18464 type PurchasesSubscriptionsAcknowledgeCall struct {
18465 s *Service
18466 packageName string
18467 subscriptionId string
18468 token string
18469 subscriptionpurchasesacknowledgerequest *SubscriptionPurchasesAcknowledgeRequest
18470 urlParams_ gensupport.URLParams
18471 ctx_ context.Context
18472 header_ http.Header
18473 }
18474
18475
18476
18477
18478
18479
18480
18481
18482 func (r *PurchasesSubscriptionsService) Acknowledge(packageName string, subscriptionId string, token string, subscriptionpurchasesacknowledgerequest *SubscriptionPurchasesAcknowledgeRequest) *PurchasesSubscriptionsAcknowledgeCall {
18483 c := &PurchasesSubscriptionsAcknowledgeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18484 c.packageName = packageName
18485 c.subscriptionId = subscriptionId
18486 c.token = token
18487 c.subscriptionpurchasesacknowledgerequest = subscriptionpurchasesacknowledgerequest
18488 return c
18489 }
18490
18491
18492
18493
18494 func (c *PurchasesSubscriptionsAcknowledgeCall) Fields(s ...googleapi.Field) *PurchasesSubscriptionsAcknowledgeCall {
18495 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18496 return c
18497 }
18498
18499
18500 func (c *PurchasesSubscriptionsAcknowledgeCall) Context(ctx context.Context) *PurchasesSubscriptionsAcknowledgeCall {
18501 c.ctx_ = ctx
18502 return c
18503 }
18504
18505
18506
18507 func (c *PurchasesSubscriptionsAcknowledgeCall) Header() http.Header {
18508 if c.header_ == nil {
18509 c.header_ = make(http.Header)
18510 }
18511 return c.header_
18512 }
18513
18514 func (c *PurchasesSubscriptionsAcknowledgeCall) doRequest(alt string) (*http.Response, error) {
18515 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
18516 var body io.Reader = nil
18517 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subscriptionpurchasesacknowledgerequest)
18518 if err != nil {
18519 return nil, err
18520 }
18521 c.urlParams_.Set("alt", alt)
18522 c.urlParams_.Set("prettyPrint", "false")
18523 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/subscriptions/{subscriptionId}/tokens/{token}:acknowledge")
18524 urls += "?" + c.urlParams_.Encode()
18525 req, err := http.NewRequest("POST", urls, body)
18526 if err != nil {
18527 return nil, err
18528 }
18529 req.Header = reqHeaders
18530 googleapi.Expand(req.URL, map[string]string{
18531 "packageName": c.packageName,
18532 "subscriptionId": c.subscriptionId,
18533 "token": c.token,
18534 })
18535 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18536 }
18537
18538
18539 func (c *PurchasesSubscriptionsAcknowledgeCall) Do(opts ...googleapi.CallOption) error {
18540 gensupport.SetOptions(c.urlParams_, opts...)
18541 res, err := c.doRequest("json")
18542 if err != nil {
18543 return err
18544 }
18545 defer googleapi.CloseBody(res)
18546 if err := googleapi.CheckResponse(res); err != nil {
18547 return gensupport.WrapError(err)
18548 }
18549 return nil
18550 }
18551
18552 type PurchasesSubscriptionsCancelCall struct {
18553 s *Service
18554 packageName string
18555 subscriptionId string
18556 token string
18557 urlParams_ gensupport.URLParams
18558 ctx_ context.Context
18559 header_ http.Header
18560 }
18561
18562
18563
18564
18565
18566
18567
18568
18569
18570 func (r *PurchasesSubscriptionsService) Cancel(packageName string, subscriptionId string, token string) *PurchasesSubscriptionsCancelCall {
18571 c := &PurchasesSubscriptionsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18572 c.packageName = packageName
18573 c.subscriptionId = subscriptionId
18574 c.token = token
18575 return c
18576 }
18577
18578
18579
18580
18581 func (c *PurchasesSubscriptionsCancelCall) Fields(s ...googleapi.Field) *PurchasesSubscriptionsCancelCall {
18582 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18583 return c
18584 }
18585
18586
18587 func (c *PurchasesSubscriptionsCancelCall) Context(ctx context.Context) *PurchasesSubscriptionsCancelCall {
18588 c.ctx_ = ctx
18589 return c
18590 }
18591
18592
18593
18594 func (c *PurchasesSubscriptionsCancelCall) Header() http.Header {
18595 if c.header_ == nil {
18596 c.header_ = make(http.Header)
18597 }
18598 return c.header_
18599 }
18600
18601 func (c *PurchasesSubscriptionsCancelCall) doRequest(alt string) (*http.Response, error) {
18602 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
18603 var body io.Reader = nil
18604 c.urlParams_.Set("alt", alt)
18605 c.urlParams_.Set("prettyPrint", "false")
18606 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/subscriptions/{subscriptionId}/tokens/{token}:cancel")
18607 urls += "?" + c.urlParams_.Encode()
18608 req, err := http.NewRequest("POST", urls, body)
18609 if err != nil {
18610 return nil, err
18611 }
18612 req.Header = reqHeaders
18613 googleapi.Expand(req.URL, map[string]string{
18614 "packageName": c.packageName,
18615 "subscriptionId": c.subscriptionId,
18616 "token": c.token,
18617 })
18618 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18619 }
18620
18621
18622 func (c *PurchasesSubscriptionsCancelCall) Do(opts ...googleapi.CallOption) error {
18623 gensupport.SetOptions(c.urlParams_, opts...)
18624 res, err := c.doRequest("json")
18625 if err != nil {
18626 return err
18627 }
18628 defer googleapi.CloseBody(res)
18629 if err := googleapi.CheckResponse(res); err != nil {
18630 return gensupport.WrapError(err)
18631 }
18632 return nil
18633 }
18634
18635 type PurchasesSubscriptionsDeferCall struct {
18636 s *Service
18637 packageName string
18638 subscriptionId string
18639 token string
18640 subscriptionpurchasesdeferrequest *SubscriptionPurchasesDeferRequest
18641 urlParams_ gensupport.URLParams
18642 ctx_ context.Context
18643 header_ http.Header
18644 }
18645
18646
18647
18648
18649
18650
18651
18652
18653
18654 func (r *PurchasesSubscriptionsService) Defer(packageName string, subscriptionId string, token string, subscriptionpurchasesdeferrequest *SubscriptionPurchasesDeferRequest) *PurchasesSubscriptionsDeferCall {
18655 c := &PurchasesSubscriptionsDeferCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18656 c.packageName = packageName
18657 c.subscriptionId = subscriptionId
18658 c.token = token
18659 c.subscriptionpurchasesdeferrequest = subscriptionpurchasesdeferrequest
18660 return c
18661 }
18662
18663
18664
18665
18666 func (c *PurchasesSubscriptionsDeferCall) Fields(s ...googleapi.Field) *PurchasesSubscriptionsDeferCall {
18667 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18668 return c
18669 }
18670
18671
18672 func (c *PurchasesSubscriptionsDeferCall) Context(ctx context.Context) *PurchasesSubscriptionsDeferCall {
18673 c.ctx_ = ctx
18674 return c
18675 }
18676
18677
18678
18679 func (c *PurchasesSubscriptionsDeferCall) Header() http.Header {
18680 if c.header_ == nil {
18681 c.header_ = make(http.Header)
18682 }
18683 return c.header_
18684 }
18685
18686 func (c *PurchasesSubscriptionsDeferCall) doRequest(alt string) (*http.Response, error) {
18687 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
18688 var body io.Reader = nil
18689 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subscriptionpurchasesdeferrequest)
18690 if err != nil {
18691 return nil, err
18692 }
18693 c.urlParams_.Set("alt", alt)
18694 c.urlParams_.Set("prettyPrint", "false")
18695 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/subscriptions/{subscriptionId}/tokens/{token}:defer")
18696 urls += "?" + c.urlParams_.Encode()
18697 req, err := http.NewRequest("POST", urls, body)
18698 if err != nil {
18699 return nil, err
18700 }
18701 req.Header = reqHeaders
18702 googleapi.Expand(req.URL, map[string]string{
18703 "packageName": c.packageName,
18704 "subscriptionId": c.subscriptionId,
18705 "token": c.token,
18706 })
18707 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18708 }
18709
18710
18711
18712
18713
18714
18715
18716 func (c *PurchasesSubscriptionsDeferCall) Do(opts ...googleapi.CallOption) (*SubscriptionPurchasesDeferResponse, error) {
18717 gensupport.SetOptions(c.urlParams_, opts...)
18718 res, err := c.doRequest("json")
18719 if res != nil && res.StatusCode == http.StatusNotModified {
18720 if res.Body != nil {
18721 res.Body.Close()
18722 }
18723 return nil, gensupport.WrapError(&googleapi.Error{
18724 Code: res.StatusCode,
18725 Header: res.Header,
18726 })
18727 }
18728 if err != nil {
18729 return nil, err
18730 }
18731 defer googleapi.CloseBody(res)
18732 if err := googleapi.CheckResponse(res); err != nil {
18733 return nil, gensupport.WrapError(err)
18734 }
18735 ret := &SubscriptionPurchasesDeferResponse{
18736 ServerResponse: googleapi.ServerResponse{
18737 Header: res.Header,
18738 HTTPStatusCode: res.StatusCode,
18739 },
18740 }
18741 target := &ret
18742 if err := gensupport.DecodeResponse(target, res); err != nil {
18743 return nil, err
18744 }
18745 return ret, nil
18746 }
18747
18748 type PurchasesSubscriptionsGetCall struct {
18749 s *Service
18750 packageName string
18751 subscriptionId string
18752 token string
18753 urlParams_ gensupport.URLParams
18754 ifNoneMatch_ string
18755 ctx_ context.Context
18756 header_ http.Header
18757 }
18758
18759
18760
18761
18762
18763
18764
18765
18766
18767 func (r *PurchasesSubscriptionsService) Get(packageName string, subscriptionId string, token string) *PurchasesSubscriptionsGetCall {
18768 c := &PurchasesSubscriptionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18769 c.packageName = packageName
18770 c.subscriptionId = subscriptionId
18771 c.token = token
18772 return c
18773 }
18774
18775
18776
18777
18778 func (c *PurchasesSubscriptionsGetCall) Fields(s ...googleapi.Field) *PurchasesSubscriptionsGetCall {
18779 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18780 return c
18781 }
18782
18783
18784
18785
18786 func (c *PurchasesSubscriptionsGetCall) IfNoneMatch(entityTag string) *PurchasesSubscriptionsGetCall {
18787 c.ifNoneMatch_ = entityTag
18788 return c
18789 }
18790
18791
18792 func (c *PurchasesSubscriptionsGetCall) Context(ctx context.Context) *PurchasesSubscriptionsGetCall {
18793 c.ctx_ = ctx
18794 return c
18795 }
18796
18797
18798
18799 func (c *PurchasesSubscriptionsGetCall) Header() http.Header {
18800 if c.header_ == nil {
18801 c.header_ = make(http.Header)
18802 }
18803 return c.header_
18804 }
18805
18806 func (c *PurchasesSubscriptionsGetCall) doRequest(alt string) (*http.Response, error) {
18807 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
18808 if c.ifNoneMatch_ != "" {
18809 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18810 }
18811 var body io.Reader = nil
18812 c.urlParams_.Set("alt", alt)
18813 c.urlParams_.Set("prettyPrint", "false")
18814 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/subscriptions/{subscriptionId}/tokens/{token}")
18815 urls += "?" + c.urlParams_.Encode()
18816 req, err := http.NewRequest("GET", urls, body)
18817 if err != nil {
18818 return nil, err
18819 }
18820 req.Header = reqHeaders
18821 googleapi.Expand(req.URL, map[string]string{
18822 "packageName": c.packageName,
18823 "subscriptionId": c.subscriptionId,
18824 "token": c.token,
18825 })
18826 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18827 }
18828
18829
18830
18831
18832
18833
18834
18835 func (c *PurchasesSubscriptionsGetCall) Do(opts ...googleapi.CallOption) (*SubscriptionPurchase, error) {
18836 gensupport.SetOptions(c.urlParams_, opts...)
18837 res, err := c.doRequest("json")
18838 if res != nil && res.StatusCode == http.StatusNotModified {
18839 if res.Body != nil {
18840 res.Body.Close()
18841 }
18842 return nil, gensupport.WrapError(&googleapi.Error{
18843 Code: res.StatusCode,
18844 Header: res.Header,
18845 })
18846 }
18847 if err != nil {
18848 return nil, err
18849 }
18850 defer googleapi.CloseBody(res)
18851 if err := googleapi.CheckResponse(res); err != nil {
18852 return nil, gensupport.WrapError(err)
18853 }
18854 ret := &SubscriptionPurchase{
18855 ServerResponse: googleapi.ServerResponse{
18856 Header: res.Header,
18857 HTTPStatusCode: res.StatusCode,
18858 },
18859 }
18860 target := &ret
18861 if err := gensupport.DecodeResponse(target, res); err != nil {
18862 return nil, err
18863 }
18864 return ret, nil
18865 }
18866
18867 type PurchasesSubscriptionsRefundCall struct {
18868 s *Service
18869 packageName string
18870 subscriptionId string
18871 token string
18872 urlParams_ gensupport.URLParams
18873 ctx_ context.Context
18874 header_ http.Header
18875 }
18876
18877
18878
18879
18880
18881
18882
18883
18884
18885
18886 func (r *PurchasesSubscriptionsService) Refund(packageName string, subscriptionId string, token string) *PurchasesSubscriptionsRefundCall {
18887 c := &PurchasesSubscriptionsRefundCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18888 c.packageName = packageName
18889 c.subscriptionId = subscriptionId
18890 c.token = token
18891 return c
18892 }
18893
18894
18895
18896
18897 func (c *PurchasesSubscriptionsRefundCall) Fields(s ...googleapi.Field) *PurchasesSubscriptionsRefundCall {
18898 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18899 return c
18900 }
18901
18902
18903 func (c *PurchasesSubscriptionsRefundCall) Context(ctx context.Context) *PurchasesSubscriptionsRefundCall {
18904 c.ctx_ = ctx
18905 return c
18906 }
18907
18908
18909
18910 func (c *PurchasesSubscriptionsRefundCall) Header() http.Header {
18911 if c.header_ == nil {
18912 c.header_ = make(http.Header)
18913 }
18914 return c.header_
18915 }
18916
18917 func (c *PurchasesSubscriptionsRefundCall) doRequest(alt string) (*http.Response, error) {
18918 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
18919 var body io.Reader = nil
18920 c.urlParams_.Set("alt", alt)
18921 c.urlParams_.Set("prettyPrint", "false")
18922 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/subscriptions/{subscriptionId}/tokens/{token}:refund")
18923 urls += "?" + c.urlParams_.Encode()
18924 req, err := http.NewRequest("POST", urls, body)
18925 if err != nil {
18926 return nil, err
18927 }
18928 req.Header = reqHeaders
18929 googleapi.Expand(req.URL, map[string]string{
18930 "packageName": c.packageName,
18931 "subscriptionId": c.subscriptionId,
18932 "token": c.token,
18933 })
18934 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18935 }
18936
18937
18938 func (c *PurchasesSubscriptionsRefundCall) Do(opts ...googleapi.CallOption) error {
18939 gensupport.SetOptions(c.urlParams_, opts...)
18940 res, err := c.doRequest("json")
18941 if err != nil {
18942 return err
18943 }
18944 defer googleapi.CloseBody(res)
18945 if err := googleapi.CheckResponse(res); err != nil {
18946 return gensupport.WrapError(err)
18947 }
18948 return nil
18949 }
18950
18951 type PurchasesSubscriptionsRevokeCall struct {
18952 s *Service
18953 packageName string
18954 subscriptionId string
18955 token string
18956 urlParams_ gensupport.URLParams
18957 ctx_ context.Context
18958 header_ http.Header
18959 }
18960
18961
18962
18963
18964
18965
18966
18967
18968
18969
18970 func (r *PurchasesSubscriptionsService) Revoke(packageName string, subscriptionId string, token string) *PurchasesSubscriptionsRevokeCall {
18971 c := &PurchasesSubscriptionsRevokeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18972 c.packageName = packageName
18973 c.subscriptionId = subscriptionId
18974 c.token = token
18975 return c
18976 }
18977
18978
18979
18980
18981 func (c *PurchasesSubscriptionsRevokeCall) Fields(s ...googleapi.Field) *PurchasesSubscriptionsRevokeCall {
18982 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18983 return c
18984 }
18985
18986
18987 func (c *PurchasesSubscriptionsRevokeCall) Context(ctx context.Context) *PurchasesSubscriptionsRevokeCall {
18988 c.ctx_ = ctx
18989 return c
18990 }
18991
18992
18993
18994 func (c *PurchasesSubscriptionsRevokeCall) Header() http.Header {
18995 if c.header_ == nil {
18996 c.header_ = make(http.Header)
18997 }
18998 return c.header_
18999 }
19000
19001 func (c *PurchasesSubscriptionsRevokeCall) doRequest(alt string) (*http.Response, error) {
19002 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
19003 var body io.Reader = nil
19004 c.urlParams_.Set("alt", alt)
19005 c.urlParams_.Set("prettyPrint", "false")
19006 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/subscriptions/{subscriptionId}/tokens/{token}:revoke")
19007 urls += "?" + c.urlParams_.Encode()
19008 req, err := http.NewRequest("POST", urls, body)
19009 if err != nil {
19010 return nil, err
19011 }
19012 req.Header = reqHeaders
19013 googleapi.Expand(req.URL, map[string]string{
19014 "packageName": c.packageName,
19015 "subscriptionId": c.subscriptionId,
19016 "token": c.token,
19017 })
19018 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19019 }
19020
19021
19022 func (c *PurchasesSubscriptionsRevokeCall) Do(opts ...googleapi.CallOption) error {
19023 gensupport.SetOptions(c.urlParams_, opts...)
19024 res, err := c.doRequest("json")
19025 if err != nil {
19026 return err
19027 }
19028 defer googleapi.CloseBody(res)
19029 if err := googleapi.CheckResponse(res); err != nil {
19030 return gensupport.WrapError(err)
19031 }
19032 return nil
19033 }
19034
19035 type PurchasesSubscriptionsv2GetCall struct {
19036 s *Service
19037 packageName string
19038 token string
19039 urlParams_ gensupport.URLParams
19040 ifNoneMatch_ string
19041 ctx_ context.Context
19042 header_ http.Header
19043 }
19044
19045
19046
19047
19048
19049
19050
19051 func (r *PurchasesSubscriptionsv2Service) Get(packageName string, token string) *PurchasesSubscriptionsv2GetCall {
19052 c := &PurchasesSubscriptionsv2GetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19053 c.packageName = packageName
19054 c.token = token
19055 return c
19056 }
19057
19058
19059
19060
19061 func (c *PurchasesSubscriptionsv2GetCall) Fields(s ...googleapi.Field) *PurchasesSubscriptionsv2GetCall {
19062 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19063 return c
19064 }
19065
19066
19067
19068
19069 func (c *PurchasesSubscriptionsv2GetCall) IfNoneMatch(entityTag string) *PurchasesSubscriptionsv2GetCall {
19070 c.ifNoneMatch_ = entityTag
19071 return c
19072 }
19073
19074
19075 func (c *PurchasesSubscriptionsv2GetCall) Context(ctx context.Context) *PurchasesSubscriptionsv2GetCall {
19076 c.ctx_ = ctx
19077 return c
19078 }
19079
19080
19081
19082 func (c *PurchasesSubscriptionsv2GetCall) Header() http.Header {
19083 if c.header_ == nil {
19084 c.header_ = make(http.Header)
19085 }
19086 return c.header_
19087 }
19088
19089 func (c *PurchasesSubscriptionsv2GetCall) doRequest(alt string) (*http.Response, error) {
19090 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
19091 if c.ifNoneMatch_ != "" {
19092 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19093 }
19094 var body io.Reader = nil
19095 c.urlParams_.Set("alt", alt)
19096 c.urlParams_.Set("prettyPrint", "false")
19097 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/subscriptionsv2/tokens/{token}")
19098 urls += "?" + c.urlParams_.Encode()
19099 req, err := http.NewRequest("GET", urls, body)
19100 if err != nil {
19101 return nil, err
19102 }
19103 req.Header = reqHeaders
19104 googleapi.Expand(req.URL, map[string]string{
19105 "packageName": c.packageName,
19106 "token": c.token,
19107 })
19108 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19109 }
19110
19111
19112
19113
19114
19115
19116
19117 func (c *PurchasesSubscriptionsv2GetCall) Do(opts ...googleapi.CallOption) (*SubscriptionPurchaseV2, error) {
19118 gensupport.SetOptions(c.urlParams_, opts...)
19119 res, err := c.doRequest("json")
19120 if res != nil && res.StatusCode == http.StatusNotModified {
19121 if res.Body != nil {
19122 res.Body.Close()
19123 }
19124 return nil, gensupport.WrapError(&googleapi.Error{
19125 Code: res.StatusCode,
19126 Header: res.Header,
19127 })
19128 }
19129 if err != nil {
19130 return nil, err
19131 }
19132 defer googleapi.CloseBody(res)
19133 if err := googleapi.CheckResponse(res); err != nil {
19134 return nil, gensupport.WrapError(err)
19135 }
19136 ret := &SubscriptionPurchaseV2{
19137 ServerResponse: googleapi.ServerResponse{
19138 Header: res.Header,
19139 HTTPStatusCode: res.StatusCode,
19140 },
19141 }
19142 target := &ret
19143 if err := gensupport.DecodeResponse(target, res); err != nil {
19144 return nil, err
19145 }
19146 return ret, nil
19147 }
19148
19149 type PurchasesSubscriptionsv2RevokeCall struct {
19150 s *Service
19151 packageName string
19152 token string
19153 revokesubscriptionpurchaserequest *RevokeSubscriptionPurchaseRequest
19154 urlParams_ gensupport.URLParams
19155 ctx_ context.Context
19156 header_ http.Header
19157 }
19158
19159
19160
19161
19162
19163
19164
19165 func (r *PurchasesSubscriptionsv2Service) Revoke(packageName string, token string, revokesubscriptionpurchaserequest *RevokeSubscriptionPurchaseRequest) *PurchasesSubscriptionsv2RevokeCall {
19166 c := &PurchasesSubscriptionsv2RevokeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19167 c.packageName = packageName
19168 c.token = token
19169 c.revokesubscriptionpurchaserequest = revokesubscriptionpurchaserequest
19170 return c
19171 }
19172
19173
19174
19175
19176 func (c *PurchasesSubscriptionsv2RevokeCall) Fields(s ...googleapi.Field) *PurchasesSubscriptionsv2RevokeCall {
19177 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19178 return c
19179 }
19180
19181
19182 func (c *PurchasesSubscriptionsv2RevokeCall) Context(ctx context.Context) *PurchasesSubscriptionsv2RevokeCall {
19183 c.ctx_ = ctx
19184 return c
19185 }
19186
19187
19188
19189 func (c *PurchasesSubscriptionsv2RevokeCall) Header() http.Header {
19190 if c.header_ == nil {
19191 c.header_ = make(http.Header)
19192 }
19193 return c.header_
19194 }
19195
19196 func (c *PurchasesSubscriptionsv2RevokeCall) doRequest(alt string) (*http.Response, error) {
19197 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
19198 var body io.Reader = nil
19199 body, err := googleapi.WithoutDataWrapper.JSONReader(c.revokesubscriptionpurchaserequest)
19200 if err != nil {
19201 return nil, err
19202 }
19203 c.urlParams_.Set("alt", alt)
19204 c.urlParams_.Set("prettyPrint", "false")
19205 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/subscriptionsv2/tokens/{token}:revoke")
19206 urls += "?" + c.urlParams_.Encode()
19207 req, err := http.NewRequest("POST", urls, body)
19208 if err != nil {
19209 return nil, err
19210 }
19211 req.Header = reqHeaders
19212 googleapi.Expand(req.URL, map[string]string{
19213 "packageName": c.packageName,
19214 "token": c.token,
19215 })
19216 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19217 }
19218
19219
19220
19221
19222
19223
19224
19225 func (c *PurchasesSubscriptionsv2RevokeCall) Do(opts ...googleapi.CallOption) (*RevokeSubscriptionPurchaseResponse, error) {
19226 gensupport.SetOptions(c.urlParams_, opts...)
19227 res, err := c.doRequest("json")
19228 if res != nil && res.StatusCode == http.StatusNotModified {
19229 if res.Body != nil {
19230 res.Body.Close()
19231 }
19232 return nil, gensupport.WrapError(&googleapi.Error{
19233 Code: res.StatusCode,
19234 Header: res.Header,
19235 })
19236 }
19237 if err != nil {
19238 return nil, err
19239 }
19240 defer googleapi.CloseBody(res)
19241 if err := googleapi.CheckResponse(res); err != nil {
19242 return nil, gensupport.WrapError(err)
19243 }
19244 ret := &RevokeSubscriptionPurchaseResponse{
19245 ServerResponse: googleapi.ServerResponse{
19246 Header: res.Header,
19247 HTTPStatusCode: res.StatusCode,
19248 },
19249 }
19250 target := &ret
19251 if err := gensupport.DecodeResponse(target, res); err != nil {
19252 return nil, err
19253 }
19254 return ret, nil
19255 }
19256
19257 type PurchasesVoidedpurchasesListCall struct {
19258 s *Service
19259 packageName string
19260 urlParams_ gensupport.URLParams
19261 ifNoneMatch_ string
19262 ctx_ context.Context
19263 header_ http.Header
19264 }
19265
19266
19267
19268
19269
19270 func (r *PurchasesVoidedpurchasesService) List(packageName string) *PurchasesVoidedpurchasesListCall {
19271 c := &PurchasesVoidedpurchasesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19272 c.packageName = packageName
19273 return c
19274 }
19275
19276
19277
19278
19279
19280
19281
19282
19283 func (c *PurchasesVoidedpurchasesListCall) EndTime(endTime int64) *PurchasesVoidedpurchasesListCall {
19284 c.urlParams_.Set("endTime", fmt.Sprint(endTime))
19285 return c
19286 }
19287
19288
19289
19290
19291
19292
19293
19294 func (c *PurchasesVoidedpurchasesListCall) IncludeQuantityBasedPartialRefund(includeQuantityBasedPartialRefund bool) *PurchasesVoidedpurchasesListCall {
19295 c.urlParams_.Set("includeQuantityBasedPartialRefund", fmt.Sprint(includeQuantityBasedPartialRefund))
19296 return c
19297 }
19298
19299
19300
19301
19302 func (c *PurchasesVoidedpurchasesListCall) MaxResults(maxResults int64) *PurchasesVoidedpurchasesListCall {
19303 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
19304 return c
19305 }
19306
19307
19308
19309
19310 func (c *PurchasesVoidedpurchasesListCall) StartIndex(startIndex int64) *PurchasesVoidedpurchasesListCall {
19311 c.urlParams_.Set("startIndex", fmt.Sprint(startIndex))
19312 return c
19313 }
19314
19315
19316
19317
19318
19319
19320
19321
19322 func (c *PurchasesVoidedpurchasesListCall) StartTime(startTime int64) *PurchasesVoidedpurchasesListCall {
19323 c.urlParams_.Set("startTime", fmt.Sprint(startTime))
19324 return c
19325 }
19326
19327
19328
19329
19330 func (c *PurchasesVoidedpurchasesListCall) Token(token string) *PurchasesVoidedpurchasesListCall {
19331 c.urlParams_.Set("token", token)
19332 return c
19333 }
19334
19335
19336
19337
19338
19339
19340
19341
19342
19343
19344 func (c *PurchasesVoidedpurchasesListCall) Type(type_ int64) *PurchasesVoidedpurchasesListCall {
19345 c.urlParams_.Set("type", fmt.Sprint(type_))
19346 return c
19347 }
19348
19349
19350
19351
19352 func (c *PurchasesVoidedpurchasesListCall) Fields(s ...googleapi.Field) *PurchasesVoidedpurchasesListCall {
19353 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19354 return c
19355 }
19356
19357
19358
19359
19360 func (c *PurchasesVoidedpurchasesListCall) IfNoneMatch(entityTag string) *PurchasesVoidedpurchasesListCall {
19361 c.ifNoneMatch_ = entityTag
19362 return c
19363 }
19364
19365
19366 func (c *PurchasesVoidedpurchasesListCall) Context(ctx context.Context) *PurchasesVoidedpurchasesListCall {
19367 c.ctx_ = ctx
19368 return c
19369 }
19370
19371
19372
19373 func (c *PurchasesVoidedpurchasesListCall) Header() http.Header {
19374 if c.header_ == nil {
19375 c.header_ = make(http.Header)
19376 }
19377 return c.header_
19378 }
19379
19380 func (c *PurchasesVoidedpurchasesListCall) doRequest(alt string) (*http.Response, error) {
19381 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
19382 if c.ifNoneMatch_ != "" {
19383 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19384 }
19385 var body io.Reader = nil
19386 c.urlParams_.Set("alt", alt)
19387 c.urlParams_.Set("prettyPrint", "false")
19388 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/purchases/voidedpurchases")
19389 urls += "?" + c.urlParams_.Encode()
19390 req, err := http.NewRequest("GET", urls, body)
19391 if err != nil {
19392 return nil, err
19393 }
19394 req.Header = reqHeaders
19395 googleapi.Expand(req.URL, map[string]string{
19396 "packageName": c.packageName,
19397 })
19398 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19399 }
19400
19401
19402
19403
19404
19405
19406
19407 func (c *PurchasesVoidedpurchasesListCall) Do(opts ...googleapi.CallOption) (*VoidedPurchasesListResponse, error) {
19408 gensupport.SetOptions(c.urlParams_, opts...)
19409 res, err := c.doRequest("json")
19410 if res != nil && res.StatusCode == http.StatusNotModified {
19411 if res.Body != nil {
19412 res.Body.Close()
19413 }
19414 return nil, gensupport.WrapError(&googleapi.Error{
19415 Code: res.StatusCode,
19416 Header: res.Header,
19417 })
19418 }
19419 if err != nil {
19420 return nil, err
19421 }
19422 defer googleapi.CloseBody(res)
19423 if err := googleapi.CheckResponse(res); err != nil {
19424 return nil, gensupport.WrapError(err)
19425 }
19426 ret := &VoidedPurchasesListResponse{
19427 ServerResponse: googleapi.ServerResponse{
19428 Header: res.Header,
19429 HTTPStatusCode: res.StatusCode,
19430 },
19431 }
19432 target := &ret
19433 if err := gensupport.DecodeResponse(target, res); err != nil {
19434 return nil, err
19435 }
19436 return ret, nil
19437 }
19438
19439 type ReviewsGetCall struct {
19440 s *Service
19441 packageName string
19442 reviewId string
19443 urlParams_ gensupport.URLParams
19444 ifNoneMatch_ string
19445 ctx_ context.Context
19446 header_ http.Header
19447 }
19448
19449
19450
19451
19452
19453 func (r *ReviewsService) Get(packageName string, reviewId string) *ReviewsGetCall {
19454 c := &ReviewsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19455 c.packageName = packageName
19456 c.reviewId = reviewId
19457 return c
19458 }
19459
19460
19461
19462 func (c *ReviewsGetCall) TranslationLanguage(translationLanguage string) *ReviewsGetCall {
19463 c.urlParams_.Set("translationLanguage", translationLanguage)
19464 return c
19465 }
19466
19467
19468
19469
19470 func (c *ReviewsGetCall) Fields(s ...googleapi.Field) *ReviewsGetCall {
19471 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19472 return c
19473 }
19474
19475
19476
19477
19478 func (c *ReviewsGetCall) IfNoneMatch(entityTag string) *ReviewsGetCall {
19479 c.ifNoneMatch_ = entityTag
19480 return c
19481 }
19482
19483
19484 func (c *ReviewsGetCall) Context(ctx context.Context) *ReviewsGetCall {
19485 c.ctx_ = ctx
19486 return c
19487 }
19488
19489
19490
19491 func (c *ReviewsGetCall) Header() http.Header {
19492 if c.header_ == nil {
19493 c.header_ = make(http.Header)
19494 }
19495 return c.header_
19496 }
19497
19498 func (c *ReviewsGetCall) doRequest(alt string) (*http.Response, error) {
19499 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
19500 if c.ifNoneMatch_ != "" {
19501 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19502 }
19503 var body io.Reader = nil
19504 c.urlParams_.Set("alt", alt)
19505 c.urlParams_.Set("prettyPrint", "false")
19506 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/reviews/{reviewId}")
19507 urls += "?" + c.urlParams_.Encode()
19508 req, err := http.NewRequest("GET", urls, body)
19509 if err != nil {
19510 return nil, err
19511 }
19512 req.Header = reqHeaders
19513 googleapi.Expand(req.URL, map[string]string{
19514 "packageName": c.packageName,
19515 "reviewId": c.reviewId,
19516 })
19517 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19518 }
19519
19520
19521
19522
19523
19524
19525 func (c *ReviewsGetCall) Do(opts ...googleapi.CallOption) (*Review, error) {
19526 gensupport.SetOptions(c.urlParams_, opts...)
19527 res, err := c.doRequest("json")
19528 if res != nil && res.StatusCode == http.StatusNotModified {
19529 if res.Body != nil {
19530 res.Body.Close()
19531 }
19532 return nil, gensupport.WrapError(&googleapi.Error{
19533 Code: res.StatusCode,
19534 Header: res.Header,
19535 })
19536 }
19537 if err != nil {
19538 return nil, err
19539 }
19540 defer googleapi.CloseBody(res)
19541 if err := googleapi.CheckResponse(res); err != nil {
19542 return nil, gensupport.WrapError(err)
19543 }
19544 ret := &Review{
19545 ServerResponse: googleapi.ServerResponse{
19546 Header: res.Header,
19547 HTTPStatusCode: res.StatusCode,
19548 },
19549 }
19550 target := &ret
19551 if err := gensupport.DecodeResponse(target, res); err != nil {
19552 return nil, err
19553 }
19554 return ret, nil
19555 }
19556
19557 type ReviewsListCall struct {
19558 s *Service
19559 packageName string
19560 urlParams_ gensupport.URLParams
19561 ifNoneMatch_ string
19562 ctx_ context.Context
19563 header_ http.Header
19564 }
19565
19566
19567
19568
19569 func (r *ReviewsService) List(packageName string) *ReviewsListCall {
19570 c := &ReviewsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19571 c.packageName = packageName
19572 return c
19573 }
19574
19575
19576
19577 func (c *ReviewsListCall) MaxResults(maxResults int64) *ReviewsListCall {
19578 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
19579 return c
19580 }
19581
19582
19583
19584 func (c *ReviewsListCall) StartIndex(startIndex int64) *ReviewsListCall {
19585 c.urlParams_.Set("startIndex", fmt.Sprint(startIndex))
19586 return c
19587 }
19588
19589
19590
19591 func (c *ReviewsListCall) Token(token string) *ReviewsListCall {
19592 c.urlParams_.Set("token", token)
19593 return c
19594 }
19595
19596
19597
19598 func (c *ReviewsListCall) TranslationLanguage(translationLanguage string) *ReviewsListCall {
19599 c.urlParams_.Set("translationLanguage", translationLanguage)
19600 return c
19601 }
19602
19603
19604
19605
19606 func (c *ReviewsListCall) Fields(s ...googleapi.Field) *ReviewsListCall {
19607 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19608 return c
19609 }
19610
19611
19612
19613
19614 func (c *ReviewsListCall) IfNoneMatch(entityTag string) *ReviewsListCall {
19615 c.ifNoneMatch_ = entityTag
19616 return c
19617 }
19618
19619
19620 func (c *ReviewsListCall) Context(ctx context.Context) *ReviewsListCall {
19621 c.ctx_ = ctx
19622 return c
19623 }
19624
19625
19626
19627 func (c *ReviewsListCall) Header() http.Header {
19628 if c.header_ == nil {
19629 c.header_ = make(http.Header)
19630 }
19631 return c.header_
19632 }
19633
19634 func (c *ReviewsListCall) doRequest(alt string) (*http.Response, error) {
19635 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
19636 if c.ifNoneMatch_ != "" {
19637 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19638 }
19639 var body io.Reader = nil
19640 c.urlParams_.Set("alt", alt)
19641 c.urlParams_.Set("prettyPrint", "false")
19642 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/reviews")
19643 urls += "?" + c.urlParams_.Encode()
19644 req, err := http.NewRequest("GET", urls, body)
19645 if err != nil {
19646 return nil, err
19647 }
19648 req.Header = reqHeaders
19649 googleapi.Expand(req.URL, map[string]string{
19650 "packageName": c.packageName,
19651 })
19652 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19653 }
19654
19655
19656
19657
19658
19659
19660
19661 func (c *ReviewsListCall) Do(opts ...googleapi.CallOption) (*ReviewsListResponse, error) {
19662 gensupport.SetOptions(c.urlParams_, opts...)
19663 res, err := c.doRequest("json")
19664 if res != nil && res.StatusCode == http.StatusNotModified {
19665 if res.Body != nil {
19666 res.Body.Close()
19667 }
19668 return nil, gensupport.WrapError(&googleapi.Error{
19669 Code: res.StatusCode,
19670 Header: res.Header,
19671 })
19672 }
19673 if err != nil {
19674 return nil, err
19675 }
19676 defer googleapi.CloseBody(res)
19677 if err := googleapi.CheckResponse(res); err != nil {
19678 return nil, gensupport.WrapError(err)
19679 }
19680 ret := &ReviewsListResponse{
19681 ServerResponse: googleapi.ServerResponse{
19682 Header: res.Header,
19683 HTTPStatusCode: res.StatusCode,
19684 },
19685 }
19686 target := &ret
19687 if err := gensupport.DecodeResponse(target, res); err != nil {
19688 return nil, err
19689 }
19690 return ret, nil
19691 }
19692
19693 type ReviewsReplyCall struct {
19694 s *Service
19695 packageName string
19696 reviewId string
19697 reviewsreplyrequest *ReviewsReplyRequest
19698 urlParams_ gensupport.URLParams
19699 ctx_ context.Context
19700 header_ http.Header
19701 }
19702
19703
19704
19705
19706
19707 func (r *ReviewsService) Reply(packageName string, reviewId string, reviewsreplyrequest *ReviewsReplyRequest) *ReviewsReplyCall {
19708 c := &ReviewsReplyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19709 c.packageName = packageName
19710 c.reviewId = reviewId
19711 c.reviewsreplyrequest = reviewsreplyrequest
19712 return c
19713 }
19714
19715
19716
19717
19718 func (c *ReviewsReplyCall) Fields(s ...googleapi.Field) *ReviewsReplyCall {
19719 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19720 return c
19721 }
19722
19723
19724 func (c *ReviewsReplyCall) Context(ctx context.Context) *ReviewsReplyCall {
19725 c.ctx_ = ctx
19726 return c
19727 }
19728
19729
19730
19731 func (c *ReviewsReplyCall) Header() http.Header {
19732 if c.header_ == nil {
19733 c.header_ = make(http.Header)
19734 }
19735 return c.header_
19736 }
19737
19738 func (c *ReviewsReplyCall) doRequest(alt string) (*http.Response, error) {
19739 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
19740 var body io.Reader = nil
19741 body, err := googleapi.WithoutDataWrapper.JSONReader(c.reviewsreplyrequest)
19742 if err != nil {
19743 return nil, err
19744 }
19745 c.urlParams_.Set("alt", alt)
19746 c.urlParams_.Set("prettyPrint", "false")
19747 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/reviews/{reviewId}:reply")
19748 urls += "?" + c.urlParams_.Encode()
19749 req, err := http.NewRequest("POST", urls, body)
19750 if err != nil {
19751 return nil, err
19752 }
19753 req.Header = reqHeaders
19754 googleapi.Expand(req.URL, map[string]string{
19755 "packageName": c.packageName,
19756 "reviewId": c.reviewId,
19757 })
19758 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19759 }
19760
19761
19762
19763
19764
19765
19766
19767 func (c *ReviewsReplyCall) Do(opts ...googleapi.CallOption) (*ReviewsReplyResponse, error) {
19768 gensupport.SetOptions(c.urlParams_, opts...)
19769 res, err := c.doRequest("json")
19770 if res != nil && res.StatusCode == http.StatusNotModified {
19771 if res.Body != nil {
19772 res.Body.Close()
19773 }
19774 return nil, gensupport.WrapError(&googleapi.Error{
19775 Code: res.StatusCode,
19776 Header: res.Header,
19777 })
19778 }
19779 if err != nil {
19780 return nil, err
19781 }
19782 defer googleapi.CloseBody(res)
19783 if err := googleapi.CheckResponse(res); err != nil {
19784 return nil, gensupport.WrapError(err)
19785 }
19786 ret := &ReviewsReplyResponse{
19787 ServerResponse: googleapi.ServerResponse{
19788 Header: res.Header,
19789 HTTPStatusCode: res.StatusCode,
19790 },
19791 }
19792 target := &ret
19793 if err := gensupport.DecodeResponse(target, res); err != nil {
19794 return nil, err
19795 }
19796 return ret, nil
19797 }
19798
19799 type SystemapksVariantsCreateCall struct {
19800 s *Service
19801 packageName string
19802 versionCode int64
19803 variant *Variant
19804 urlParams_ gensupport.URLParams
19805 ctx_ context.Context
19806 header_ http.Header
19807 }
19808
19809
19810
19811
19812
19813
19814 func (r *SystemapksVariantsService) Create(packageName string, versionCode int64, variant *Variant) *SystemapksVariantsCreateCall {
19815 c := &SystemapksVariantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19816 c.packageName = packageName
19817 c.versionCode = versionCode
19818 c.variant = variant
19819 return c
19820 }
19821
19822
19823
19824
19825 func (c *SystemapksVariantsCreateCall) Fields(s ...googleapi.Field) *SystemapksVariantsCreateCall {
19826 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19827 return c
19828 }
19829
19830
19831 func (c *SystemapksVariantsCreateCall) Context(ctx context.Context) *SystemapksVariantsCreateCall {
19832 c.ctx_ = ctx
19833 return c
19834 }
19835
19836
19837
19838 func (c *SystemapksVariantsCreateCall) Header() http.Header {
19839 if c.header_ == nil {
19840 c.header_ = make(http.Header)
19841 }
19842 return c.header_
19843 }
19844
19845 func (c *SystemapksVariantsCreateCall) doRequest(alt string) (*http.Response, error) {
19846 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
19847 var body io.Reader = nil
19848 body, err := googleapi.WithoutDataWrapper.JSONReader(c.variant)
19849 if err != nil {
19850 return nil, err
19851 }
19852 c.urlParams_.Set("alt", alt)
19853 c.urlParams_.Set("prettyPrint", "false")
19854 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/systemApks/{versionCode}/variants")
19855 urls += "?" + c.urlParams_.Encode()
19856 req, err := http.NewRequest("POST", urls, body)
19857 if err != nil {
19858 return nil, err
19859 }
19860 req.Header = reqHeaders
19861 googleapi.Expand(req.URL, map[string]string{
19862 "packageName": c.packageName,
19863 "versionCode": strconv.FormatInt(c.versionCode, 10),
19864 })
19865 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19866 }
19867
19868
19869
19870
19871
19872
19873 func (c *SystemapksVariantsCreateCall) Do(opts ...googleapi.CallOption) (*Variant, error) {
19874 gensupport.SetOptions(c.urlParams_, opts...)
19875 res, err := c.doRequest("json")
19876 if res != nil && res.StatusCode == http.StatusNotModified {
19877 if res.Body != nil {
19878 res.Body.Close()
19879 }
19880 return nil, gensupport.WrapError(&googleapi.Error{
19881 Code: res.StatusCode,
19882 Header: res.Header,
19883 })
19884 }
19885 if err != nil {
19886 return nil, err
19887 }
19888 defer googleapi.CloseBody(res)
19889 if err := googleapi.CheckResponse(res); err != nil {
19890 return nil, gensupport.WrapError(err)
19891 }
19892 ret := &Variant{
19893 ServerResponse: googleapi.ServerResponse{
19894 Header: res.Header,
19895 HTTPStatusCode: res.StatusCode,
19896 },
19897 }
19898 target := &ret
19899 if err := gensupport.DecodeResponse(target, res); err != nil {
19900 return nil, err
19901 }
19902 return ret, nil
19903 }
19904
19905 type SystemapksVariantsDownloadCall struct {
19906 s *Service
19907 packageName string
19908 versionCode int64
19909 variantId int64
19910 urlParams_ gensupport.URLParams
19911 ifNoneMatch_ string
19912 ctx_ context.Context
19913 header_ http.Header
19914 }
19915
19916
19917
19918
19919
19920
19921
19922 func (r *SystemapksVariantsService) Download(packageName string, versionCode int64, variantId int64) *SystemapksVariantsDownloadCall {
19923 c := &SystemapksVariantsDownloadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19924 c.packageName = packageName
19925 c.versionCode = versionCode
19926 c.variantId = variantId
19927 return c
19928 }
19929
19930
19931
19932
19933 func (c *SystemapksVariantsDownloadCall) Fields(s ...googleapi.Field) *SystemapksVariantsDownloadCall {
19934 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19935 return c
19936 }
19937
19938
19939
19940
19941 func (c *SystemapksVariantsDownloadCall) IfNoneMatch(entityTag string) *SystemapksVariantsDownloadCall {
19942 c.ifNoneMatch_ = entityTag
19943 return c
19944 }
19945
19946
19947 func (c *SystemapksVariantsDownloadCall) Context(ctx context.Context) *SystemapksVariantsDownloadCall {
19948 c.ctx_ = ctx
19949 return c
19950 }
19951
19952
19953
19954 func (c *SystemapksVariantsDownloadCall) Header() http.Header {
19955 if c.header_ == nil {
19956 c.header_ = make(http.Header)
19957 }
19958 return c.header_
19959 }
19960
19961 func (c *SystemapksVariantsDownloadCall) doRequest(alt string) (*http.Response, error) {
19962 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
19963 if c.ifNoneMatch_ != "" {
19964 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19965 }
19966 var body io.Reader = nil
19967 c.urlParams_.Set("alt", alt)
19968 c.urlParams_.Set("prettyPrint", "false")
19969 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/systemApks/{versionCode}/variants/{variantId}:download")
19970 urls += "?" + c.urlParams_.Encode()
19971 req, err := http.NewRequest("GET", urls, body)
19972 if err != nil {
19973 return nil, err
19974 }
19975 req.Header = reqHeaders
19976 googleapi.Expand(req.URL, map[string]string{
19977 "packageName": c.packageName,
19978 "versionCode": strconv.FormatInt(c.versionCode, 10),
19979 "variantId": strconv.FormatInt(c.variantId, 10),
19980 })
19981 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19982 }
19983
19984
19985
19986
19987 func (c *SystemapksVariantsDownloadCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
19988 gensupport.SetOptions(c.urlParams_, opts...)
19989 res, err := c.doRequest("media")
19990 if err != nil {
19991 return nil, err
19992 }
19993 if err := googleapi.CheckResponse(res); err != nil {
19994 res.Body.Close()
19995 return nil, gensupport.WrapError(err)
19996 }
19997 return res, nil
19998 }
19999
20000
20001 func (c *SystemapksVariantsDownloadCall) Do(opts ...googleapi.CallOption) error {
20002 gensupport.SetOptions(c.urlParams_, opts...)
20003 res, err := c.doRequest("json")
20004 if err != nil {
20005 return err
20006 }
20007 defer googleapi.CloseBody(res)
20008 if err := googleapi.CheckResponse(res); err != nil {
20009 return gensupport.WrapError(err)
20010 }
20011 return nil
20012 }
20013
20014 type SystemapksVariantsGetCall struct {
20015 s *Service
20016 packageName string
20017 versionCode int64
20018 variantId int64
20019 urlParams_ gensupport.URLParams
20020 ifNoneMatch_ string
20021 ctx_ context.Context
20022 header_ http.Header
20023 }
20024
20025
20026
20027
20028
20029
20030 func (r *SystemapksVariantsService) Get(packageName string, versionCode int64, variantId int64) *SystemapksVariantsGetCall {
20031 c := &SystemapksVariantsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20032 c.packageName = packageName
20033 c.versionCode = versionCode
20034 c.variantId = variantId
20035 return c
20036 }
20037
20038
20039
20040
20041 func (c *SystemapksVariantsGetCall) Fields(s ...googleapi.Field) *SystemapksVariantsGetCall {
20042 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20043 return c
20044 }
20045
20046
20047
20048
20049 func (c *SystemapksVariantsGetCall) IfNoneMatch(entityTag string) *SystemapksVariantsGetCall {
20050 c.ifNoneMatch_ = entityTag
20051 return c
20052 }
20053
20054
20055 func (c *SystemapksVariantsGetCall) Context(ctx context.Context) *SystemapksVariantsGetCall {
20056 c.ctx_ = ctx
20057 return c
20058 }
20059
20060
20061
20062 func (c *SystemapksVariantsGetCall) Header() http.Header {
20063 if c.header_ == nil {
20064 c.header_ = make(http.Header)
20065 }
20066 return c.header_
20067 }
20068
20069 func (c *SystemapksVariantsGetCall) doRequest(alt string) (*http.Response, error) {
20070 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
20071 if c.ifNoneMatch_ != "" {
20072 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20073 }
20074 var body io.Reader = nil
20075 c.urlParams_.Set("alt", alt)
20076 c.urlParams_.Set("prettyPrint", "false")
20077 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/systemApks/{versionCode}/variants/{variantId}")
20078 urls += "?" + c.urlParams_.Encode()
20079 req, err := http.NewRequest("GET", urls, body)
20080 if err != nil {
20081 return nil, err
20082 }
20083 req.Header = reqHeaders
20084 googleapi.Expand(req.URL, map[string]string{
20085 "packageName": c.packageName,
20086 "versionCode": strconv.FormatInt(c.versionCode, 10),
20087 "variantId": strconv.FormatInt(c.variantId, 10),
20088 })
20089 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20090 }
20091
20092
20093
20094
20095
20096
20097 func (c *SystemapksVariantsGetCall) Do(opts ...googleapi.CallOption) (*Variant, error) {
20098 gensupport.SetOptions(c.urlParams_, opts...)
20099 res, err := c.doRequest("json")
20100 if res != nil && res.StatusCode == http.StatusNotModified {
20101 if res.Body != nil {
20102 res.Body.Close()
20103 }
20104 return nil, gensupport.WrapError(&googleapi.Error{
20105 Code: res.StatusCode,
20106 Header: res.Header,
20107 })
20108 }
20109 if err != nil {
20110 return nil, err
20111 }
20112 defer googleapi.CloseBody(res)
20113 if err := googleapi.CheckResponse(res); err != nil {
20114 return nil, gensupport.WrapError(err)
20115 }
20116 ret := &Variant{
20117 ServerResponse: googleapi.ServerResponse{
20118 Header: res.Header,
20119 HTTPStatusCode: res.StatusCode,
20120 },
20121 }
20122 target := &ret
20123 if err := gensupport.DecodeResponse(target, res); err != nil {
20124 return nil, err
20125 }
20126 return ret, nil
20127 }
20128
20129 type SystemapksVariantsListCall struct {
20130 s *Service
20131 packageName string
20132 versionCode int64
20133 urlParams_ gensupport.URLParams
20134 ifNoneMatch_ string
20135 ctx_ context.Context
20136 header_ http.Header
20137 }
20138
20139
20140
20141
20142
20143 func (r *SystemapksVariantsService) List(packageName string, versionCode int64) *SystemapksVariantsListCall {
20144 c := &SystemapksVariantsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20145 c.packageName = packageName
20146 c.versionCode = versionCode
20147 return c
20148 }
20149
20150
20151
20152
20153 func (c *SystemapksVariantsListCall) Fields(s ...googleapi.Field) *SystemapksVariantsListCall {
20154 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20155 return c
20156 }
20157
20158
20159
20160
20161 func (c *SystemapksVariantsListCall) IfNoneMatch(entityTag string) *SystemapksVariantsListCall {
20162 c.ifNoneMatch_ = entityTag
20163 return c
20164 }
20165
20166
20167 func (c *SystemapksVariantsListCall) Context(ctx context.Context) *SystemapksVariantsListCall {
20168 c.ctx_ = ctx
20169 return c
20170 }
20171
20172
20173
20174 func (c *SystemapksVariantsListCall) Header() http.Header {
20175 if c.header_ == nil {
20176 c.header_ = make(http.Header)
20177 }
20178 return c.header_
20179 }
20180
20181 func (c *SystemapksVariantsListCall) doRequest(alt string) (*http.Response, error) {
20182 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
20183 if c.ifNoneMatch_ != "" {
20184 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20185 }
20186 var body io.Reader = nil
20187 c.urlParams_.Set("alt", alt)
20188 c.urlParams_.Set("prettyPrint", "false")
20189 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/systemApks/{versionCode}/variants")
20190 urls += "?" + c.urlParams_.Encode()
20191 req, err := http.NewRequest("GET", urls, body)
20192 if err != nil {
20193 return nil, err
20194 }
20195 req.Header = reqHeaders
20196 googleapi.Expand(req.URL, map[string]string{
20197 "packageName": c.packageName,
20198 "versionCode": strconv.FormatInt(c.versionCode, 10),
20199 })
20200 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20201 }
20202
20203
20204
20205
20206
20207
20208
20209 func (c *SystemapksVariantsListCall) Do(opts ...googleapi.CallOption) (*SystemApksListResponse, error) {
20210 gensupport.SetOptions(c.urlParams_, opts...)
20211 res, err := c.doRequest("json")
20212 if res != nil && res.StatusCode == http.StatusNotModified {
20213 if res.Body != nil {
20214 res.Body.Close()
20215 }
20216 return nil, gensupport.WrapError(&googleapi.Error{
20217 Code: res.StatusCode,
20218 Header: res.Header,
20219 })
20220 }
20221 if err != nil {
20222 return nil, err
20223 }
20224 defer googleapi.CloseBody(res)
20225 if err := googleapi.CheckResponse(res); err != nil {
20226 return nil, gensupport.WrapError(err)
20227 }
20228 ret := &SystemApksListResponse{
20229 ServerResponse: googleapi.ServerResponse{
20230 Header: res.Header,
20231 HTTPStatusCode: res.StatusCode,
20232 },
20233 }
20234 target := &ret
20235 if err := gensupport.DecodeResponse(target, res); err != nil {
20236 return nil, err
20237 }
20238 return ret, nil
20239 }
20240
20241 type UsersCreateCall struct {
20242 s *Service
20243 parent string
20244 user *User
20245 urlParams_ gensupport.URLParams
20246 ctx_ context.Context
20247 header_ http.Header
20248 }
20249
20250
20251
20252
20253
20254 func (r *UsersService) Create(parent string, user *User) *UsersCreateCall {
20255 c := &UsersCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20256 c.parent = parent
20257 c.user = user
20258 return c
20259 }
20260
20261
20262
20263
20264 func (c *UsersCreateCall) Fields(s ...googleapi.Field) *UsersCreateCall {
20265 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20266 return c
20267 }
20268
20269
20270 func (c *UsersCreateCall) Context(ctx context.Context) *UsersCreateCall {
20271 c.ctx_ = ctx
20272 return c
20273 }
20274
20275
20276
20277 func (c *UsersCreateCall) Header() http.Header {
20278 if c.header_ == nil {
20279 c.header_ = make(http.Header)
20280 }
20281 return c.header_
20282 }
20283
20284 func (c *UsersCreateCall) doRequest(alt string) (*http.Response, error) {
20285 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
20286 var body io.Reader = nil
20287 body, err := googleapi.WithoutDataWrapper.JSONReader(c.user)
20288 if err != nil {
20289 return nil, err
20290 }
20291 c.urlParams_.Set("alt", alt)
20292 c.urlParams_.Set("prettyPrint", "false")
20293 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+parent}/users")
20294 urls += "?" + c.urlParams_.Encode()
20295 req, err := http.NewRequest("POST", urls, body)
20296 if err != nil {
20297 return nil, err
20298 }
20299 req.Header = reqHeaders
20300 googleapi.Expand(req.URL, map[string]string{
20301 "parent": c.parent,
20302 })
20303 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20304 }
20305
20306
20307
20308
20309
20310
20311 func (c *UsersCreateCall) Do(opts ...googleapi.CallOption) (*User, error) {
20312 gensupport.SetOptions(c.urlParams_, opts...)
20313 res, err := c.doRequest("json")
20314 if res != nil && res.StatusCode == http.StatusNotModified {
20315 if res.Body != nil {
20316 res.Body.Close()
20317 }
20318 return nil, gensupport.WrapError(&googleapi.Error{
20319 Code: res.StatusCode,
20320 Header: res.Header,
20321 })
20322 }
20323 if err != nil {
20324 return nil, err
20325 }
20326 defer googleapi.CloseBody(res)
20327 if err := googleapi.CheckResponse(res); err != nil {
20328 return nil, gensupport.WrapError(err)
20329 }
20330 ret := &User{
20331 ServerResponse: googleapi.ServerResponse{
20332 Header: res.Header,
20333 HTTPStatusCode: res.StatusCode,
20334 },
20335 }
20336 target := &ret
20337 if err := gensupport.DecodeResponse(target, res); err != nil {
20338 return nil, err
20339 }
20340 return ret, nil
20341 }
20342
20343 type UsersDeleteCall struct {
20344 s *Service
20345 name string
20346 urlParams_ gensupport.URLParams
20347 ctx_ context.Context
20348 header_ http.Header
20349 }
20350
20351
20352
20353
20354
20355 func (r *UsersService) Delete(name string) *UsersDeleteCall {
20356 c := &UsersDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20357 c.name = name
20358 return c
20359 }
20360
20361
20362
20363
20364 func (c *UsersDeleteCall) Fields(s ...googleapi.Field) *UsersDeleteCall {
20365 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20366 return c
20367 }
20368
20369
20370 func (c *UsersDeleteCall) Context(ctx context.Context) *UsersDeleteCall {
20371 c.ctx_ = ctx
20372 return c
20373 }
20374
20375
20376
20377 func (c *UsersDeleteCall) Header() http.Header {
20378 if c.header_ == nil {
20379 c.header_ = make(http.Header)
20380 }
20381 return c.header_
20382 }
20383
20384 func (c *UsersDeleteCall) doRequest(alt string) (*http.Response, error) {
20385 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
20386 var body io.Reader = nil
20387 c.urlParams_.Set("alt", alt)
20388 c.urlParams_.Set("prettyPrint", "false")
20389 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}")
20390 urls += "?" + c.urlParams_.Encode()
20391 req, err := http.NewRequest("DELETE", urls, body)
20392 if err != nil {
20393 return nil, err
20394 }
20395 req.Header = reqHeaders
20396 googleapi.Expand(req.URL, map[string]string{
20397 "name": c.name,
20398 })
20399 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20400 }
20401
20402
20403 func (c *UsersDeleteCall) Do(opts ...googleapi.CallOption) error {
20404 gensupport.SetOptions(c.urlParams_, opts...)
20405 res, err := c.doRequest("json")
20406 if err != nil {
20407 return err
20408 }
20409 defer googleapi.CloseBody(res)
20410 if err := googleapi.CheckResponse(res); err != nil {
20411 return gensupport.WrapError(err)
20412 }
20413 return nil
20414 }
20415
20416 type UsersListCall struct {
20417 s *Service
20418 parent string
20419 urlParams_ gensupport.URLParams
20420 ifNoneMatch_ string
20421 ctx_ context.Context
20422 header_ http.Header
20423 }
20424
20425
20426
20427
20428
20429 func (r *UsersService) List(parent string) *UsersListCall {
20430 c := &UsersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20431 c.parent = parent
20432 return c
20433 }
20434
20435
20436
20437 func (c *UsersListCall) PageSize(pageSize int64) *UsersListCall {
20438 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
20439 return c
20440 }
20441
20442
20443
20444 func (c *UsersListCall) PageToken(pageToken string) *UsersListCall {
20445 c.urlParams_.Set("pageToken", pageToken)
20446 return c
20447 }
20448
20449
20450
20451
20452 func (c *UsersListCall) Fields(s ...googleapi.Field) *UsersListCall {
20453 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20454 return c
20455 }
20456
20457
20458
20459
20460 func (c *UsersListCall) IfNoneMatch(entityTag string) *UsersListCall {
20461 c.ifNoneMatch_ = entityTag
20462 return c
20463 }
20464
20465
20466 func (c *UsersListCall) Context(ctx context.Context) *UsersListCall {
20467 c.ctx_ = ctx
20468 return c
20469 }
20470
20471
20472
20473 func (c *UsersListCall) Header() http.Header {
20474 if c.header_ == nil {
20475 c.header_ = make(http.Header)
20476 }
20477 return c.header_
20478 }
20479
20480 func (c *UsersListCall) doRequest(alt string) (*http.Response, error) {
20481 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
20482 if c.ifNoneMatch_ != "" {
20483 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20484 }
20485 var body io.Reader = nil
20486 c.urlParams_.Set("alt", alt)
20487 c.urlParams_.Set("prettyPrint", "false")
20488 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+parent}/users")
20489 urls += "?" + c.urlParams_.Encode()
20490 req, err := http.NewRequest("GET", urls, body)
20491 if err != nil {
20492 return nil, err
20493 }
20494 req.Header = reqHeaders
20495 googleapi.Expand(req.URL, map[string]string{
20496 "parent": c.parent,
20497 })
20498 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20499 }
20500
20501
20502
20503
20504
20505
20506
20507 func (c *UsersListCall) Do(opts ...googleapi.CallOption) (*ListUsersResponse, error) {
20508 gensupport.SetOptions(c.urlParams_, opts...)
20509 res, err := c.doRequest("json")
20510 if res != nil && res.StatusCode == http.StatusNotModified {
20511 if res.Body != nil {
20512 res.Body.Close()
20513 }
20514 return nil, gensupport.WrapError(&googleapi.Error{
20515 Code: res.StatusCode,
20516 Header: res.Header,
20517 })
20518 }
20519 if err != nil {
20520 return nil, err
20521 }
20522 defer googleapi.CloseBody(res)
20523 if err := googleapi.CheckResponse(res); err != nil {
20524 return nil, gensupport.WrapError(err)
20525 }
20526 ret := &ListUsersResponse{
20527 ServerResponse: googleapi.ServerResponse{
20528 Header: res.Header,
20529 HTTPStatusCode: res.StatusCode,
20530 },
20531 }
20532 target := &ret
20533 if err := gensupport.DecodeResponse(target, res); err != nil {
20534 return nil, err
20535 }
20536 return ret, nil
20537 }
20538
20539
20540
20541
20542 func (c *UsersListCall) Pages(ctx context.Context, f func(*ListUsersResponse) error) error {
20543 c.ctx_ = ctx
20544 defer c.PageToken(c.urlParams_.Get("pageToken"))
20545 for {
20546 x, err := c.Do()
20547 if err != nil {
20548 return err
20549 }
20550 if err := f(x); err != nil {
20551 return err
20552 }
20553 if x.NextPageToken == "" {
20554 return nil
20555 }
20556 c.PageToken(x.NextPageToken)
20557 }
20558 }
20559
20560 type UsersPatchCall struct {
20561 s *Service
20562 name string
20563 user *User
20564 urlParams_ gensupport.URLParams
20565 ctx_ context.Context
20566 header_ http.Header
20567 }
20568
20569
20570
20571
20572
20573 func (r *UsersService) Patch(name string, user *User) *UsersPatchCall {
20574 c := &UsersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20575 c.name = name
20576 c.user = user
20577 return c
20578 }
20579
20580
20581
20582 func (c *UsersPatchCall) UpdateMask(updateMask string) *UsersPatchCall {
20583 c.urlParams_.Set("updateMask", updateMask)
20584 return c
20585 }
20586
20587
20588
20589
20590 func (c *UsersPatchCall) Fields(s ...googleapi.Field) *UsersPatchCall {
20591 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20592 return c
20593 }
20594
20595
20596 func (c *UsersPatchCall) Context(ctx context.Context) *UsersPatchCall {
20597 c.ctx_ = ctx
20598 return c
20599 }
20600
20601
20602
20603 func (c *UsersPatchCall) Header() http.Header {
20604 if c.header_ == nil {
20605 c.header_ = make(http.Header)
20606 }
20607 return c.header_
20608 }
20609
20610 func (c *UsersPatchCall) doRequest(alt string) (*http.Response, error) {
20611 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
20612 var body io.Reader = nil
20613 body, err := googleapi.WithoutDataWrapper.JSONReader(c.user)
20614 if err != nil {
20615 return nil, err
20616 }
20617 c.urlParams_.Set("alt", alt)
20618 c.urlParams_.Set("prettyPrint", "false")
20619 urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}")
20620 urls += "?" + c.urlParams_.Encode()
20621 req, err := http.NewRequest("PATCH", urls, body)
20622 if err != nil {
20623 return nil, err
20624 }
20625 req.Header = reqHeaders
20626 googleapi.Expand(req.URL, map[string]string{
20627 "name": c.name,
20628 })
20629 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20630 }
20631
20632
20633
20634
20635
20636
20637 func (c *UsersPatchCall) Do(opts ...googleapi.CallOption) (*User, error) {
20638 gensupport.SetOptions(c.urlParams_, opts...)
20639 res, err := c.doRequest("json")
20640 if res != nil && res.StatusCode == http.StatusNotModified {
20641 if res.Body != nil {
20642 res.Body.Close()
20643 }
20644 return nil, gensupport.WrapError(&googleapi.Error{
20645 Code: res.StatusCode,
20646 Header: res.Header,
20647 })
20648 }
20649 if err != nil {
20650 return nil, err
20651 }
20652 defer googleapi.CloseBody(res)
20653 if err := googleapi.CheckResponse(res); err != nil {
20654 return nil, gensupport.WrapError(err)
20655 }
20656 ret := &User{
20657 ServerResponse: googleapi.ServerResponse{
20658 Header: res.Header,
20659 HTTPStatusCode: res.StatusCode,
20660 },
20661 }
20662 target := &ret
20663 if err := gensupport.DecodeResponse(target, res); err != nil {
20664 return nil, err
20665 }
20666 return ret, nil
20667 }
20668
View as plain text