Refactor JSONInterface