Added logs and callbacks to capture data.

It'll be easier to parse the JSON all at once, and the received
payloads are always fairly small.