use ujson
little jsonify util
whitespace
organize imports a little bit
move keepalive responsibility from client to server