Skip to content

Add MCP tool titles, annotations, prompts, and resource#176

Open
nspady wants to merge 2 commits intomainfrom
codex/tool-titles-hints
Open

Add MCP tool titles, annotations, prompts, and resource#176
nspady wants to merge 2 commits intomainfrom
codex/tool-titles-hints

Conversation

@nspady
Copy link
Owner

@nspady nspady commented Mar 3, 2026

Summary

  • Add title and annotations (readOnlyHint, destructiveHint, idempotentHint, openWorldHint) to all 13 MCP tools
  • Add two prompt templates: daily-agenda-brief and find-and-book-meeting
  • Add calendar-accounts resource exposing connected accounts and deduplicated calendars
  • Migrate manage-accounts from deprecated server.tool() to server.registerTool()
  • Fix idempotentHint for update-event (PUT semantics) and respond-to-event (same response = no change)
  • Add error handling to resource callback with proper McpError wrapping

Test plan

  • All 802 unit tests pass (npm test -- --run)
  • TypeScript type checking passes (npm run lint)
  • Verify tool titles/annotations appear in MCP Inspector
  • Verify prompts render correctly via MCP client
  • Verify calendar-accounts resource returns expected JSON

🤖 Generated with Claude Code

nspady added 2 commits March 2, 2026 11:08
…r handling

- Migrate manage-accounts from server.tool() to registerTool()
- Remove unused ToolAnnotations import
- Fix idempotentHint: true for update-event and respond-to-event
- Add try/catch to calendar-accounts resource callback
- Update tests for registerTool and add prompt/resource callback tests
@github-actions
Copy link
Contributor

github-actions bot commented Mar 3, 2026

📊 Tool Description Token Analysis

Summary

Metric Baseline PR Diff
Total Tokens 7,356 7,356 — (0.0%)
Duplicate Patterns 16 16
Potential Savings 605 605
Full token breakdown by tool
Tool Desc Props Names Types Enums Overhead Total
create-event 6 1066 141 31 131 838 2213
update-event 12 611 88 28 55 586 1380
create-events 39 362 72 5 64 530 1072
search-events 10 197 17 9 0 380 613
list-events 16 160 16 8 0 397 597
get-freebusy 28 139 16 7 0 184 374
respond-to-event 22 208 12 8 27 93 370
get-event 9 75 5 4 0 185 278
delete-event 5 41 6 4 8 80 144
get-current-time 29 37 3 2 0 52 123
list-calendars 4 27 1 1 0 85 118
list-colors 10 16 1 1 0 46 74

Analysis generated at 2026-03-03T04:42:48.554Z

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