API v1

MCP tool design

How BennyBooks shapes MCP tools for clean, token-efficient agent use.

Markdown version · llms.txt

Agents only see tool names, descriptions, and schemas. Vague or bloated surfaces cause wrong calls and wasted context. BennyBooks ships a curated catalog rather than a raw OpenAPI dump.

Principles

  1. Curate ~12 tools — disable redundant operations in your MCP bridge
  2. verb_noun names (list_transactions) matching OpenAPI operationId
  3. Descriptions cover what, when to use, and when not to use
  4. Put constraints in the schema (enums, date format, limits)
  5. Lean lists — default limit=50; prefer get_transaction over list_notes
  6. Writes are proposals only until a human approves (recorded in Log)
  7. Prefer categoryCode over display names
  8. x-mcp annotations: readOnlyHint, destructiveHint, idempotentHint, openWorldHint

Default expose set

ToolScopeRole
get_ontologypublicGet ontology
list_categoriesreadList categories
list_transactionsreadList transactions
get_transactionreadGet transaction
get_dashboard_summaryreadDashboard summary
search_receiptsreadSearch receipts
list_connectorsreadList connectors
list_pending_proposalsreadList pending proposals
propose_categorizationpropose-writePropose categorization
propose_journal_entrypropose-writePropose journal entry
propose_receipt_linkpropose-writePropose receipt link
attach_notepropose-writeAttach note (proposal)

Workflows

  • Categorize — list_categories → list_transactions(status=uncategorized) → propose_categorization
  • Investigate — get_transaction (notes + receipts) → search_receipts if needed
  • Month-end — get_dashboard_summary → chase uncategorized / receipt_missing / proposals / connectors

Audit trail

Propose-write tools are audit-logged. Humans see Approvals for decisions and Log (/log) for history. Agents have no read API for Log in v1 — see Audit Log guide.

Source of truth

lib/mcp/tool-catalog.ts drives OpenAPI enrichment, AnythingMCP yaml, and /skill.md. Repo doc: docs/MCP.md.

Native Streamable HTTP MCP on this origin is not required for v1 — AnythingMCP (or a future small MCP server) wraps the same curated surface.