How can I access the metadata/file paths of all a users's saved files?
ShreyJ1729 opened this issue · 3 comments
ShreyJ1729 commented
New user of the library here. I was looking through the docs and couldn't find anything on this. How can I access a user's saved items? I'm building a tool that backs up data in a private cloud so I want to get a list of all the metadata of the users items and push them to my DB.
windingwind commented
The APIs of data: https://github.com/windingwind/zotero-types/blob/master/types/xpcom/data/items.d.ts
The source code of Zotero: https://github.com/zotero/zotero/blob/main/chrome/content/zotero/xpcom/data/items.js
ShreyJ1729 commented
Thanks! Quick second question - how can I access the logged in user's email address?
windingwind commented
Zotero.Prefs.get("sync.server.username")
Please ask the user for permission before getting this sensitive information.