added json serialization option