safejson to core