Added api to send messages