Skip to content

Add Notes filters, accounts, stats, tags, and attachment listing - #337

Closed
oliverames wants to merge 2 commits into
mattt:mainfrom
oliverames:feat/notes-read-parity
Closed

oliverames wants to merge 2 commits into
mattt:mainfrom
oliverames:feat/notes-read-parity

Conversation

@oliverames

@oliverames oliverames commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

What it does and why

iMCP can list and read notes, but it can't answer questions like which notes are pinned, which ones have a checklist, or which attachments a note holds. This PR adds those read-only answers using what TopoText 0.2.0 already exposes. It adds no entitlements, helpers, or writes. It is the read side of what sweetrb/apple-notes-mcp covers, and it follows the order Mattt suggested on #311: read parity before any writes.

What changed

  • notes_fetch keeps its current parameters and gains tag, has (attachment, checklist, table, link, drawing, image, pdf, audio, video, scan), pinned, locked, minWords, maxWords, createdStart, createdEnd, and includeRecentlyDeleted.
  • Filters that need a note's contents read each candidate, up to 500 notes per call. If a call stops early, it returns nextCursor and says so. Locked or undecodable notes are listed in unreadableNoteIDs.
  • Notes in notes_fetch and notes_read now carry a url and isRecentlyDeleted. When contents were read, they also carry tags, has, links, and wordCount.
  • notes_folders adds a path for nested folders.
  • New tools: notes_accounts, notes_stats (metadata only, capped at 10,000 notes), notes_tags (from the most recent notes, 500 by default and 5,000 at most), and notes_attachments (name, kind, type, URL, and size, without file contents).
  • The filter and output logic lives in NotesQuery.swift so the test target can compile it, because TopoText's Note and Folder have no public initializers.
  • The test target's deployment target moves from 15.0 to 15.1 because TopoText requires 15.1.
  • Smart folders aren't listed because TopoText leaves them out. mattt/TopoText#3 proposes support for smart folders, tags, and note links.

Testing

  • NotesTests covers the filter and output logic with synthetic data.
  • CI: both builds (macOS 26 with Xcode 26.0, macOS 27 with Xcode 27.0) pass.

Not verified

  • No run against a live Notes database.
  • The url format notes://showNote?identifier=<id> has not been confirmed to open the right note.
  • The new tools have not been called through a client on a Mac.

Screenshots

Notes page in Settings

This is the Notes page in the current Settings window of my integration build, whose sidebar still says "Developer & Advanced" (since renamed "Advanced"). The read tools listed here (Fetch Notes, Read Note, List Note Attachments, List Note Accounts, Summarize Notes, List Note Tags, List Note Folders) are this PR's. The "Private Notes features" section and the "Allow writes" row come from other work (#342 and a fork-only branch), not from this PR.

Oliver Ames added 2 commits November 16, 2026 12:51
Tags, word counts, and the features a note contains come from its decoded
contents, so they live in plain functions of TopoText's public values. That
lets the test target cover them without a Notes database.
notes_fetch gains tag, has, pinned, locked, word-count, created-date, and
includeRecentlyDeleted filters; notes carry a notes:// link, folders a path.
New read-only tools: notes_accounts, notes_stats, notes_tags, notes_attachments.
Everything still reads through TopoText 0.2.0.
@oliverames

Copy link
Copy Markdown
Contributor Author

Replaced by #384, the same change cut as one PR (on top of #377) so it can merge on its own.

@oliverames oliverames closed this Nov 18, 2026
@oliverames
oliverames deleted the feat/notes-read-parity branch November 18, 2026 21:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant