Phase 5 ships two complementary surfaces for reactive observability of canonical card changes:Documentation Index
Fetch the complete documentation index at: https://docs.mnemom.ai/llms.txt
Use this file to discover all available pages before exploring further.
- Server-Sent Events at
GET /v1/agents/{id}/stream— long-lived HTTP connection; consumers receive acard_changedSSE frame whenever the agent’s canonical card recomposes. - Signed webhook subscriptions at
POST /v1/agents/{id}/notifications/webhook— Mnemom POSTs a signed payload to your URL on each canonical change.
agents.sse_enabled / agents.webhook_enabled first.
SSE channel
Connect
Content-Type: text/event-stream. Each canonical change emits a frame like:
Reconnect with cursor
Theid field on each frame is the transparency-log log_index. On reconnect, pass it as Last-Event-ID (SSE convention) or as the since query parameter:
log_index ASC order, so the cursor is monotone.
Stream lifetime
Connections cap at 5 minutes (Cloudflare Workers HTTP response budget). Clients reconnect with the latest cursor — the SSE convention handles this automatically in EventSource. A: keepalive <timestamp> comment frame is emitted every 15 seconds; a final event: close frame fires before the connection drops.
Authentication
Currently the endpoint is unauthenticated when the per-agent flag is on — the same access pattern as the A2A AgentCard export. If the per-agent flag is off the endpoint returns 404 (no enumeration).Webhook channel
Subscribe
secret is shown exactly once — store it server-side. Mnemom holds only the hash; subsequent verifications use the hash.
Delivery shape
On every canonical card change, Mnemom POSTs to your URL:Verify the signature
The HMAC-SHA256 signature is computed over the string<timestamp>.<raw-body>:
Idempotent delivery
Each subscription trackslast_sent_log_index. If the compose hook reruns the same log entry (e.g., the reconciler closes a gap that the compose path also closed), the dispatcher skips re-delivery for any subscription whose last_sent_log_index >= log_index.
Unsubscribe
Opt-in
By default, both flags are off:Webhook URL constraints
https://only. http URLs are declined.- No loopback / private-network space (10/8, 172.16/12, 192.168/16, 169.254/16, fc00::/7, fe80::/10).
- No
.local/.internalTLDs.
SSE vs webhook — which to use
| Use case | Channel |
|---|---|
| Backend service that wants real-time reactivity, can keep an HTTP connection open | SSE |
| Serverless / Lambda / Cloud Functions that prefer push-on-event | Webhook |
| Browser / dashboard UI consuming card changes | SSE (via EventSource) |
| Compliance / SIEM / archive that wants a durable POST trail | Webhook |
See also
- A2A AgentCard export — the pull-side counterpart
- Transparency log — the event source
- AAP attestation tokens — the
attestation_jwsfield