- thor/web/mcp.py: stateless Streamable HTTP at POST /mcp (JSON-RPC 2.0), RFC 9728 metadata at
/.well-known/oauth-protected-resource[/mcp], 401 with resource_metadata. Tokens checked
against Authelia's JWKS: RS256, iss, aud (this server), exp, typ at+jwt, client_id thor-mcp,
scp array; group admin only; Remote-* headers never trusted; every tool call logged with the
user.
- Read tools (thor:read): list_incidents, get_incident, what_covers, thor_status,
list_known_conditions. Write tools (thor:write): add_known_condition, end_known_condition,
attach_ticket, detach_ticket. Tools a token's scopes can't use aren't listed.
- Migration 4: incident_links (who attached which ticket to which incident). attach_ticket
records an 'attach' action; in shadow nothing is sent, live sends a 'Root cause' comment.
- Incident page lists attached tickets. PyJWT[crypto] added.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Work in progress for thor#1 phase 1 (PR 1 of 6). Not yet pushed: CI workflow and deploy files still to add.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>