batchGet method
Reads one or more subscriptions.
Request parameters:
packageName
- Required. The parent app (package name) for which the
subscriptions should be retrieved. Must be equal to the package_name field
on all the requests.
productIds
- Required. A list of up to 100 subscription product IDs to
retrieve. All the IDs must be different.
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a BatchGetSubscriptionsResponse.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client
completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<BatchGetSubscriptionsResponse> batchGet(
core.String packageName, {
core.List<core.String>? productIds,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
if (productIds != null) 'productIds': productIds,
if ($fields != null) 'fields': [$fields],
};
final url_ = 'androidpublisher/v3/applications/' +
commons.escapeVariable('$packageName') +
'/subscriptions:batchGet';
final response_ = await _requester.request(
url_,
'GET',
queryParams: queryParams_,
);
return BatchGetSubscriptionsResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>);
}