Added all required codes for messaging app