add method to_json