deleteCampaign method
Deletes a data collection campaign. Deleting a campaign suspends all data collection and removes it from any vehicles.
May throw AccessDeniedException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter name :
The name of the campaign to delete.
Implementation
Future<DeleteCampaignResponse> deleteCampaign({
required String name,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.0',
'X-Amz-Target': 'IoTAutobahnControlPlane.DeleteCampaign'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'name': name,
},
);
return DeleteCampaignResponse.fromJson(jsonResponse.body);
}