implemented json_serialize_to_string_pretty