fix delete function, set format to json for notebooks