I have recently installed the Azure Active Directory Graph Client Library 2.0.2 Nuget package and am unable to add Members to Groups both adding a group to a group or adding
We’ve just released an update to the Graph client library, that fixes this problem. You should now be able to add members to groups. The mechanism is a little different from using AddLinks (and hopefully simpler).
We also have a new blog describing the client library which talks about this and many other things: http://blogs.msdn.com/b/aadgraphteam/archive/2014/12/12/announcing-azure-ad-graph-api-client-library-2-0.aspx
For reference, to add a member to a group:
{groupObject}.Members.Add({entityObject} as DirectoryObject);
So for example, to update a group with a new user member:
myGroup.Members.Add(userToBeAdded as DirectoryObject); await myGroup.UpdateAsync();
NOTE: The same construct can be used to add users to a DirectoryRole object. Groups and users may be added to a group, however, for now, only users can be added to a DirectoryRole.
Hope this helps,