updateUser method

Future<void> updateUser({
  1. required String identityStoreId,
  2. required List<AttributeOperation> operations,
  3. required String userId,
})

Updates the specified user metadata and attributes in the specified identity store.

May throw ConflictException. May throw ResourceNotFoundException. May throw ServiceQuotaExceededException. May throw ValidationException.

Parameter identityStoreId : The globally unique identifier for the identity store.

Parameter operations : A list of AttributeOperation objects to apply to the requested user. These operations might add, replace, or remove an attribute. For more information on the attributes that can be added, replaced, or removed, see User.

Parameter userId : The identifier for a user in the identity store.

Implementation

Future<void> updateUser({
  required String identityStoreId,
  required List<AttributeOperation> operations,
  required String userId,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AWSIdentityStore.UpdateUser'
  };
  await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'IdentityStoreId': identityStoreId,
      'Operations': operations,
      'UserId': userId,
    },
  );
}