Get Zotero JSON from API
✓ Published0🌍 Public
CCliffordAnderson
Last edited Jul 14, 2015
Created on Jul 14, 2015
This example demonstrates how to retrieve and parse Zotero library items as structured XML from the Zotero API. It uses the XQuery `fetch:text` function to download JSON data from the API endpoint, then parses that JSON with `json:parse`. The code extracts all `note` elements from the parsed data and converts each into an XML fragment using `fn:parse-xml-fragment`. This approach shows a direct pipeline from API response to manipulable XML nodes, useful for further processing or transformation in an XQuery environment.
AI-generated description