You are not logged in.
Pages: 1
I'm not sure if this is a bug to be solved or a 'feature' but it's not documented and a bit of a sticking point. Basically I'm writing automated scripts to upload a large collection of images to our account via the JSON API, along with these images we're sending a fair amount of meta data for each one.
The first hurdle and one that could most certainly be better pointed out in the documentation is that no meta data will be accepted in the 'AddFilesToUpload' request unless it was specified in the 'editablemetadata' parameter of the initial 'CreateUpload' function, annoying but not a killer.
The real problem is the API won't accept any custom metadata field that has a space or apparently even an underscore replacement in it. If you have a field named 'House Number' and try to add that to the editablemetadata param it is rejected with an 'unknown metadata field' error unless you remove all the spaces, even if you do that and then pass the data in a similarly modified field the data will not be accepted anyway. Also worth noting it would seem if you edit an existing custom metadata field with spaces in to one without spaces it still will not work with the API unless you create a whole new metadata field from scratch, I assume thats probably so data doesn't get lost in the background when you rename them but it's a bit annoying not to be able to use existing fields with data already in them because we can't use them in the API.
Offline
Hi Oli,
I will run this past our team and will be back in touch to let you know our thoughts.
Offline
Hi Oli,
When you create a new metadata field, the name you give the field is automatically converted into a lower camel case keyname and the latter is what you need to specifiy in the editablemetadata parameter.
e.g. A metadata field name of 'House number' will be converted to the form 'houseNumber'.
Compare these pages through the IMS GUI when editing the metadata field to see the relationship:
Settings > Field name
and
Mappings > Metadata key name
Offline
Pages: 1