JSON data is converted into a compatible array