releaseSenderId method

Future<ReleaseSenderIdResult> releaseSenderId({
  1. required String isoCountryCode,
  2. required String senderId,
})

Releases an existing sender ID in your account.

May throw AccessDeniedException. May throw ConflictException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Parameter isoCountryCode : The two-character code, in ISO 3166-1 alpha-2 format, for the country or region.

Parameter senderId : The sender ID to release.

Implementation

Future<ReleaseSenderIdResult> releaseSenderId({
  required String isoCountryCode,
  required String senderId,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.0',
    'X-Amz-Target': 'PinpointSMSVoiceV2.ReleaseSenderId'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'IsoCountryCode': isoCountryCode,
      'SenderId': senderId,
    },
  );

  return ReleaseSenderIdResult.fromJson(jsonResponse.body);
}