MCP `link` for external clients doesn't open the iOS app — also return a `t3code://threads/...` link
Problem
When an external MCP client (OAuth, e.g. an assistant running outside T3) calls t3_thread_launch / t3_thread_read, the returned link is the relay web URL (https://<relay>.t3coderelay.com/<envId>/<threadId>) or t3-thread://v2/.... Neither opens the T3 Code iOS app:
t3-thread://is only a markdown/chip format and not a registered OS scheme.app.t3.codesand*.t3coderelay.comaren't in the app's associated domains (apps/mobile/app.config.ts, onlyclerk.t3.codes).
The only URL the iOS app opens is t3code://threads/<environmentId>/<threadId> (apps/mobile/src/App.tsx linking prefixes, apps/mobile/src/Stack.tsx thread route). I confirmed it opens the right thread when pasted into Safari, including mcp:launch:... thread ids with colons.
Proposal
In threadLinkFor (apps/server/src/mcp/McpInvocationContext.ts), also return an app link for external clients, e.g. appLink: t3code://threads/${encodeURIComponent(envId)}/${encodeURIComponent(threadId)}, next to the existing link. It's additive, uses the already-registered scheme and route, and needs no native rebuild.
Optional, larger: add applinks:app.t3.codes (and the relay domain) plus an AASA file so the https:// links open the app directly.
Related
- #4996 (desktop
t3code://threads/...deep link)