hi shapeways,
i get the feeling the 'get materials' call has a really strange Json structure
For example this comes out:
"materials":{
"6":{
"materialId":"6",
"title":"White Strong & Flexible",
"supportsColorFiles":"0",
"printerId":"5",
"swatch":" https:\/\/static1.sw-cdn.net\/rrstatic\/img\/materials\/plas tic_wsf_white.jpg ",
"restrictions":null
},
If i double check the Json documentation at json.org this would mean:
Object materials -> has object "6" (since "{" denotes the start of an object))
Since we have multiple materials it sounds logically they should be in some sort of a collection (so all standard json parsing codes now better how to handle it)
I think it would make sense to put them in an array ( i compared your code with for example some parts of the mailchimp Api )
"materials": [{
"materialId":"6",
"title":"White Strong & Flexible",
"supportsColorFiles":"0",
"printerId":"5",
"swatch":" https:\/\/static1.sw-cdn.net\/rrstatic\/img\/materials\/plas tic_wsf_white.jpg ",
"restrictions":null
}, ...other material objects ]
or am i not seeing something?
chrs,
Elco