Agentic AI Foundation Logo
Illustration of Peter Alexander in a fire chief's helmet ringing an alarm bell as Alf the robot slides down a fire pole, spilling his tea.

MCP Events: teaching agents to react

Peter AlexanderNovember 30, 2026

MCP has always been primarily request-driven. A user or a model asks, and a server answers. That model took us a long way, but as people started building more autonomous agents, every harness ran into the same need. It had to subscribe to events from various sources to react to them: CI events, messaging apps, alerts from monitoring systems. And every harness was building those integrations on its own.

If that sounds familiar, it should. It's the M×N problem MCP was created to solve: M clients and N services add up to M×N one-off integrations. MCP solved it for request/response calls by giving tools a common interface, the "USB-C port for AI applications". Events, which became a Beta MCP extension in November, aims to be that same port for things that happen. A server says "here's what you can watch, and here's what you'll get when it happens", and a harness integrates once to receive events from any server.

Clients and event sources each connect once to MCP Events.

Here's a simple example of what we want to enable. You tell your agent, "if CI fails on any of my pull requests, figure out why and post a summary." The agent subscribes to a ci.failed event on your GitHub MCP server, with your username as the argument, and then goes quiet. The model stays idle until a build actually breaks. When one does, the event arrives, the agent wakes, reads the logs with the same server's tools, and leaves its summary. Swap in a different client or a different CI provider, and the same event subscription pattern applies.

An agent subscribes to ci.failed, sits idle with no model calls, then wakes when a build fails, reads the logs and posts a summary.

Why polling loops and notifications weren't enough

The obvious workaround is an agentic polling loop: the model wakes up on a timer, calls a tool like "list new alerts", and goes back to sleep. It works, but it's slow and expensive. The agent runtime has to stay awake when there's nothing to do, and every check burns tokens just to find out that nothing happened. The faster you want to react, the more often you wake the model, and the more you pay for empty answers. Events moves the waiting out of the model: the client does the watching, and the model only runs when there's something to act on.

MCP also already has resource update notifications, so why not just use those? They fall short in three ways.

  • They carry no custom subscription arguments or event payload. notifications/resources/updated tells you a URI changed. It can't say "a P1 incident was opened for the payments service", because there's nowhere to put "P1" or "payments", and nothing describing the incident.
  • They need a live connection. If your client isn't connected when something happens, you never hear about it.
  • They can't be resumed. There's no cursor, so anything that happens during a disconnect is gone, and you can't even tell you missed it.

Since nothing existing met those needs, we extended the protocol.

The shape of an event

The core idea is small. A server lists the event types it offers with events/list. Each one has a name, an inputSchema for subscription arguments, a payloadSchema for what gets delivered, and the delivery modes it supports.

json
{
 "events": [
   {
     "name": "incident.created",
     "description": "Fires when a new PagerDuty incident is created",
     "delivery": ["webhook", "push", "poll"],
     "inputSchema": {
       "type": "object",
       "properties": {
         "severity": { "type": "string", "enum": ["P1", "P2", "P3", "P4"] },
         "service": { "type": "string" }
       }
     },
     "payloadSchema": {
       "type": "object",
       "properties": {
         "service": { "type": "string" },
         "severity": { "type": "string" }
       }
     }
   },
    …
 ]
}

A client subscribes with a name and arguments, and receives occurrences that look like this:

json
{
 "eventId": "evt_3Qx9",
 "name": "incident.created",
 "timestamp": "2026-11-20T03:12:44Z",
 "data": { "service": "payments", "severity": "P1" },
 "cursor": "c_00af31"
}

If that looks deliberately like tools, it is. We wanted it that way. Tools are "things the model can do, with a schema." Events are "things the model can be told about, with a schema." The goal was for anyone who has written an MCP tool to read an event definition and feel at home.

The hardest call: three ways to deliver

The decision the group went back and forth on most was delivery. MCP usually prefers one way to do a thing, and we wanted one mode too, but we couldn't make it work.

The deployments that need events don't overlap.

  • A serverless server can't hold a connection open per subscriber.
  • A client on a laptop behind NAT has no public URL to receive a webhook.
  • A client that demands low latency may find polling unsuitable.

Whichever single mode you pick, someone real gets stranded. We tried a few times to remove a mode, but every time the idea was floated we hit well-justified resistance from the community with real use cases.

