add method for sending messages