associateMemberToGroup method
Adds a member (user or group) to the group's set.
May throw DirectoryServiceAuthenticationFailedException.
May throw DirectoryUnavailableException.
May throw EntityNotFoundException.
May throw EntityStateException.
May throw InvalidParameterException.
May throw OrganizationNotFoundException.
May throw OrganizationStateException.
May throw UnsupportedOperationException.
Parameter groupId :
The group to which the member (user or group) is associated.
The identifier can accept GroupId, Groupname, or email. The following identity formats are available:
- Group ID: 12345678-1234-1234-1234-123456789012 or S-1-1-12-1234567890-123456789-123456789-1234
- Email address: group@domain.tld
- Group name: group
Parameter memberId :
The member (user or group) to associate to the group.
The member ID can accept UserID or GroupId, Username or Groupname, or email.
- Member: 12345678-1234-1234-1234-123456789012 or S-1-1-12-1234567890-123456789-123456789-1234
- Email address: member@domain.tld
- Member name: member
Parameter organizationId :
The organization under which the group exists.
Implementation
Future<void> associateMemberToGroup({
required String groupId,
required String memberId,
required String organizationId,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'WorkMailService.AssociateMemberToGroup'
};
await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'GroupId': groupId,
'MemberId': memberId,
'OrganizationId': organizationId,
},
);
}