Frontend functions for Message System added

There are mistakes around the code