!7 extend BEAObject { S _originalStruct; } module BEAThoughtBot1 > DynCRUD { switchable S user; switchable S botToken; void importAll { Map data = cast postJSONPage("https://bea.gazelle.rocks/bot/beaList", _user := user, _botToken := botToken); L list = cast data.get("result"); if (list == null) ret with infoBox(str(data.get("error"))); for (Map map : list) { //long id = toLong(map.get("id")); GlobalID globalID = GlobalID((S) map.get("gid")); S struct = cast map.get("struct"); BEAObject o = uniq BEAObject(+globalID); cset(o, _originalStruct := struct); } } }