Files
outline/server/tools
Tom Moor 8a896ddd2d feat: Return breadcrumb in MCP responses (#12203)
* feat: Add breadcrumb to MCP responses

* test: Update MCP test expectations for new response envelope

Tests were reading the old flat document shape; update them to read
through the new { document, breadcrumb } envelope.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

* perf: Batch collection lookups when building breadcrumbs

Add getBreadcrumbsForDocuments helper that loads all referenced
collections in one query (with the user's memberships) and resolves
breadcrumbs from the per-collection cached documentStructure. Use it
in list_documents and move_document, replacing the per-document
Collection.findByPk that produced an N+1 query pattern.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

* test: Add coverage for getBreadcrumbsForDocuments and parallelize doc + breadcrumb loads

Run presentDocument and getDocumentBreadcrumb concurrently in fetch,
create_document, and update_document so the breadcrumb lookup no
longer adds latency on top of the presenter.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-01 22:57:03 -04:00
..
2026-03-20 09:45:50 -04:00
2026-02-16 20:14:18 -05:00
2026-03-20 09:45:50 -04:00

Tools are the building blocks of functionality for our internal MCP server.

Each tool is a self-contained unit of functionality that can be invoked by the MCP client to perform a specific task. To test the MCP with Claude in development make sure to run with the following command to ensure that the MCP server trusts the mkcert root CA certificate.

NODE_EXTRA_CA_CERTS=$(mkcert -CAROOT)/rootCA.pem claude