//This implementation deviates from RFC 7159 - The JavaScript Object Notation (JSON) Data Interchange Format <https://tools.ietf.org/html/rfc7159> in the following ways:
//Section 6 (Numbers):
// Leading zeros are allowed
// Infinity, -Infinity, NaN are considered valid numbers
//Section 7 (Strings):
// Escaping characters is not implemented
// Literal double quote is represented as "" in a string
root_folder_name = user_input("(optional, you can press enter to skip and use the root folder name provided in the import string)\nroot folder name: \n")
export_string = user_input("export string: \n")
table = json.to_object(export_string)
file_table = {}
for value in table.values
key = table.indexOf(value)
file_name = value["name"].replace(" ", "_")
if value["parent"] == "" then
parent_folder = root_folder
if root_folder_name != "" then file_name = root_folder_name
file_path = parent_folder.path + "/" + file_name
if computer.File(file_path) then computer.File(file_path).delete //clear