Skip to main content
Glama
README.md
# @pipeworx/nasa-sea-level

NASA's satellite-altimetry global mean sea level: the merged TOPEX/Poseidon, Jason-1, OSTM/Jason-2, Jason-3 and Sentinel-6 record, one value per ~10-day altimeter cycle from 1992, in mm relative to a 20-year mean.

Part of [Pipeworx](https://pipeworx.io) — an MCP gateway connecting AI agents to 2098+ live data sources. This is an independent, unofficial integration — not affiliated with, endorsed by, or published by the upstream provider.

## Tools

- `sealevel_gmsl_series(start_year?, end_year?)` -- time-ordered global mean sea level points (decimal year, altimeter cycle, mm, standard deviation, smoothed mm with the annual cycle removed). Returns units, dataset version (5.2), granule id and fetch time. Outside the record it returns an empty result with the years the record covers.
- `sealevel_gmsl_summary(start_year?, end_year?)` -- the latest value, the linear rate (mm per year) and acceleration (mm per year squared) fitted by least squares over the window, rise since the first cycle in the window, and the reference period. The rate and acceleration are computed here from the series; the file publishes neither, and no uncertainty is given.

## Why this is not noaa-tides

Tide gauges measure coastal relative sea level at a station. This is the global ocean average from satellites, the series NASA reports as the global sea level indicator.

## Not included

The NASA Sea Level Projection Tool (IPCC AR6 projections at tide gauges, to 2150 by scenario) is not here: NASA publishes those projections only as bulk archives, with no per-location interface to call.

## Auth

The data file needs an Earthdata Login bearer token. The pack declares the platform key `PLATFORM_EARTHDATA_TOKEN`, so callers need none; `_apiKey` overrides it. The token is sent only as an Authorization header and never returned or written to an error. It expires 2027-01-31. Finding the file (NASA CMR) needs no token.

## Data sources

NASA Sea Level Change Team and PO.DAAC, global mean sea level from integrated multi-mission altimeters, version 5.2. NASA data is US public domain. Every response names the dataset, version, granule id and fetch time.

## Unverified until the token is used

The authenticated download has not run against live data. The parser follows the product's documented 12-column layout and is tested against a fixture written to it. If the body is not that text, the error shows the first 200 characters, scrubbed of tokens and URL queries.

## Quick Start

Add to your MCP client (Claude Desktop, Cursor, Windsurf, etc.):

```json
{
  "mcpServers": {
    "nasa-sea-level": {
      "url": "https://gateway.pipeworx.io/nasa-sea-level/mcp"
    }
  }
}
```

### What this endpoint actually serves

`tools/list` at `https://gateway.pipeworx.io/nasa-sea-level/mcp` returns the tools in the table
above **plus five Pipeworx tools**: `ask_pipeworx`, `discover_tools`, `ask_pipeworx_grounded`, `company_register_search` and `company_facts`.
`ask_pipeworx` answers a question this pack does not cover by routing across the
whole catalog, without adding a second MCP server.

Add an option to the same URL:

- `https://gateway.pipeworx.io/nasa-sea-level/mcp?meta=1` lists this pack's tools plus **up to 48 shared Pipeworx tools** (48 when this README was
generated; a connection without an account lists fewer, and its own `tools/list` is the
exact answer on any given day).
- `https://gateway.pipeworx.io/nasa-sea-level/mcp?meta=0` lists this pack's tools alone.

Or connect to the full Pipeworx gateway to get every pack's tools listed
directly, instead of just this one's:

```json
{
  "mcpServers": {
    "pipeworx": {
      "url": "https://gateway.pipeworx.io/mcp"
    }
  }
}
```

Both URLs reach the same gateway and the same 2098+ data sources. The
only difference is which pack's tools are listed **directly**; `ask_pipeworx`
reaches all of them from either one (it is not listed on a `?meta=0` connection).

## No MCP client? Call it over HTTP

```bash
curl -X POST https://gateway.pipeworx.io/v1/tools/sealevel_gmsl_series \
  -H 'Content-Type: application/json' \
  -d '{"start_year":2020,"end_year":2024}'
```

No account needed for the first calls. Inspect any tool: `GET https://gateway.pipeworx.io/v1/tools/sealevel_gmsl_series`. Find one: `POST https://gateway.pipeworx.io/v1/tools/search_packs` with `{"query":"..."}`.

## Run it from npm

`@pipeworx/mcp-nasa-sea-level` is a local stdio bridge to the Pipeworx gateway: your MCP client
starts it with `npx`, and it forwards every call to the same
`https://gateway.pipeworx.io/nasa-sea-level/mcp` endpoint shown above. It needs network access;
there is no offline mode.

```json
{
  "mcpServers": {
    "nasa-sea-level": {
      "command": "npx",
      "args": ["-y", "@pipeworx/mcp-nasa-sea-level"]
    }
  }
}
```

Without a key it calls anonymously, capped at 50 calls a day. A free account
raises that to 200 a day: get a key at https://pipeworx.io/signup and add
`"env": { "PIPEWORX_API_KEY": "<your key>" }` to the server entry.
The key is sent as a Bearer token, the same way a hosted connection sends it,
so calls are metered and billed exactly as they are there.

It lists **only** this pack's tools by default. Set `PIPEWORX_META_TOOLS=1` to
also list `ask_pipeworx` and the other gateway-wide tools.

Behind an HTTPS proxy: Node's built-in `fetch` does not read `HTTPS_PROXY` by
default. Newer Node releases honour it when `NODE_USE_ENV_PROXY=1` is set; check
your Node version's documentation.

## Using with ask_pipeworx

Instead of calling tools directly, you can ask questions in plain English —
this works on the pack endpoint above as well as on the full gateway:

```
ask_pipeworx({ question: "your question about Nasa Sea Level data" })
```

The gateway picks the right tool and fills the arguments automatically.

## More

- [Docs and guides](https://pipeworx.io/docs)
- [pipeworx.io](https://pipeworx.io)

## License

MIT