So Events has three, none mandatory, and a server advertises whichever subset it can support per event type:

  • Poll (events/poll). Plain request and response. The server doesn't need to maintain per-subscription state. This is the floor, and it works almost anywhere.
  • Push (events/stream). A long-lived request that streams events as notifications. Low latency for local stdio servers and clients that can keep a stream open.
  • Webhook (events/subscribe). The client registers an HTTPS callback, and the server POSTs signed events to it. Low latency without a held connection, for remote servers.
The same three events delivered by poll, push and webhook.

This does increase the size of the specification and the implementation burden for SDKs, clients, and servers. We believe this is the right choice, but welcome feedback from the community and are eager to see if real use tends to cluster around one or two modes.

Cursors, not guarantees

The second big decision was how reliable to make delivery. It's tempting to promise exactly-once, ordered delivery. But Events sits in front of Gmail, Slack, GitHub, PagerDuty, Kafka and a hundred other systems, each with its own consistency model. A single guarantee at the MCP layer would be either too weak to be useful or too strong to implement.

Instead, every subscription has an opaque, server-defined cursor. The client stores the last cursor it saw and hands it back after a disconnect or a restart, and the server resumes from there. If the upstream is durable, that gives you at-least-once delivery, and eventId lets the client drop duplicates. It is up to servers to decide how much retention they can provide (if any) and whether logically identical events are given the same eventId. If the upstream has no history, the server returns a null cursor and everyone knows replay isn't available.

The edge cases matter here, too. truncated: true signals that events were skipped, so an agent knows to go re-read the real state with tools. And maxAgeMs lets a client that was offline for a week say "resume from my cursor, but give me at most the last five minutes", rather than drowning in backlog.

Resuming a push stream after a restart looks like this:

json
{
 "jsonrpc": "2.0",
 "id": 1,
 "method": "events/stream",
 "params": {
   "name": "incident.created",
   "arguments": { "severity": "P1" },
   "cursor": "c_00af31",
   "maxAgeMs": 300000
 }
}
A client saves its cursor, goes offline, and resumes from it; when it is too far behind, the server answers truncated: true.

We expect some people to use events for state synchronization, which is exactly where these semantics matter.

Webhooks, done boringly

For webhooks we tried hard not to invent anything. Events adopts Standard Webhooks for signing, so off-the-shelf verifier libraries just work. The client supplies the signing secret per subscription. The server must verify the endpoint before it sends anything, to reduce the risk of subscriptions being used to flood someone else's URL.

Subscriptions have a TTL the client suggests and the server grants, and the client refreshes before it expires. This follows the direction of the 2026-07-28 specification, which made MCP's core stateless so servers scale on ordinary HTTP infrastructure. The client owns its subscription list, and every refresh restates the subscription in full, so the server never has to remember a client it can't rebuild. A server that wants to keep everything in memory can grant short TTLs. If it crashes or a request lands on a fresh instance, clients simply resubscribe. A server that grants long TTLs is choosing to persist subscriptions for that long.

What you can build with it

The thing that excites me most about Events is that it lets users and developers build agents that react to events:

  • An on-call agent that subscribes to new incidents, pulls logs with tools, and posts a first-pass triage before a human is awake.
  • An inbox or Slack agent that reacts to messages from specific people or channels, using subscription arguments instead of filtering everything client-side.
  • Agents that talk to each other by sending messages via tools and subscribing to their own inbox for incoming messages.
  • Local stdio servers that push messages straight into a coding agent's session based on things happening on your computer.

I'm excited to see what everyone builds with Events!

How this came together

The Events extension was built in the open by the Tasks and Events Working Group, led by Clare Liguori, Luca Chang, Caitie McCaffrey and me. It started as a design sketch in February, became SEP-3415 in October, was accepted by the Core Maintainers and was finalized on November 19. I would personally like to thank all members of the working group for their contributions, including feedback on the design, early integrations, conformance tests, and SDK implementations: Events would not be where it is today without the working group.

Get involved

Events is new, and we want to hear where it breaks. Try it against an agent you already run. Tell us where it saved you glue code, where a delivery mode didn't fit, or where an open question (should resource subscriptions become events? should one subscription cover several event types?) matters to you.

Share

Author

subscription section bg
Subscribe

Subscribe to the AAIF Briefing

Weekly signal on standards, governance, and the people building the future. No fluff. Just what matters.

About AAIF