updateBillingGroup method
Updates information about the billing group.
Requires permission to access the UpdateBillingGroup action.
May throw InternalFailureException.
May throw InvalidRequestException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw VersionConflictException.
Parameter billingGroupName :
The name of the billing group.
Parameter billingGroupProperties :
The properties 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
UpdateBillingGroup request is rejected with a
VersionConflictException.
Implementation
Future<UpdateBillingGroupResponse> updateBillingGroup({
required String billingGroupName,
required BillingGroupProperties billingGroupProperties,
int? expectedVersion,
}) async {
final $payload = <String, dynamic>{
'billingGroupProperties': billingGroupProperties,
if (expectedVersion != null) 'expectedVersion': expectedVersion,
};
final response = await _protocol.send(
payload: $payload,
method: 'PATCH',
requestUri: '/billing-groups/${Uri.encodeComponent(billingGroupName)}',
exceptionFnMap: _exceptionFns,
);
return UpdateBillingGroupResponse.fromJson(response);
}