use to_json instead of _doc