deleteSubscriber method

Future<void> deleteSubscriber({
  1. required String accountId,
  2. required String budgetName,
  3. required Notification notification,
  4. required Subscriber subscriber,
})

Deletes a subscriber.

May throw InternalErrorException. May throw InvalidParameterException. May throw NotFoundException. May throw AccessDeniedException.

Parameter accountId : The accountId that is associated with the budget whose subscriber you want to delete.

Parameter budgetName : The name of the budget whose subscriber you want to delete.

Parameter notification : The notification whose subscriber you want to delete.

Parameter subscriber : The subscriber that you want to delete.

Implementation

Future<void> deleteSubscriber({
  required String accountId,
  required String budgetName,
  required Notification notification,
  required Subscriber subscriber,
}) async {
  ArgumentError.checkNotNull(accountId, 'accountId');
  _s.validateStringLength(
    'accountId',
    accountId,
    12,
    12,
    isRequired: true,
  );
  ArgumentError.checkNotNull(budgetName, 'budgetName');
  _s.validateStringLength(
    'budgetName',
    budgetName,
    1,
    100,
    isRequired: true,
  );
  ArgumentError.checkNotNull(notification, 'notification');
  ArgumentError.checkNotNull(subscriber, 'subscriber');
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AWSBudgetServiceGateway.DeleteSubscriber'
  };
  await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'AccountId': accountId,
      'BudgetName': budgetName,
      'Notification': notification,
      'Subscriber': subscriber,
    },
  );
}