edtechhub / zotero-cli

Commandline interface for Zotero
https://github.com/edtechhub/zotero-cli/projects/1
13 stars 3 forks source link

Zotero.check_items(items) #62

Open retorquere opened 5 years ago

retorquere commented 5 years ago

Check whether items to be created on the server contain only valid keys. This method first creates a set of valid keys by calling item_fields(), then compares the user-created dicts to it. If any keys in the user-created dicts are unknown, a InvalidItemFields exception is raised, detailing the invalid fields.

retorquere commented 5 years ago

I don't understand what this says. What are keys in this context?

bjohas commented 5 years ago

I think it means the keys in the key:value pairs for an item (e.g. title, publication, ...).

However, I am not sure why it would be possible to create items with invalid keys?

Does the existence of this method mean that items created through the API should be checked with check_items?

retorquere commented 5 years ago

I don't have a clue.

bjohas commented 5 years ago

Ok let me see if I can work it out.

retorquere commented 5 years ago

Why though? If you don't have a live use-case behind this, what's the point?