batchDelete method
- BatchDeleteDataPointsRequest request,
- String parent, {
- String? $fields,
Delete a batch of identifyable data points.
request - The metadata request object.
Request parameters:
parent - Optional. Parent (data type) for the Data Point collection
Format: users/me/dataTypes/{data_type}, e.g.: -
users/me/dataTypes/steps - users/me/dataTypes/- For a list of the
supported data types see the DataPoint data union field. Deleting data
points across multiple data type collections is supported following
https://aip.dev/159. If this is set, the parent of all of the data points
specified in names must match this field.
Value must have pattern ^users/\[^/\]+/dataTypes/\[^/\]+$.
$fields - Selector specifying which fields to include in a partial
response.
Completes with a Operation.
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<Operation> batchDelete(
BatchDeleteDataPointsRequest request,
core.String parent, {
core.String? $fields,
}) async {
final body_ = convert.json.encode(request);
final queryParams_ = <core.String, core.List<core.String>>{
'fields': ?$fields == null ? null : [$fields],
};
final url_ =
'v4/' + core.Uri.encodeFull('$parent') + '/dataPoints:batchDelete';
final response_ = await _requester.request(
url_,
'POST',
body: body_,
queryParams: queryParams_,
);
return Operation.fromJson(response_ as core.Map<core.String, core.dynamic>);
}