Kind of a hack for detecting that the parsed data is JSON, so if you have better ideas, let me know