Command Palette

Search for a command to run...

UnylyUnyly
Весь каталог

Events Serverless Earthquake Agent

БесплатноНе проверен

Events Serverless Earthquake Agent — Model Context Protocol server

GitHubEmbed

Описание

Events Serverless Earthquake Agent — Model Context Protocol server

README

A sample that demonstrates the experimental MCP Triggers & Events extension webhook delivery mode, by using MCP events to wake a serverless Strands agent.

Screenshot of sample app home page.

This sample app provides multi-customer earthquake monitoring. Each user configures their own filters (minimum magnitude, geographic region, max depth) and briefing schedule. The agent accumulates earthquake observations in its conversation history and periodically synthesizes them into a briefing report for the user.

Screenshot of agent conversation.

Screenshot of briefing reports.

This is sample/demo code intended to illustrate the MCP Events extension and a wake/sleep serverless agent pattern. It is not production-hardened.

Architecture

The system consists of:

  • MCP Servers — declare event types, manage webhook subscriptions, deliver signed events to webhook targets
  • MCP Client/Host application — subscribes to events, receives and processes them, manages customer state
  • External systemsUSGS Real-time Feed, Amazon Bedrock

At a high-level, there are three major components:

  1. MCP Server 1 — USGS Earthquake Feed polls the USGS GeoJSON feed every 5 minutes, detects new earthquakes with cursor-based deduplication, and delivers each one as an earthquake.detected event to every subscription whose filter matches.
  2. MCP Server 2 — Message Scheduler fires a briefing.trigger event per customer on that customer's configured interval (or on demand).
  3. The Strands agent wakes on each event. Its conversation history accumulates the earthquake events for the customer: each earthquake becomes a user message plus an LLM analysis response. Each briefing trigger event asks the LLM to synthesize the whole conversation into a report via a save_report tool.

The system is entirely serverless: The agent has zero running compute until an event arrives: webhook events wake the Lambda-hosted Strands agent just long enough to process the event and persist its state. Likewise, both MCP servers run as Lambda functions, triggered on EventBridge schedules. They have no long-running processes — they wake, check for work, deliver webhooks, and exit.

The two MCP servers (top and bottom) deliver events to the client application (middle) via signed webhooks (solid orange arrows). Inside the client application, events flow through a Webhook Receiver → SQS queue → Strands Agent pipeline, with the agent invoking Bedrock for LLM analysis and persisting conversation state to S3.

High-level overview

Event delivery

Each delivery is a signed HTTP POST (Standard Webhooks HMAC-SHA256) with an X-MCP-Subscription-Id header that the receiver uses to look up the correct per-subscription secret and route the event to the right customer.

When the Strands agent handler is invoked with a webhook event, it goes through the following steps:

  1. It translates the MCP server's subscription ID in the event to the application's customer ID.
  2. It acquires a lock on the customer ID, so that multiple agent invocations don't overwrite each other.
  3. It looks up any existing agent session data (including previous conversation history) associated with that customer in S3, and loads it into the Strands agent.
  4. It adds the event as a user message in the conversation history. This could be an earthquake event or a briefing event.
  5. It runs the agent. For earthquake events, the LLM responds with an analysis of the most recent earthquake. For briefing events, the LLM calls an agent tool that stores a briefing report.
  6. It stores the agent's session data back to S3. For briefing events, the session data is cleared, so that future reports don't contain duplicate earthquake data.
  7. It releases the lock on the customer ID.
Event delivery flow

Subscription management

The Subscription Manager is the MCP client's subscription lifecycle owner. It calls events/subscribe on both servers per customer — supplying filter parameters (magnitude, region, depth) for the earthquake feed, an interval for the briefing trigger, and a client-generated whsec_ signing secret for each subscription.

The MCP servers' subscriptions also require periodic refreshing or they expire (using TTLs on subscription records in DynamODB). The client's Subscription Manager maintains those subscriptions by periodically calling events/subscribe on each server.

Subscription management

Customer webapp

Customers can self-service manage their configuration and view reports through a SvelteKit SPA served via CloudFront. The webapp authenticates with Cognito and calls the Data API with a JWT to manage config, read reports, and view the agent's conversation history.

Customer webapp

Getting started

See DEVELOPMENT.md for prerequisites, install, build, lint, test, deploy, and usage instructions.

MCP Events design coverage

See MCP-EVENTS-COVERAGE.md for a detailed breakdown of which parts of the MCP Events design sketch are implemented in this project.

License

Apache-2.0.

from github.com/clareliguori/mcp-events-serverless-earthquake-agent

Установка Events Serverless Earthquake Agent

У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.

▸ github.com/clareliguori/mcp-events-serverless-earthquake-agent

FAQ

Events Serverless Earthquake Agent MCP бесплатный?

Да, Events Serverless Earthquake Agent MCP бесплатный — установка в пару кликов через Unyly без оплаты.

Нужен ли API-ключ для Events Serverless Earthquake Agent?

Нет, Events Serverless Earthquake Agent работает без API-ключей и переменных окружения.

Events Serverless Earthquake Agent — hosted или self-hosted?

Self-hosted: сервер запускается локально на твоей машине командой из раздела установки.

Как установить Events Serverless Earthquake Agent в Claude Desktop, Claude Code или Cursor?

Открой Events Serverless Earthquake Agent на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.

Похожие MCP

Fetch

Web content fetching and conversion for efficient LLM usage.

автор: Community

Roblox Studio

Enables AI coding tools to control Roblox Studio for workspace exploration, instance manipulation, and script management. It provides tools for playtesting, sce

paralovавтор: paralov

AWS KB Retrieval

Retrieval from AWS Knowledge Base using Bedrock Agent Runtime.

modelcontextprotocolавтор: modelcontextprotocol

Spring AI MCP Server

Provides auto-configuration for setting up an MCP server in Spring Boot applications.

автор: Community

llm-analysis-assistant

A very streamlined mcp client that supports calling and monitoring stdio/sse/streamableHttp, and can also view request responses through the /logs page. It also

xuzexin-hzавтор: xuzexin-hz

MCP-Agent

A simple, composable framework to build agents using Model Context Protocol by [LastMile AI](https://www.lastmileai.dev)

lastmile-aiавтор: lastmile-ai

Spring AI MCP Client

Provides auto-configuration for MCP client functionality in Spring Boot applications.

автор: Community

mcp.natoma.ai

A Hosted MCP Platform to discover, install, manage and deploy MCP servers by [Natoma Labs](https://www.natoma.ai)

автор: Community

MCPHub

Website to list high quality MCP servers and reviews by real users. Also provide online chatbot for popular LLM models with MCP server support.

автор: Community

MCP Servers Rating and User Reviews

Website to rate MCP servers, write authentic user reviews, and [search engine for agent & mcp](http://www.deepnlp.org/search/agent)

автор: Community

Compare Events Serverless Earthquake Agent with

Не уверен что выбрать?

Найди свой стек за 60 секунд

Автор?

Embed-бейдж для README

Похожее

Все в категории ai