Skip to content

fix(mcp): accept an identity's email address in from; add upstream tracking ledger - #37

Open
amirhmoradi wants to merge 3 commits into
mainfrom
upstream-sync/2026-10-05-mcp-from-address
Open

amirhmoradi wants to merge 3 commits into
mainfrom
upstream-sync/2026-10-05-mcp-from-address

Conversation

@amirhmoradi

Copy link
Copy Markdown
Contributor

Summary

Fix: email_compose, email_reply, email_forward, email_edit and note_to_draft passed from straight through as identityId. No MCP tool lists identity IDs, and the old description pointed at a non-existent "email_identities". Agents therefore passed the sender address, got Identity not found, and fell back to the default identity. Now:

  • from containing @ is resolved case-insensitively via GET /identities (already ungated in access-control.js, read-only).
  • An unknown address returns { error: "No Thunderbird identity has the address … (known: …)" } without composing anything.
  • Plain identity IDs pass through as before.

MCP only. No new tool (counts stay at 74 CLI / 42 MCP). No change to extension/, bridge/ or the access policy. Idea from vitalio-sh/thunderbird-cli#30 (reimplemented; nothing copied).

Docs: adds docs/upstream-tracking.md, the state file for the weekly upstream & forks scan (ODIAA-2402). It holds the watermark (upstream 465613d, last-seen SHA per fork, Thunderbird versions) and the triage ledger, seeded from docs/PLAN.md §3/§5, plus this week's 19 items and 3 similar-project ideas.

Changes

  • mcp/src/tools.js: setIdentity() helper, wired into the 5 tools; from descriptions updated
  • test/mcp-test.mjs: /identities mock; tests for address → ID and unknown address → error
  • skills/thunderbird-cli/SKILL.md: from: <identityId|email>
  • CHANGELOG.md: ### Fixed and ### Docs under [Unreleased]
  • docs/upstream-tracking.md: new

Note: #36 also adds a ### Security block under [Unreleased]. Whichever merges second needs a trivial CHANGELOG rebase.

Tests

  • npm run test:all: pass (exit 0, all suites 0 failed; MCP 83/83)
  • npm run test:pack-smoke: pass (10/10)

🤖 Generated with Claude Code

…tracking ledger

email_compose/reply/forward/edit and note_to_draft passed `from` straight
through as identityId. No MCP tool lists identity IDs, so agents passed
the sender address, got "Identity not found" and retried with the default
identity. An address (contains "@") is now resolved case-insensitively via
GET /identities (ungated read). An unknown address returns an error that
lists the known addresses. Plain IDs pass through unchanged.

Idea from vitalio-sh/thunderbird-cli#30.

Also adds docs/upstream-tracking.md: watermark and triage ledger for the
weekly upstream & forks scan, seeded from docs/PLAN.md (ODIAA-2402).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
amirhmoradi and others added 2 commits October 12, 2026 09:24
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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