====== Zotero Web API Full-Text Content Requests ====== This page documents the methods to access full-text content of Zotero items via the [[start|Zotero Web API]]. See the [[Basics]] page for basic information on accessing the API, including possible HTTP status codes not listed here. ==== Getting new full-text content ==== GET /fulltext?since= Content-Type: application/json Last-Modified-Version: { "": , "": , "": } For each item with a full-text content version greater than stored locally, get the item's full-text content, as described below. ^ Common responses ^^ | ''200 OK'' | Full-text content was successfully retrieved. | | ''400 Bad Request'' | The 'since' parameter was not provided. | ==== Getting an item's full-text content ==== GET /items//fulltext '''' should correspond to an existing attachment item. Content-Type: application/json Last-Modified-Version: { "content": "This is full-text content.", "indexedPages": 50, "totalPages": 50 } ''indexedChars'' and ''totalChars'' are used for text documents, while ''indexedPages'' and ''totalPages'' are used for PDFs. ^ Common responses ^^ | ''200 OK'' | Full-text content was found for the given item. | | ''404 Not Found'' | The item wasn't found, or no full-text content was found for the given item. | ==== Setting an item's full-text content ==== PUT /items//fulltext Content-Type: application/json { "content": "This is full-text content.", "indexedChars": 26, "totalChars": 26 } '''' should correspond to an existing attachment item. For text documents, include ''indexedChars'' and ''totalChars''. For PDFs, include ''indexedPages'' and ''totalPages''. ^ Common responses ^^ | ''204 No Content'' | The item's full-text content was updated. | | ''400 Bad Request'' | Invalid JSON was provided. | | ''404 Not Found'' | The item wasn't found or was not an attachment. | ==== Searching for items by full-text content ==== See the ''q'' and ''qmode'' [[basics#search_parameters|search parameters]].