j::json evtToDoc(not_null<OdinEvent*> evt) { return j::json({ {"type", (int) evt->getType() }, {"code", (int) evt->getCode() }, {"source", evt->getDoco() } }); }