I have searched internet for hours and can't find how to convert my specific JSON:
[{"_id":"55d66226726b611100aaf741","replacement":false,"quantity":5,"name":"Generator 1000 kW","maintenanceperiod":365,"lifespan":120,"cost":5000,"sku":"100003"}, {"_id":"55d66226726b611100aaf742","replacement":true,"quantity":183,"name":"Cooling Fan","maintenanceperiod":0,"lifespan":0,"cost":300,"sku":"100004"}]
Into a Map<String, Object>. Something simple like:
Map<String, Object> m = (Map<String, Object>) JSON.deserializeUntyped(response.getBody());
Won't work as the JSON is a List when deserialized and I get the following error: 'Expecting '}' but was: '<EOF>'