add refactor of json file