open my $fh, '<', $filename; $bytes= <$fh>; $data= decode_json($bytes);