Query Notes
query_documentsBrowse paginated indexed notes by text, path, folder, metadata, or modification date, returning exact totals and snippets to locate relevant Markdown content.
Instructions
Page through all matching indexed notes with an exact total.
Queries with text rank by keyword score then path; blank queries rank by modification time descending then path. Pages are live views, so concurrent writes can move notes between pages. Use read to retrieve full note content.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Case-sensitive exact vault-relative path, including .md. | |
| limit | No | Maximum returned notes, 1-1000; total is independent of this cap. | |
| query | No | FTS5 expression; blank selects all indexed notes. Malformed syntax matches its literal words. | |
| scope | No | Indexed columns to match: metadata (path, title, headings, summary), body, or all. Terms must match within one indexed section. | all |
| folder | No | Restrict to this folder and descendants; empty selects root notes. | |
| offset | No | Notes to skip in this live view, at least 0. | |
| filters | No | AND equality over fields in indexed_frontmatter_fields from stats. List fields match a member; computed OKF fields use search instead. | |
| pattern | No | Case-sensitive path glob; *, ? and bracket classes are wildcards. | |
| snippet_words | No | Excerpt width in words, at least 0; 0 returns whole sections. | |
| modified_after | No | Inclusive RFC3339 modification instant with timezone. | |
| chunks_per_file | No | Maximum matching sections per note, at least 1. | |
| modified_before | No | Exclusive RFC3339 modification instant with timezone. | |
| wait_for_pending_writes | No | Wait for recent index writes. On timeout, answer from the current index with _meta.index_stale=true. Default false. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| items | Yes | ||
| limit | Yes | ||
| total | Yes | ||
| offset | Yes | ||
| truncated | Yes | ||
| index_stale | Yes |