[#102] as_json method fixed
[#105] simple API added and tested
quick fix