Documents
Documents and folders: write or upload them, edit Markdown together, keep versions, link them to records, and import from Google Drive.
Commands
- PostMake a document from an uploaded file
documents.document.add_fileFiles an uploaded file (a PDF, a photo, anything) as a document. - PostChange a document between Markdown and HTML
documents.document.convertConverts a document's text to the other format. - PostMake targeted changes to a document
documents.document.editApplies changes to a Markdown or HTML document in order: replace an exact passage ({find, replace}), insert at the end of a heading's section ({after_heading, insert}), or add to the end ({append}). - PostLink a document to a record
documents.document.linkLinks a document to any record in the household (a task, a recipe, a piece of equipment), so the record shows it. - PostDelete a document
documents.document.removeDeletes a document with its text, versions, extracts and links. - PostSave the text read from a file
documents.document.save_textRecords the text of an uploaded file: a PDF's text layer, or what you read from a scan or photo. - PostRemove a document's link to a record
documents.document.unlinkRemoves the link between a document and a record. - PostRename, file or describe a document
documents.document.updateChanges a document's title, folder or summary; only the fields given change. folder_id null takes it out of its folder (unfiled), summary null clears the summary. - PostReplace a document's whole text
documents.document.writeReplaces the text of a Markdown or HTML document. - PostWrite a new document
documents.document.write_newCreates a Markdown or HTML document with the given text. - PostSave what you extracted from a document
documents.extract.saveKeeps structured information you worked out from a document (a policy's number and dates, a statement's lines), so the next question doesn't need the file read again. - PostCreate a folder
documents.folder.createMakes a folder, at the top level or inside another folder. - PostMove a folder
documents.folder.moveMoves a folder, with everything in it, into another folder or to the top level. - PostDelete an empty folder
documents.folder.removeDeletes a folder that has nothing in it. - PostRename a folder
documents.folder.renameChanges a folder's name. - PostImport from Google Drive
documents.google.importImports chosen Google Drive folders and files as documents. - PostDismiss a finished import
documents.import.dismissRemoves a finished import (done or failed) from the library, so it stops showing. - PostRestore an earlier version of a document
documents.version.restoreMakes an earlier version's text and title current.
Queries
- GetDocuments linked to a record
documents.document.for_recordThe documents linked to a record (a task, a recipe, a piece of equipment), oldest link first, each with the link's note. - GetRead a document
documents.document.readA document's text, with its title, kind, summary, folder, saved extracts and links. - GetFind documents by what they say
documents.document.searchFinds documents with all of the words you give in their title, summary, text or extracted information, best matches first. - GetWhat is in a folder
documents.folder.listThe folders and documents directly inside a folder, or at the top level when folder_id is left out (where unfiled documents are too). - GetA document's history
documents.version.listThe saved earlier versions of a Markdown or HTML document, newest first: when, why, who, and how much text each change added and removed (comparing each version with the next newer one, the newest with the current text).
Routes
- GetBrowse a connected Google Drive
documents.google_filesLists one page of a Google Drive folder through a connected Google Drive account, folders first and then by name, 100 to a page. parent_id is root (My Drive), shared (Shared with me) or a folder's Drive ID.