Added note about the fact that sendJson requires the object to implement a toJson function.