Skip to content

cyanheads/usgs-water-mcp-server

v0.5.0Apache-2.0

Query real-time and historical water data from ~8,000 USGS stream gages and groundwater wells via MCP. STDIO or Streamable HTTP.

Changelog

All notable changes to this project. Each entry links to its full per-version file in changelog/.

0.5.0 — 2026-10-28

Publishes the usgs-water-guide skill over MCP and in the package, moves to mcp-ts-core 0.13.18 (Markdown-escaped error text, cancelled calls settle as RequestCancelled), and keeps result notices as blockquotes.

0.4.0 — 2026-10-20 · ⚠️ Breaking

Site series discovery and timeout recovery

0.3.0 — 2026-10-03

Adds the opt-in water_dataframe_drop tool, stops the server at startup on an invalid USGS_REQUEST_TIMEOUT_MS, and moves to mcp-ts-core 0.13.11, whose tool errors end with their request id.

0.2.6 — 2026-09-24

NWIS series are read per statistic and sensor method, the -999999 no-data value reads as missing, and water_list_parameters searches the full USGS parameter-code catalog.

0.2.5 — 2026-09-22

water_find_sites enforces NWIS's one-major-filter rule and adds limit/offset paging; water_get_series canvas previews now show the most recent records; both tools derive deterministic per-query canvas table names, resolve a supplied canvas_id before the upstream call, and point staged-data notices at water_dataframe_describe first.

0.2.4 — 2026-09-19

Adopts mcp-ts-core ^0.13.6: canvas_id inputs validate before any canvas lookup, water_dataframe_query classifies engine-side SQL failures, and a SQL-comment ReDoS fix reaches that same tool's sql input. Skill tree moves to framework-skills/.

0.2.3 — 2026-08-22

MCP SDK v2 support and request-aware NWIS retries

0.2.2 — 2026-07-19

Wire declared error recovery hints through to callers on every tool and resource, surface water_dataframe_query's truncation flag as an output field, scope its non-SELECT rejection to what callers can invoke, and drop water_get_series's unreachable site_not_found reason.

0.2.1 — 2026-07-19

Definition-language pass over every tool and resource: concatenated description strings collapse to single strings, and inaccurate ones are corrected — the water_dataframe_* tools now name water_find_sites as a canvas producer, row_count describes what it actually counts, and water_get_conditions explains both of its data-gap cases.

0.2.0 — 2026-07-17 · ⚠️ Breaking

BREAKING: hucCd is now optional on water_find_sites sites[].hucCd and the usgs-water://site/{siteId} resource. It is omitted for sites USGS NWIS assigns no Hydrologic Unit Code, where the prior release backfilled an empty string that printed a bare HUC label. Consumers must treat hucCd as possibly-absent.

0.1.13 — 2026-07-16

Rendering-correctness fixes: water_get_series renders every returned value (not just the last 20) and its spillover notice reports the real preview count instead of a fixed 500; water_find_sites renders basic-mode altitude independently of drainageArea and no longer leaks a literal notice: undefined into content[].

0.1.12 — 2026-07-16

water_find_sites stages its full match set to a DuckDB DataCanvas when a query exceeds the 500-site inline cap and a canvas provider is enabled, returning canvas_id and table_name to retrieve every match past the cap via water_dataframe_query. An optional canvas_id input reuses an existing canvas.

0.1.11 — 2026-07-16

water_find_sites echoes the countyCd filter in its enrichment and trailer; the usgs-water://site/{siteId} resource validates siteId at the edge and declares a typed error contract; and stale site-metadata documentation — the removed available-data-types claim and altitude's mode boundary — is corrected.

0.1.10 — 2026-07-16

water_get_conditions validates site and parameterCd at the schema edge, reports why historical context is missing via a new historicalContextStatus enum, and drops the flood/drought framing for an explicit instantaneous-vs-daily-mean disclosure.

0.1.9 — 2026-07-15

Fix a midnight timezone bug in water_get_conditions' stat-row matching, add a percentileLabel field, and correct the hucCd width claim.

0.1.8 — 2026-07-15

Validate NWIS inputs at the edge, bound and complete water_get_readings output, and adopt the mcp-ts-core 0.10.14 supply-chain baseline.

0.1.7 — 2026-06-21

Sanitize the CANVAS_PROVIDER_TYPE env var out of the canvas-disabled error contract and server instructions; reroute the operator hint to the server log. Follow-up to #2, which sanitized the tool descriptions.

0.1.6 — 2026-06-20

Adopt @cyanheads/mcp-ts-core ^0.10.9: check-dependency-specifiers devcheck guard, plugin-manifest packaging checks, re-synced framework tooling and skills. Framework-maintenance only — no tool behavior changes.

0.1.5 — 2026-06-12

Adopt @cyanheads/mcp-ts-core ^0.10.6: refined error codes, denySystemCatalogs SQL hardening, explicit server identity, Docker healthcheck, and post-pack bundle cleaning

0.1.4 — 2026-06-08

Fix water_find_sites unbounded results and empty expanded fields; add YYYY-MM-DD date validation to water_get_series

0.1.3 — 2026-06-06

Fix misclassified site_not_found errors, remove internal env var from tool descriptions, add query enrichment context, and make stateCd/countyCd optional in basic mode

0.1.2 — 2026-06-06

Public hosted endpoint at https://usgs-water.caseyjhand.com/mcp

0.1.1 — 2026-06-05 · 🛡️ Security

Initial public release — 5 USGS NWIS water-data tools + 2 DataCanvas SQL tools + 2 resources over the USGS National Water Information System, with security hardening of upstream error handling