new mechanism fro JSON serialization