OLD | NEW |
1 library googleapis.androidpublisher.v2; | 1 library googleapis.androidpublisher.v2; |
2 | 2 |
3 import "dart:core" as core; | 3 import "dart:core" as core; |
4 import "dart:collection" as collection; | 4 import "dart:collection" as collection; |
5 import "dart:async" as async; | 5 import "dart:async" as async; |
6 import "dart:convert" as convert; | 6 import "dart:convert" as convert; |
7 | 7 |
8 import "package:crypto/crypto.dart" as crypto; | 8 import "package:crypto/crypto.dart" as crypto; |
9 import 'package:http/http.dart' as http; | 9 import 'package:http/http.dart' as http; |
10 import '../src/common_internal.dart' as common_internal; | 10 import '../src/common_internal.dart' as common_internal; |
11 import '../common/common.dart' as common; | 11 import '../common/common.dart' as common; |
12 | 12 |
13 export '../common/common.dart' show ApiRequestError; | 13 export '../common/common.dart' show ApiRequestError; |
14 export '../common/common.dart' show DetailedApiRequestError; | 14 export '../common/common.dart' show DetailedApiRequestError; |
15 | 15 |
16 /** Lets Android application developers access their Google Play accounts. */ | 16 /** Lets Android application developers access their Google Play accounts. */ |
17 class AndroidpublisherApi { | 17 class AndroidpublisherApi { |
18 /** View and manage your Google Play Android Developer account */ | 18 /** View and manage your Google Play Android Developer account */ |
19 static const AndroidpublisherScope = "https://www.googleapis.com/auth/androidp
ublisher"; | 19 static const AndroidpublisherScope = "https://www.googleapis.com/auth/androidp
ublisher"; |
20 | 20 |
21 | 21 |
22 final common_internal.ApiRequester _requester; | 22 final common_internal.ApiRequester _requester; |
23 | 23 |
24 EditsResourceApi get edits => new EditsResourceApi(_requester); | 24 EditsResourceApi get edits => new EditsResourceApi(_requester); |
25 InappproductsResourceApi get inappproducts => new InappproductsResourceApi(_re
quester); | 25 InappproductsResourceApi get inappproducts => new InappproductsResourceApi(_re
quester); |
26 PurchasesResourceApi get purchases => new PurchasesResourceApi(_requester); | 26 PurchasesResourceApi get purchases => new PurchasesResourceApi(_requester); |
27 | 27 |
28 AndroidpublisherApi(http.Client client) : | 28 AndroidpublisherApi(http.Client client) : |
29 _requester = new common_internal.ApiRequester(client, "https://www.googlea
pis.com/", "/androidpublisher/v2/applications/"); | 29 _requester = new common_internal.ApiRequester(client, "https://www.googlea
pis.com/", "androidpublisher/v2/applications/"); |
30 } | 30 } |
31 | 31 |
32 | 32 |
33 /** Not documented yet. */ | 33 /** Not documented yet. */ |
34 class EditsResourceApi { | 34 class EditsResourceApi { |
35 final common_internal.ApiRequester _requester; | 35 final common_internal.ApiRequester _requester; |
36 | 36 |
37 EditsApklistingsResourceApi get apklistings => new EditsApklistingsResourceApi
(_requester); | 37 EditsApklistingsResourceApi get apklistings => new EditsApklistingsResourceApi
(_requester); |
38 EditsApksResourceApi get apks => new EditsApksResourceApi(_requester); | 38 EditsApksResourceApi get apks => new EditsApksResourceApi(_requester); |
39 EditsDetailsResourceApi get details => new EditsDetailsResourceApi(_requester)
; | 39 EditsDetailsResourceApi get details => new EditsDetailsResourceApi(_requester)
; |
(...skipping 2691 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2731 "POST", | 2731 "POST", |
2732 body: _body, | 2732 body: _body, |
2733 queryParams: _queryParams, | 2733 queryParams: _queryParams, |
2734 uploadOptions: _uploadOptions, | 2734 uploadOptions: _uploadOptions, |
2735 uploadMedia: _uploadMedia, | 2735 uploadMedia: _uploadMedia, |
2736 downloadOptions: _downloadOptions); | 2736 downloadOptions: _downloadOptions); |
2737 return _response.then((data) => null); | 2737 return _response.then((data) => null); |
2738 } | 2738 } |
2739 | 2739 |
2740 /** | 2740 /** |
| 2741 * Defers a user's subscription purchase until a specified future expiration |
| 2742 * time. |
| 2743 * |
| 2744 * [request] - The metadata request object. |
| 2745 * |
| 2746 * Request parameters: |
| 2747 * |
| 2748 * [packageName] - The package name of the application for which this |
| 2749 * subscription was purchased (for example, 'com.some.thing'). |
| 2750 * |
| 2751 * [subscriptionId] - The purchased subscription ID (for example, |
| 2752 * 'monthly001'). |
| 2753 * |
| 2754 * [token] - The token provided to the user's device when the subscription was |
| 2755 * purchased. |
| 2756 * |
| 2757 * Completes with a [SubscriptionPurchasesDeferResponse]. |
| 2758 * |
| 2759 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2760 * error. |
| 2761 * |
| 2762 * If the used [http.Client] completes with an error when making a REST call, |
| 2763 * this method will complete with the same error. |
| 2764 */ |
| 2765 async.Future<SubscriptionPurchasesDeferResponse> defer(SubscriptionPurchasesDe
ferRequest request, core.String packageName, core.String subscriptionId, core.St
ring token) { |
| 2766 var _url = null; |
| 2767 var _queryParams = new core.Map(); |
| 2768 var _uploadMedia = null; |
| 2769 var _uploadOptions = null; |
| 2770 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2771 var _body = null; |
| 2772 |
| 2773 if (request != null) { |
| 2774 _body = convert.JSON.encode((request).toJson()); |
| 2775 } |
| 2776 if (packageName == null) { |
| 2777 throw new core.ArgumentError("Parameter packageName is required."); |
| 2778 } |
| 2779 if (subscriptionId == null) { |
| 2780 throw new core.ArgumentError("Parameter subscriptionId is required."); |
| 2781 } |
| 2782 if (token == null) { |
| 2783 throw new core.ArgumentError("Parameter token is required."); |
| 2784 } |
| 2785 |
| 2786 |
| 2787 _url = common_internal.Escaper.ecapeVariable('$packageName') + '/purchases/s
ubscriptions/' + common_internal.Escaper.ecapeVariable('$subscriptionId') + '/to
kens/' + common_internal.Escaper.ecapeVariable('$token') + ':defer'; |
| 2788 |
| 2789 var _response = _requester.request(_url, |
| 2790 "POST", |
| 2791 body: _body, |
| 2792 queryParams: _queryParams, |
| 2793 uploadOptions: _uploadOptions, |
| 2794 uploadMedia: _uploadMedia, |
| 2795 downloadOptions: _downloadOptions); |
| 2796 return _response.then((data) => new SubscriptionPurchasesDeferResponse.fromJ
son(data)); |
| 2797 } |
| 2798 |
| 2799 /** |
2741 * Checks whether a user's subscription purchase is valid and returns its | 2800 * Checks whether a user's subscription purchase is valid and returns its |
2742 * expiry time. | 2801 * expiry time. |
2743 * | 2802 * |
2744 * Request parameters: | 2803 * Request parameters: |
2745 * | 2804 * |
2746 * [packageName] - The package name of the application for which this | 2805 * [packageName] - The package name of the application for which this |
2747 * subscription was purchased (for example, 'com.some.thing'). | 2806 * subscription was purchased (for example, 'com.some.thing'). |
2748 * | 2807 * |
2749 * [subscriptionId] - The purchased subscription ID (for example, | 2808 * [subscriptionId] - The purchased subscription ID (for example, |
2750 * 'monthly001'). | 2809 * 'monthly001'). |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2784 var _response = _requester.request(_url, | 2843 var _response = _requester.request(_url, |
2785 "GET", | 2844 "GET", |
2786 body: _body, | 2845 body: _body, |
2787 queryParams: _queryParams, | 2846 queryParams: _queryParams, |
2788 uploadOptions: _uploadOptions, | 2847 uploadOptions: _uploadOptions, |
2789 uploadMedia: _uploadMedia, | 2848 uploadMedia: _uploadMedia, |
2790 downloadOptions: _downloadOptions); | 2849 downloadOptions: _downloadOptions); |
2791 return _response.then((data) => new SubscriptionPurchase.fromJson(data)); | 2850 return _response.then((data) => new SubscriptionPurchase.fromJson(data)); |
2792 } | 2851 } |
2793 | 2852 |
| 2853 /** |
| 2854 * Refunds a user's subscription purchase, but the subscription remains valid |
| 2855 * until its expiration time and it will continue to recur. |
| 2856 * |
| 2857 * Request parameters: |
| 2858 * |
| 2859 * [packageName] - The package name of the application for which this |
| 2860 * subscription was purchased (for example, 'com.some.thing'). |
| 2861 * |
| 2862 * [subscriptionId] - The purchased subscription ID (for example, |
| 2863 * 'monthly001'). |
| 2864 * |
| 2865 * [token] - The token provided to the user's device when the subscription was |
| 2866 * purchased. |
| 2867 * |
| 2868 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2869 * error. |
| 2870 * |
| 2871 * If the used [http.Client] completes with an error when making a REST call, |
| 2872 * this method will complete with the same error. |
| 2873 */ |
| 2874 async.Future refund(core.String packageName, core.String subscriptionId, core.
String token) { |
| 2875 var _url = null; |
| 2876 var _queryParams = new core.Map(); |
| 2877 var _uploadMedia = null; |
| 2878 var _uploadOptions = null; |
| 2879 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2880 var _body = null; |
| 2881 |
| 2882 if (packageName == null) { |
| 2883 throw new core.ArgumentError("Parameter packageName is required."); |
| 2884 } |
| 2885 if (subscriptionId == null) { |
| 2886 throw new core.ArgumentError("Parameter subscriptionId is required."); |
| 2887 } |
| 2888 if (token == null) { |
| 2889 throw new core.ArgumentError("Parameter token is required."); |
| 2890 } |
| 2891 |
| 2892 _downloadOptions = null; |
| 2893 |
| 2894 _url = common_internal.Escaper.ecapeVariable('$packageName') + '/purchases/s
ubscriptions/' + common_internal.Escaper.ecapeVariable('$subscriptionId') + '/to
kens/' + common_internal.Escaper.ecapeVariable('$token') + ':refund'; |
| 2895 |
| 2896 var _response = _requester.request(_url, |
| 2897 "POST", |
| 2898 body: _body, |
| 2899 queryParams: _queryParams, |
| 2900 uploadOptions: _uploadOptions, |
| 2901 uploadMedia: _uploadMedia, |
| 2902 downloadOptions: _downloadOptions); |
| 2903 return _response.then((data) => null); |
| 2904 } |
| 2905 |
| 2906 /** |
| 2907 * Refunds and immediately revokes a user's subscription purchase. Access to |
| 2908 * the subscription will be terminated immediately and it will stop recurring. |
| 2909 * |
| 2910 * Request parameters: |
| 2911 * |
| 2912 * [packageName] - The package name of the application for which this |
| 2913 * subscription was purchased (for example, 'com.some.thing'). |
| 2914 * |
| 2915 * [subscriptionId] - The purchased subscription ID (for example, |
| 2916 * 'monthly001'). |
| 2917 * |
| 2918 * [token] - The token provided to the user's device when the subscription was |
| 2919 * purchased. |
| 2920 * |
| 2921 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2922 * error. |
| 2923 * |
| 2924 * If the used [http.Client] completes with an error when making a REST call, |
| 2925 * this method will complete with the same error. |
| 2926 */ |
| 2927 async.Future revoke(core.String packageName, core.String subscriptionId, core.
String token) { |
| 2928 var _url = null; |
| 2929 var _queryParams = new core.Map(); |
| 2930 var _uploadMedia = null; |
| 2931 var _uploadOptions = null; |
| 2932 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2933 var _body = null; |
| 2934 |
| 2935 if (packageName == null) { |
| 2936 throw new core.ArgumentError("Parameter packageName is required."); |
| 2937 } |
| 2938 if (subscriptionId == null) { |
| 2939 throw new core.ArgumentError("Parameter subscriptionId is required."); |
| 2940 } |
| 2941 if (token == null) { |
| 2942 throw new core.ArgumentError("Parameter token is required."); |
| 2943 } |
| 2944 |
| 2945 _downloadOptions = null; |
| 2946 |
| 2947 _url = common_internal.Escaper.ecapeVariable('$packageName') + '/purchases/s
ubscriptions/' + common_internal.Escaper.ecapeVariable('$subscriptionId') + '/to
kens/' + common_internal.Escaper.ecapeVariable('$token') + ':revoke'; |
| 2948 |
| 2949 var _response = _requester.request(_url, |
| 2950 "POST", |
| 2951 body: _body, |
| 2952 queryParams: _queryParams, |
| 2953 uploadOptions: _uploadOptions, |
| 2954 uploadMedia: _uploadMedia, |
| 2955 downloadOptions: _downloadOptions); |
| 2956 return _response.then((data) => null); |
| 2957 } |
| 2958 |
2794 } | 2959 } |
2795 | 2960 |
2796 | 2961 |
2797 | 2962 |
2798 /** Not documented yet. */ | 2963 /** Not documented yet. */ |
2799 class Apk { | 2964 class Apk { |
2800 /** Information about the binary payload of this APK. */ | 2965 /** Information about the binary payload of this APK. */ |
2801 ApkBinary binary; | 2966 ApkBinary binary; |
2802 | 2967 |
2803 /** The version code of the APK, as specified in the APK's manifest file. */ | 2968 /** The version code of the APK, as specified in the APK's manifest file. */ |
(...skipping 446 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3250 | 3415 |
3251 /** | 3416 /** |
3252 * Prices per buyer region. None of these prices should be zero. In-app | 3417 * Prices per buyer region. None of these prices should be zero. In-app |
3253 * products can never be free. | 3418 * products can never be free. |
3254 */ | 3419 */ |
3255 core.Map<core.String, Price> prices; | 3420 core.Map<core.String, Price> prices; |
3256 | 3421 |
3257 /** Purchase type enum value. Unmodifiable after creation. */ | 3422 /** Purchase type enum value. Unmodifiable after creation. */ |
3258 core.String purchaseType; | 3423 core.String purchaseType; |
3259 | 3424 |
| 3425 /** |
| 3426 * Definition of a season for a seasonal subscription. Can be defined only for |
| 3427 * yearly subscriptions. |
| 3428 */ |
| 3429 Season season; |
| 3430 |
3260 /** The stock-keeping-unit (SKU) of the product, unique within an app. */ | 3431 /** The stock-keeping-unit (SKU) of the product, unique within an app. */ |
3261 core.String sku; | 3432 core.String sku; |
3262 | 3433 |
3263 /** Not documented yet. */ | 3434 /** Not documented yet. */ |
3264 core.String status; | 3435 core.String status; |
3265 | 3436 |
3266 /** | 3437 /** |
3267 * The period of the subscription (if any), i.e. period at which payments must | 3438 * The period of the subscription (if any), i.e. period at which payments must |
3268 * happen. Defined as ISO 8601 duration, i.e. "P1M" for 1 month period. | 3439 * happen. Defined as ISO 8601 duration, i.e. "P1M" for 1 month period. |
3269 */ | 3440 */ |
(...skipping 22 matching lines...) Expand all Loading... |
3292 } | 3463 } |
3293 if (_json.containsKey("packageName")) { | 3464 if (_json.containsKey("packageName")) { |
3294 packageName = _json["packageName"]; | 3465 packageName = _json["packageName"]; |
3295 } | 3466 } |
3296 if (_json.containsKey("prices")) { | 3467 if (_json.containsKey("prices")) { |
3297 prices = common_internal.mapMap(_json["prices"], (item) => new Price.fromJ
son(item)); | 3468 prices = common_internal.mapMap(_json["prices"], (item) => new Price.fromJ
son(item)); |
3298 } | 3469 } |
3299 if (_json.containsKey("purchaseType")) { | 3470 if (_json.containsKey("purchaseType")) { |
3300 purchaseType = _json["purchaseType"]; | 3471 purchaseType = _json["purchaseType"]; |
3301 } | 3472 } |
| 3473 if (_json.containsKey("season")) { |
| 3474 season = new Season.fromJson(_json["season"]); |
| 3475 } |
3302 if (_json.containsKey("sku")) { | 3476 if (_json.containsKey("sku")) { |
3303 sku = _json["sku"]; | 3477 sku = _json["sku"]; |
3304 } | 3478 } |
3305 if (_json.containsKey("status")) { | 3479 if (_json.containsKey("status")) { |
3306 status = _json["status"]; | 3480 status = _json["status"]; |
3307 } | 3481 } |
3308 if (_json.containsKey("subscriptionPeriod")) { | 3482 if (_json.containsKey("subscriptionPeriod")) { |
3309 subscriptionPeriod = _json["subscriptionPeriod"]; | 3483 subscriptionPeriod = _json["subscriptionPeriod"]; |
3310 } | 3484 } |
3311 if (_json.containsKey("trialPeriod")) { | 3485 if (_json.containsKey("trialPeriod")) { |
(...skipping 14 matching lines...) Expand all Loading... |
3326 } | 3500 } |
3327 if (packageName != null) { | 3501 if (packageName != null) { |
3328 _json["packageName"] = packageName; | 3502 _json["packageName"] = packageName; |
3329 } | 3503 } |
3330 if (prices != null) { | 3504 if (prices != null) { |
3331 _json["prices"] = common_internal.mapMap(prices, (item) => (item).toJson()
); | 3505 _json["prices"] = common_internal.mapMap(prices, (item) => (item).toJson()
); |
3332 } | 3506 } |
3333 if (purchaseType != null) { | 3507 if (purchaseType != null) { |
3334 _json["purchaseType"] = purchaseType; | 3508 _json["purchaseType"] = purchaseType; |
3335 } | 3509 } |
| 3510 if (season != null) { |
| 3511 _json["season"] = (season).toJson(); |
| 3512 } |
3336 if (sku != null) { | 3513 if (sku != null) { |
3337 _json["sku"] = sku; | 3514 _json["sku"] = sku; |
3338 } | 3515 } |
3339 if (status != null) { | 3516 if (status != null) { |
3340 _json["status"] = status; | 3517 _json["status"] = status; |
3341 } | 3518 } |
3342 if (subscriptionPeriod != null) { | 3519 if (subscriptionPeriod != null) { |
3343 _json["subscriptionPeriod"] = subscriptionPeriod; | 3520 _json["subscriptionPeriod"] = subscriptionPeriod; |
3344 } | 3521 } |
3345 if (trialPeriod != null) { | 3522 if (trialPeriod != null) { |
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3781 } | 3958 } |
3782 if (listings != null) { | 3959 if (listings != null) { |
3783 _json["listings"] = listings.map((value) => (value).toJson()).toList(); | 3960 _json["listings"] = listings.map((value) => (value).toJson()).toList(); |
3784 } | 3961 } |
3785 return _json; | 3962 return _json; |
3786 } | 3963 } |
3787 } | 3964 } |
3788 | 3965 |
3789 | 3966 |
3790 /** Not documented yet. */ | 3967 /** Not documented yet. */ |
| 3968 class MonthDay { |
| 3969 /** |
| 3970 * Day of a month, value in [1, 31] range. Valid range depends on the |
| 3971 * specified month. |
| 3972 */ |
| 3973 core.int day; |
| 3974 |
| 3975 /** Month of a year. e.g. 1 = JAN, 2 = FEB etc. */ |
| 3976 core.int month; |
| 3977 |
| 3978 |
| 3979 MonthDay(); |
| 3980 |
| 3981 MonthDay.fromJson(core.Map _json) { |
| 3982 if (_json.containsKey("day")) { |
| 3983 day = _json["day"]; |
| 3984 } |
| 3985 if (_json.containsKey("month")) { |
| 3986 month = _json["month"]; |
| 3987 } |
| 3988 } |
| 3989 |
| 3990 core.Map toJson() { |
| 3991 var _json = new core.Map(); |
| 3992 if (day != null) { |
| 3993 _json["day"] = day; |
| 3994 } |
| 3995 if (month != null) { |
| 3996 _json["month"] = month; |
| 3997 } |
| 3998 return _json; |
| 3999 } |
| 4000 } |
| 4001 |
| 4002 |
| 4003 /** Not documented yet. */ |
3791 class PageInfo { | 4004 class PageInfo { |
3792 /** Not documented yet. */ | 4005 /** Not documented yet. */ |
3793 core.int resultPerPage; | 4006 core.int resultPerPage; |
3794 | 4007 |
3795 /** Not documented yet. */ | 4008 /** Not documented yet. */ |
3796 core.int startIndex; | 4009 core.int startIndex; |
3797 | 4010 |
3798 /** Not documented yet. */ | 4011 /** Not documented yet. */ |
3799 core.int totalResults; | 4012 core.int totalResults; |
3800 | 4013 |
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3937 _json["purchaseState"] = purchaseState; | 4150 _json["purchaseState"] = purchaseState; |
3938 } | 4151 } |
3939 if (purchaseTimeMillis != null) { | 4152 if (purchaseTimeMillis != null) { |
3940 _json["purchaseTimeMillis"] = purchaseTimeMillis; | 4153 _json["purchaseTimeMillis"] = purchaseTimeMillis; |
3941 } | 4154 } |
3942 return _json; | 4155 return _json; |
3943 } | 4156 } |
3944 } | 4157 } |
3945 | 4158 |
3946 | 4159 |
| 4160 /** Not documented yet. */ |
| 4161 class Season { |
| 4162 /** Inclusive end date of the recurrence period. */ |
| 4163 MonthDay end; |
| 4164 |
| 4165 /** Inclusive start date of the recurrence period. */ |
| 4166 MonthDay start; |
| 4167 |
| 4168 |
| 4169 Season(); |
| 4170 |
| 4171 Season.fromJson(core.Map _json) { |
| 4172 if (_json.containsKey("end")) { |
| 4173 end = new MonthDay.fromJson(_json["end"]); |
| 4174 } |
| 4175 if (_json.containsKey("start")) { |
| 4176 start = new MonthDay.fromJson(_json["start"]); |
| 4177 } |
| 4178 } |
| 4179 |
| 4180 core.Map toJson() { |
| 4181 var _json = new core.Map(); |
| 4182 if (end != null) { |
| 4183 _json["end"] = (end).toJson(); |
| 4184 } |
| 4185 if (start != null) { |
| 4186 _json["start"] = (start).toJson(); |
| 4187 } |
| 4188 return _json; |
| 4189 } |
| 4190 } |
| 4191 |
| 4192 |
| 4193 /** |
| 4194 * A SubscriptionDeferralInfo contains the data needed to defer a subscription |
| 4195 * purchase to a future expiry time. |
| 4196 */ |
| 4197 class SubscriptionDeferralInfo { |
| 4198 /** |
| 4199 * The desired next expiry time for the subscription in milliseconds since |
| 4200 * Epoch. The given time must be after the current expiry time for the |
| 4201 * subscription. |
| 4202 */ |
| 4203 core.String desiredExpiryTimeMillis; |
| 4204 |
| 4205 /** |
| 4206 * The expected expiry time for the subscription. If the current expiry time |
| 4207 * for the subscription is not the value specified here, the deferral will not |
| 4208 * occur. |
| 4209 */ |
| 4210 core.String expectedExpiryTimeMillis; |
| 4211 |
| 4212 |
| 4213 SubscriptionDeferralInfo(); |
| 4214 |
| 4215 SubscriptionDeferralInfo.fromJson(core.Map _json) { |
| 4216 if (_json.containsKey("desiredExpiryTimeMillis")) { |
| 4217 desiredExpiryTimeMillis = _json["desiredExpiryTimeMillis"]; |
| 4218 } |
| 4219 if (_json.containsKey("expectedExpiryTimeMillis")) { |
| 4220 expectedExpiryTimeMillis = _json["expectedExpiryTimeMillis"]; |
| 4221 } |
| 4222 } |
| 4223 |
| 4224 core.Map toJson() { |
| 4225 var _json = new core.Map(); |
| 4226 if (desiredExpiryTimeMillis != null) { |
| 4227 _json["desiredExpiryTimeMillis"] = desiredExpiryTimeMillis; |
| 4228 } |
| 4229 if (expectedExpiryTimeMillis != null) { |
| 4230 _json["expectedExpiryTimeMillis"] = expectedExpiryTimeMillis; |
| 4231 } |
| 4232 return _json; |
| 4233 } |
| 4234 } |
| 4235 |
| 4236 |
3947 /** | 4237 /** |
3948 * A SubscriptionPurchase resource indicates the status of a user's subscription | 4238 * A SubscriptionPurchase resource indicates the status of a user's subscription |
3949 * purchase. | 4239 * purchase. |
3950 */ | 4240 */ |
3951 class SubscriptionPurchase { | 4241 class SubscriptionPurchase { |
3952 /** | 4242 /** |
3953 * Whether the subscription will automatically be renewed when it reaches its | 4243 * Whether the subscription will automatically be renewed when it reaches its |
3954 * current expiry time. | 4244 * current expiry time. |
3955 */ | 4245 */ |
3956 core.bool autoRenewing; | 4246 core.bool autoRenewing; |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4002 } | 4292 } |
4003 if (startTimeMillis != null) { | 4293 if (startTimeMillis != null) { |
4004 _json["startTimeMillis"] = startTimeMillis; | 4294 _json["startTimeMillis"] = startTimeMillis; |
4005 } | 4295 } |
4006 return _json; | 4296 return _json; |
4007 } | 4297 } |
4008 } | 4298 } |
4009 | 4299 |
4010 | 4300 |
4011 /** Not documented yet. */ | 4301 /** Not documented yet. */ |
| 4302 class SubscriptionPurchasesDeferRequest { |
| 4303 /** |
| 4304 * The information about the new desired expiry time for the subscription. |
| 4305 */ |
| 4306 SubscriptionDeferralInfo deferralInfo; |
| 4307 |
| 4308 |
| 4309 SubscriptionPurchasesDeferRequest(); |
| 4310 |
| 4311 SubscriptionPurchasesDeferRequest.fromJson(core.Map _json) { |
| 4312 if (_json.containsKey("deferralInfo")) { |
| 4313 deferralInfo = new SubscriptionDeferralInfo.fromJson(_json["deferralInfo"]
); |
| 4314 } |
| 4315 } |
| 4316 |
| 4317 core.Map toJson() { |
| 4318 var _json = new core.Map(); |
| 4319 if (deferralInfo != null) { |
| 4320 _json["deferralInfo"] = (deferralInfo).toJson(); |
| 4321 } |
| 4322 return _json; |
| 4323 } |
| 4324 } |
| 4325 |
| 4326 |
| 4327 /** Not documented yet. */ |
| 4328 class SubscriptionPurchasesDeferResponse { |
| 4329 /** |
| 4330 * The new expiry time for the subscription in milliseconds since the Epoch. |
| 4331 */ |
| 4332 core.String newExpiryTimeMillis; |
| 4333 |
| 4334 |
| 4335 SubscriptionPurchasesDeferResponse(); |
| 4336 |
| 4337 SubscriptionPurchasesDeferResponse.fromJson(core.Map _json) { |
| 4338 if (_json.containsKey("newExpiryTimeMillis")) { |
| 4339 newExpiryTimeMillis = _json["newExpiryTimeMillis"]; |
| 4340 } |
| 4341 } |
| 4342 |
| 4343 core.Map toJson() { |
| 4344 var _json = new core.Map(); |
| 4345 if (newExpiryTimeMillis != null) { |
| 4346 _json["newExpiryTimeMillis"] = newExpiryTimeMillis; |
| 4347 } |
| 4348 return _json; |
| 4349 } |
| 4350 } |
| 4351 |
| 4352 |
| 4353 /** Not documented yet. */ |
4012 class Testers { | 4354 class Testers { |
4013 /** Not documented yet. */ | 4355 /** Not documented yet. */ |
4014 core.List<core.String> googleGroups; | 4356 core.List<core.String> googleGroups; |
4015 | 4357 |
4016 /** Not documented yet. */ | 4358 /** Not documented yet. */ |
4017 core.List<core.String> googlePlusCommunities; | 4359 core.List<core.String> googlePlusCommunities; |
4018 | 4360 |
4019 | 4361 |
4020 Testers(); | 4362 Testers(); |
4021 | 4363 |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4145 _json["kind"] = kind; | 4487 _json["kind"] = kind; |
4146 } | 4488 } |
4147 if (tracks != null) { | 4489 if (tracks != null) { |
4148 _json["tracks"] = tracks.map((value) => (value).toJson()).toList(); | 4490 _json["tracks"] = tracks.map((value) => (value).toJson()).toList(); |
4149 } | 4491 } |
4150 return _json; | 4492 return _json; |
4151 } | 4493 } |
4152 } | 4494 } |
4153 | 4495 |
4154 | 4496 |
OLD | NEW |