updated to read from json instead of xml