| OLD | NEW |
| 1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
| 2 | 2 |
| 3 library googleapis.reseller.v1; | 3 library googleapis.reseller.v1; |
| 4 | 4 |
| 5 import 'dart:core' as core; | 5 import 'dart:core' as core; |
| 6 import 'dart:async' as async; | 6 import 'dart:async' as async; |
| 7 import 'dart:convert' as convert; | 7 import 'dart:convert' as convert; |
| 8 | 8 |
| 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
| 10 import 'package:http/http.dart' as http; | 10 import 'package:http/http.dart' as http; |
| 11 | 11 |
| 12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show | 12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show |
| 13 ApiRequestError, DetailedApiRequestError; | 13 ApiRequestError, DetailedApiRequestError; |
| 14 | 14 |
| 15 const core.String USER_AGENT = 'dart-api-client reseller/v1'; | 15 const core.String USER_AGENT = 'dart-api-client reseller/v1'; |
| 16 | 16 |
| 17 /** Lets you create and manage your customers and their subscriptions. */ | 17 /** Creates and manages your customers and their subscriptions. */ |
| 18 class ResellerApi { | 18 class ResellerApi { |
| 19 /** Manage users on your domain */ | 19 /** Manage users on your domain */ |
| 20 static const AppsOrderScope = "https://www.googleapis.com/auth/apps.order"; | 20 static const AppsOrderScope = "https://www.googleapis.com/auth/apps.order"; |
| 21 | 21 |
| 22 /** Manage users on your domain */ | 22 /** Manage users on your domain */ |
| 23 static const AppsOrderReadonlyScope = "https://www.googleapis.com/auth/apps.or
der.readonly"; | 23 static const AppsOrderReadonlyScope = "https://www.googleapis.com/auth/apps.or
der.readonly"; |
| 24 | 24 |
| 25 | 25 |
| 26 final commons.ApiRequester _requester; | 26 final commons.ApiRequester _requester; |
| 27 | 27 |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 | 80 |
| 81 /** | 81 /** |
| 82 * Creates a customer resource if one does not already exist. | 82 * Creates a customer resource if one does not already exist. |
| 83 * | 83 * |
| 84 * [request] - The metadata request object. | 84 * [request] - The metadata request object. |
| 85 * | 85 * |
| 86 * Request parameters: | 86 * Request parameters: |
| 87 * | 87 * |
| 88 * [customerAuthToken] - An auth token needed for inserting a customer for | 88 * [customerAuthToken] - An auth token needed for inserting a customer for |
| 89 * which domain already exists. Can be generated at | 89 * which domain already exists. Can be generated at |
| 90 * https://www.google.com/a/cpanel//TransferToken. Optional. | 90 * https://admin.google.com/TransferToken. Optional. |
| 91 * | 91 * |
| 92 * Completes with a [Customer]. | 92 * Completes with a [Customer]. |
| 93 * | 93 * |
| 94 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 94 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 95 * error. | 95 * error. |
| 96 * | 96 * |
| 97 * If the used [http.Client] completes with an error when making a REST call, | 97 * If the used [http.Client] completes with an error when making a REST call, |
| 98 * this method will complete with the same error. | 98 * this method will complete with the same error. |
| 99 */ | 99 */ |
| 100 async.Future<Customer> insert(Customer request, {core.String customerAuthToken
}) { | 100 async.Future<Customer> insert(Customer request, {core.String customerAuthToken
}) { |
| (...skipping 1061 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1162 return _json; | 1162 return _json; |
| 1163 } | 1163 } |
| 1164 } | 1164 } |
| 1165 | 1165 |
| 1166 /** JSON template for a subscription. */ | 1166 /** JSON template for a subscription. */ |
| 1167 class Subscription { | 1167 class Subscription { |
| 1168 /** Billing method of this subscription. */ | 1168 /** Billing method of this subscription. */ |
| 1169 core.String billingMethod; | 1169 core.String billingMethod; |
| 1170 /** Creation time of this subscription in milliseconds since Unix epoch. */ | 1170 /** Creation time of this subscription in milliseconds since Unix epoch. */ |
| 1171 core.String creationTime; | 1171 core.String creationTime; |
| 1172 /** Primary domain name of the customer */ |
| 1173 core.String customerDomain; |
| 1172 /** The id of the customer to whom the subscription belongs. */ | 1174 /** The id of the customer to whom the subscription belongs. */ |
| 1173 core.String customerId; | 1175 core.String customerId; |
| 1174 /** Identifies the resource as a Subscription. */ | 1176 /** Identifies the resource as a Subscription. */ |
| 1175 core.String kind; | 1177 core.String kind; |
| 1176 /** Plan details of the subscription */ | 1178 /** Plan details of the subscription */ |
| 1177 SubscriptionPlan plan; | 1179 SubscriptionPlan plan; |
| 1178 /** Purchase order id for your order tracking purposes. */ | 1180 /** Purchase order id for your order tracking purposes. */ |
| 1179 core.String purchaseOrderId; | 1181 core.String purchaseOrderId; |
| 1180 /** Renewal settings of the subscription. */ | 1182 /** Renewal settings of the subscription. */ |
| 1181 RenewalSettings renewalSettings; | 1183 RenewalSettings renewalSettings; |
| (...skipping 29 matching lines...) Expand all Loading... |
| 1211 | 1213 |
| 1212 Subscription(); | 1214 Subscription(); |
| 1213 | 1215 |
| 1214 Subscription.fromJson(core.Map _json) { | 1216 Subscription.fromJson(core.Map _json) { |
| 1215 if (_json.containsKey("billingMethod")) { | 1217 if (_json.containsKey("billingMethod")) { |
| 1216 billingMethod = _json["billingMethod"]; | 1218 billingMethod = _json["billingMethod"]; |
| 1217 } | 1219 } |
| 1218 if (_json.containsKey("creationTime")) { | 1220 if (_json.containsKey("creationTime")) { |
| 1219 creationTime = _json["creationTime"]; | 1221 creationTime = _json["creationTime"]; |
| 1220 } | 1222 } |
| 1223 if (_json.containsKey("customerDomain")) { |
| 1224 customerDomain = _json["customerDomain"]; |
| 1225 } |
| 1221 if (_json.containsKey("customerId")) { | 1226 if (_json.containsKey("customerId")) { |
| 1222 customerId = _json["customerId"]; | 1227 customerId = _json["customerId"]; |
| 1223 } | 1228 } |
| 1224 if (_json.containsKey("kind")) { | 1229 if (_json.containsKey("kind")) { |
| 1225 kind = _json["kind"]; | 1230 kind = _json["kind"]; |
| 1226 } | 1231 } |
| 1227 if (_json.containsKey("plan")) { | 1232 if (_json.containsKey("plan")) { |
| 1228 plan = new SubscriptionPlan.fromJson(_json["plan"]); | 1233 plan = new SubscriptionPlan.fromJson(_json["plan"]); |
| 1229 } | 1234 } |
| 1230 if (_json.containsKey("purchaseOrderId")) { | 1235 if (_json.containsKey("purchaseOrderId")) { |
| (...skipping 29 matching lines...) Expand all Loading... |
| 1260 } | 1265 } |
| 1261 | 1266 |
| 1262 core.Map toJson() { | 1267 core.Map toJson() { |
| 1263 var _json = new core.Map(); | 1268 var _json = new core.Map(); |
| 1264 if (billingMethod != null) { | 1269 if (billingMethod != null) { |
| 1265 _json["billingMethod"] = billingMethod; | 1270 _json["billingMethod"] = billingMethod; |
| 1266 } | 1271 } |
| 1267 if (creationTime != null) { | 1272 if (creationTime != null) { |
| 1268 _json["creationTime"] = creationTime; | 1273 _json["creationTime"] = creationTime; |
| 1269 } | 1274 } |
| 1275 if (customerDomain != null) { |
| 1276 _json["customerDomain"] = customerDomain; |
| 1277 } |
| 1270 if (customerId != null) { | 1278 if (customerId != null) { |
| 1271 _json["customerId"] = customerId; | 1279 _json["customerId"] = customerId; |
| 1272 } | 1280 } |
| 1273 if (kind != null) { | 1281 if (kind != null) { |
| 1274 _json["kind"] = kind; | 1282 _json["kind"] = kind; |
| 1275 } | 1283 } |
| 1276 if (plan != null) { | 1284 if (plan != null) { |
| 1277 _json["plan"] = (plan).toJson(); | 1285 _json["plan"] = (plan).toJson(); |
| 1278 } | 1286 } |
| 1279 if (purchaseOrderId != null) { | 1287 if (purchaseOrderId != null) { |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1343 } | 1351 } |
| 1344 if (nextPageToken != null) { | 1352 if (nextPageToken != null) { |
| 1345 _json["nextPageToken"] = nextPageToken; | 1353 _json["nextPageToken"] = nextPageToken; |
| 1346 } | 1354 } |
| 1347 if (subscriptions != null) { | 1355 if (subscriptions != null) { |
| 1348 _json["subscriptions"] = subscriptions.map((value) => (value).toJson()).to
List(); | 1356 _json["subscriptions"] = subscriptions.map((value) => (value).toJson()).to
List(); |
| 1349 } | 1357 } |
| 1350 return _json; | 1358 return _json; |
| 1351 } | 1359 } |
| 1352 } | 1360 } |
| OLD | NEW |