delete method
Revoke a license.
Request parameters:
productId
- A product's unique identifier. For more information about
products in this version of the API, see Products and SKUs.
skuId
- A product SKU's unique identifier. For more information about
available SKUs in this version of the API, see Products and SKUs.
userId
- The user's current primary email address. If the user's email
address changes, use the new email address in your API requests. Since a
userId
is subject to change, do not use a userId
value as a key for
persistent data. This key could break if the current user's email address
changes. If the userId
is suspended, the license status changes.
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a Empty.
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<Empty> delete(
core.String productId,
core.String skuId,
core.String userId, {
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
if ($fields != null) 'fields': [$fields],
};
final url_ = 'apps/licensing/v1/product/' +
commons.escapeVariable('$productId') +
'/sku/' +
commons.escapeVariable('$skuId') +
'/user/' +
commons.escapeVariable('$userId');
final response_ = await _requester.request(
url_,
'DELETE',
queryParams: queryParams_,
);
return Empty.fromJson(response_ as core.Map<core.String, core.dynamic>);
}