Assign an user profile
1 answer
searchOptionsBuilder.filter(ProfileSearchDescriptor.NAME, "User");
SearchResult<Profile> searchResultProfile = orgProfileAPI.searchProfiles(searchOptionsBuilder.done());
Profile profile = searchResultProfile.getResult().get(0);
ProfileMemberCreator profileMemberCreator = new ProfileMemberCreator(profile.getId());
profileMemberCreator.setUserId(user.getId());
orgProfileAPI.createProfileMember(profileMemberCreator);