JS modifications. Message types introduced.