Back to the app

Documentation

Hospital temperature-risk reports

This tool was Groundswell's submission to the FortyGuard Hackathon 2026. It estimates how recent and forecast temperatures may increase deaths among people living near a selected hospital. This page explains the calculation, its sources, and where it should not be used.

Connect an agent

Groundswell exposes the hospital temperature-risk workflow through one protected Streamable HTTP MCP server. A connected agent can find a hospital, request a report, and retrieve the finished analysis. It cannot browse every saved report.

Quick install

  1. Get a connection code from Groundswell. Treat it like a password and enter it only on the Groundswell authorization page.
  2. Add the endpoint below as a Streamable HTTP MCP server named Groundswell.
  3. When the browser opens the page titled "Connect to Groundswell," enter the connection code, review the access request, and select Authorize.
  4. Enable Groundswell in a new conversation. Verify it with a hospital search before requesting a report.

MCP server URL

https://mcp-production-d65f.up.railway.app/mcp
Transport
Streamable HTTP
Authorization
Browser OAuth with S256 PKCE
Tools
3 fixed tools

Client setup

ChatGPT

  1. Open Settings, then Security and login. Turn on Developer mode.
  2. Open ChatGPT Plugins, select the plus button, and create a connection named Groundswell with the MCP server URL.
  3. Complete Groundswell's browser authorization and review the three tools.
  4. Start a new conversation and enable Groundswell from the tools menu.

Developer mode depends on account and workspace policy. OpenAI documents the current flow in its ChatGPT connection guide.

Claude

  1. On an individual plan, open Customize, then Connectors, and select Add custom connector. On Team or Enterprise, an owner adds a Custom Web connector in Organization settings.
  2. Name it Groundswell and add the MCP server URL.
  3. Complete Groundswell's browser authorization.
  4. In a conversation, open Connectors and enable Groundswell.

See Anthropic's remote MCP connector guide for plan and workspace controls.

Other MCP clients

Use a client that supports remote Streamable HTTP servers, OAuth protected-resource discovery, dynamic public-client registration, and authorization code flow with S256 PKCE. Enter only the endpoint in the client. Do not add a client secret, connection code, access token, query parameter, or custom authorization header.

For protocol debugging, inspect the endpoint and list its tools with npx @modelcontextprotocol/inspector@latest. The browser authorization step still requires a valid Groundswell connection code.

Report workflow

Search first and confirm the hospital and inputs with the user. Then call start_analysis once. Keep the returned UUID and poll only after the server's requested delay.

  1. Call search_hospitals. Present close matches and keep the chosen hospitalId.
  2. Confirm the report title and catchment radius, then call start_analysis. Keep its analysisId and pollAfterMs.
  3. After that delay, call get_analysis. Repeat while status is queued or running. Stop on succeeded or failed.

Tool reference

search_hospitals

Read-only

Searches the supported CMS hospital catalogue by name, city, or two-letter US state code.

query
, required string, 2 to 100 characters.
limit
, optional integer from 1 to 25, default 10.

Returns matching hospital IDs, names, types, emergency-service status, coordinates, city, state, timezone, active model confidence tier, and source receipts. Low-confidence matches are flagged in the text response.

start_analysis

Creates or reuses a report

Starts a persistent 14-day mortality outlook using the prior 21 days of temperature. Equivalent active or completed work is reused when possible.

title
, required string, 1 to 120 characters.
hospitalId
, required ID returned by search_hospitals.
radiusKm
, required number from 0.25 to 2.8 kilometres.

Returns analysisId, status, creation time, and pollAfterMs. It does not wait for the report.

get_analysis

Read-only · requires a report UUID

Reads one known analysis. Pass the required UUID in analysisId.

Returns queued or running progress, a terminal failure, or the complete report. A successful report includes temperature periods, map cells, mortality estimates, confidence and warning fields, and source provenance.

Authentication and access

The connection code approves an MCP client. It is not a FortyGuard or Open-Meteo API key and does not expose Groundswell's database credentials. After approval, the client receives a short-lived token that works only at this MCP endpoint. The MCP server uses a separate private token when it calls the analysis service.

  • The client discovers the authorization endpoints and registers without a client secret.
  • The browser asks for the Groundswell connection code. The app has no user account or login session.
  • A one-use authorization code expires after five minutes. S256 PKCE binds it to the client that started the connection.
  • The access token lasts one hour and is bound to the exact MCP endpoint and mcp scope. The client sends it only in the Authorization header.
  • There is no public report-list tool. A client can read a report only when it knows that report's unguessable UUID.

Verify a connection

Ask the client: "Search Groundswell for Massachusetts General Hospital." Confirm that it calls search_hospitals and returns a hospital ID. Stop there unless you intend to create a report.

Debug a connection

No tools appear
Confirm the URL ends in /mcp, the transport is Streamable HTTP, and Groundswell is enabled in the current conversation. Reconnect after changing the server configuration.
403 or "connection code is incorrect"
The authorization page did not accept the code. Confirm the current code with Groundswell and restart the connection. Each new client authorization requires it.
401 or a repeated authorization prompt
The client has no valid access token. Remove or disconnect Groundswell, add it again, and complete browser authorization.
429 or analysis_limit_reached
Analysis capacity has been reached. Wait for the HTTP Retry-After value or retryAfterSeconds, then retry once.
Queued or running
This is normal progress, not a failure. Keep the same UUID and wait for pollAfterMs before calling get_analysis again.
Structured tool error
Read error.code, error.message, and error.retryable. Retry only when retryable is true, and preserve the original analysis UUID.