Skip to content

Add MCP Events for the Muse personal agent - #28

Open
infoxicator wants to merge 2 commits into
idosal:mainfrom
infoxicator:muse-events-worker
Open

infoxicator wants to merge 2 commits into
idosal:mainfrom
infoxicator:muse-events-worker

Conversation

@infoxicator

Copy link
Copy Markdown
Contributor

Summary

  • Add an experimental MCP Events (SEP-3415) adapter for Meta's personal Muse agent. A Cloudflare Worker and SQLite Durable Object manage upstream polls, signed webhooks, OAuth, and the inbox.
  • Use a native Muse Bash hook to check for an opaque wake signal. Empty checks start no model turns. The authenticated connector handles batch reads and acknowledgments.
  • Address four release blockers from an independent Astra 6.2 High review. Recover interrupted subscriptions, cancel in-flight OAuth exchanges on removal, refresh on HTTP 401 with a JSON-RPC body, and verify the Wrangler deployment before uploading static credentials.

Verification

  • Node 22.22.0. npm run typecheck and all 11 Muse adapter tests passed locally.
  • Regression coverage includes Worker restart during subscription setup, server removal during OAuth exchange, refresh token rotation after a JSON-RPC 401, and switching Cloudflare deployments.
  • On live Muse, the public demo event and a signed T3 Code run-completion webhook both woke Muse and received reader acknowledgments. In the T3 run, Cloudflare received the webhook in under a second and Muse acknowledged it after about 62 seconds. This live test preceded the review fixes.

The draft remains experimental. Muse hook behavior across VM suspension or replacement is unverified. Concurrent identical watch creation can create duplicate watches, a lower-priority finding from the review.

@voucha-checks

voucha-checks Bot commented Nov 28, 2026

Copy link
Copy Markdown

VOUCHA

VOUCHA is currently in early access and is not enabled for this repository yet.

To request access, contact @idosal.

VOUCHA has not added a comprehension check to this PR.

- Restructure polyfills/events/muse/README.md with a 3-step quickstart, architecture diagram, 8-tool reference, copy-paste Muse prompt examples (demo button, T3 Code threads, GitHub/npm/HN feeds, watch management), operator CLI table, and troubleshooting FAQ
- Add polyfills/events/muse/SECURITY.md and link it from root SECURITY.md
- Add `npm run setup -- help` and `npm run setup -- prompt --interval <seconds>` with clearer post-deploy and post-login next steps in scripts/setup.mjs
- Add CLI test coverage for help and custom poll intervals in test/setup.test.ts
@infoxicator
infoxicator marked this pull request as ready for review November 30, 2026 16:48
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