deleteBillingGroup method

Future<void> deleteBillingGroup({
  1. required String billingGroupName,
  2. int? expectedVersion,
})

Deletes the billing group.

Requires permission to access the DeleteBillingGroup action.

May throw InternalFailureException. May throw InvalidRequestException. May throw ThrottlingException. May throw VersionConflictException.

Parameter billingGroupName : The name of the billing group.

Parameter expectedVersion : The expected version of the billing group. If the version of the billing group does not match the expected version specified in the request, the DeleteBillingGroup request is rejected with a VersionConflictException.

Implementation

Future<void> deleteBillingGroup({
  required String billingGroupName,
  int? expectedVersion,
}) async {
  final $query = <String, List<String>>{
    if (expectedVersion != null)
      'expectedVersion': [expectedVersion.toString()],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'DELETE',
    requestUri: '/billing-groups/${Uri.encodeComponent(billingGroupName)}',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
}