Adding API endpoint for group types