Chat patch

Implements JSON chat, currently incomplete.
Still needs at least the ability to extract the full message as raw text (method exists, currently stubbed out)