added create and update groups functionality