I'm looking for opinions on the best strategy to implement a new feature. I want to populate fields in the "Extra" field from data on the internet.
Zotero can store info like PMID and PMCID in the "Extra" field, which are used for NIH grants:
I'd like to implement a way to populate those fields using the NIH's PMID/PMCID lookup API using the DOI:
The NIH tool takes the DOI and it returns the PMID and PMCID
Someone implemented this in mendeley by simply creating a perl script that reads from the sqlite DB then directly updates the DB:
I'd be ok with a tool that directly updated the sqlite db with the info, however, directly editing the DB in zotero is dangerous.
My question is, "what is the best strategy for implementing this feature?"
- Write a plugin using the javascript API? (or is this a bad idea since zotero is moving away from xulrunner? How will electron plugins be managed?)
- Write some tool using the web API? (but requires users to have their libraries synced with the web, and have setup/know their api keys?)
- Modify the source code itself to add a lookup engine that updates the "Extra" field?
- Something new in the "tools" menu?
- Anything else?
Thanks
-Scott