Added get activities function