rejectAccountLinkInvitation method

Future<RejectAccountLinkInvitationResult> rejectAccountLinkInvitation({
  1. required String linkId,
  2. String? clientToken,
})

Rejects the account link invitation.

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

Parameter linkId : The identifier of the account link

Parameter clientToken : The client token of the account link invitation to reject.

Implementation

Future<RejectAccountLinkInvitationResult> rejectAccountLinkInvitation({
  required String linkId,
  String? clientToken,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'WorkspacesService.RejectAccountLinkInvitation'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'LinkId': linkId,
      if (clientToken != null) 'ClientToken': clientToken,
    },
  );

  return RejectAccountLinkInvitationResult.fromJson(jsonResponse.body);
}