getResourceShareInvitations method

Future<GetResourceShareInvitationsResponse> getResourceShareInvitations({
  1. int? maxResults,
  2. String? nextToken,
  3. List<String>? resourceShareArns,
  4. List<String>? resourceShareInvitationArns,
})

Gets the invitations for resource sharing that you've received.

May throw ResourceShareInvitationArnNotFoundException. May throw InvalidMaxResultsException. May throw MalformedArnException. May throw UnknownResourceException. May throw InvalidNextTokenException. May throw InvalidParameterException. May throw ServerInternalException. May throw ServiceUnavailableException.

Parameter maxResults : The maximum number of results to return with a single call. To retrieve the remaining results, make another call with the returned nextToken value.

Parameter nextToken : The token for the next page of results.

Parameter resourceShareArns : The Amazon Resource Names (ARN) of the resource shares.

Parameter resourceShareInvitationArns : The Amazon Resource Names (ARN) of the invitations.

Implementation

Future<GetResourceShareInvitationsResponse> getResourceShareInvitations({
  int? maxResults,
  String? nextToken,
  List<String>? resourceShareArns,
  List<String>? resourceShareInvitationArns,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    1,
    500,
  );
  final $payload = <String, dynamic>{
    if (maxResults != null) 'maxResults': maxResults,
    if (nextToken != null) 'nextToken': nextToken,
    if (resourceShareArns != null) 'resourceShareArns': resourceShareArns,
    if (resourceShareInvitationArns != null)
      'resourceShareInvitationArns': resourceShareInvitationArns,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'POST',
    requestUri: '/getresourceshareinvitations',
    exceptionFnMap: _exceptionFns,
  );
  return GetResourceShareInvitationsResponse.fromJson(response);
}