{
  "markdown": "# solarstorm.today MCP server\n\n[![MCP Registry](https://img.shields.io/badge/MCP%20Registry-today.solarstorm%2Fsolarstorm-2b7fff)](https://registry.modelcontextprotocol.io/v0.1/servers/today.solarstorm%2Fsolarstorm/versions/latest)\n[![Registry version](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fregistry.modelcontextprotocol.io%2Fv0.1%2Fservers%2Ftoday.solarstorm%252Fsolarstorm%2Fversions%2Flatest&query=%24.server.version&label=registry&prefix=v&color=2b7fff)](https://registry.modelcontextprotocol.io/v0.1/servers/today.solarstorm%2Fsolarstorm/versions/latest)\n[![tests](https://github.com/newminya/solarstorm-mcp/actions/workflows/tests.yml/badge.svg)](https://github.com/newminya/solarstorm-mcp/actions/workflows/tests.yml)\n[![Python](https://img.shields.io/badge/python-3.10%2B-3776ab)](https://www.python.org/)\n[![License: MIT](https://img.shields.io/badge/license-MIT-green)](LICENSE)\n[![Hosted](https://img.shields.io/badge/hosted-mcp.solarstorm.today-f5a524)](https://solarstorm.today/mcp/)\n\nLive space weather for AI assistants. This MCP server exposes NOAA SWPC data —\nthe planetary Kp index, the official 3-day geomagnetic forecast, GOES solar\nflare activity, and aurora visibility for any latitude — as four tools your\nagent can call directly.\n\nIt runs the same logic as [solarstorm.today](https://solarstorm.today), so\nanswers match what the site shows. No API keys, no accounts, no state.\n\n> **Ask your assistant:** *\"Will I see the aurora in Vienna tonight?\"* →\n> it calls `get_aurora_visibility(48.2)` and answers from live NOAA data.\n\n## Tools\n\n| Tool | Returns |\n|---|---|\n| `get_current_kp()` | Latest planetary Kp, level (`low`/`moderate`/`high`/`severe`), observed 24-hour maximum |\n| `get_kp_forecast_3day()` | Maximum forecast Kp per calendar day for the next 3 days (Europe/Berlin days) |\n| `get_solar_flares_24h()` | Current GOES X-ray flare class and the 24-hour peak, with peak time |\n| `get_aurora_visibility(latitude)` | Kp needed at that latitude, forecast max Kp for the next 24 h, and a plain-language verdict |\n\n<details>\n<summary>Example responses</summary>\n\n```jsonc\n// get_current_kp()\n{\n  \"kp\": 4.33,\n  \"level\": \"moderate\",\n  \"time_utc\": \"2026-08-27T18:00:00+00:00\",\n  \"max_24h\": 5.67,\n  \"source\": \"NOAA SWPC\"\n}\n\n// get_kp_forecast_3day()\n{\n  \"days\": [\n    { \"date\": \"2026-08-27\", \"max_kp\": 5.67, \"level\": \"high\" },\n    { \"date\": \"2026-08-28\", \"max_kp\": 4.0,  \"level\": \"moderate\" },\n    { \"date\": \"2026-08-29\", \"max_kp\": 2.33, \"level\": \"low\" }\n  ],\n  \"timezone\": \"Europe/Berlin\",\n  \"source\": \"NOAA SWPC\",\n  \"note\": \"Kp>=5 is a G1 geomagnetic storm on the NOAA scale.\"\n}\n\n// get_solar_flares_24h()\n{\n  \"current_class\": \"C2.1\",\n  \"peak_24h_class\": \"M6.9\",\n  \"peak_time_utc\": \"2026-08-27T04:12:00Z\",\n  \"source\": \"NOAA GOES (0.1-0.8 nm)\"\n}\n\n// get_aurora_visibility(48.2)\n{\n  \"latitude\": 48.2,\n  \"kp_needed_naked_eye\": 8,\n  \"forecast_max_kp_24h\": 5.67,\n  \"visible_tonight\": false,\n  \"verdict\": \"Unlikely: forecast max Kp 5.7 is 2.3 below the ~Kp 8 needed at 48.2°. A camera picks aurora up roughly one Kp level earlier.\",\n  \"details\": \"https://solarstorm.today/aurora-tonight/\"\n}\n```\n\n</details>\n\nNetwork or format errors from NOAA come back as an `error` field. The server\nnever crashes on a bad upstream response.\n\n## Use the hosted server (no install)\n\nA public instance is running at `https://mcp.solarstorm.today/mcp`.\n\n**Claude Code**\n\n```bash\nclaude mcp add --transport http solarstorm https://mcp.solarstorm.today/mcp\n```\n\n**Claude Desktop / claude.ai** — add a custom connector pointing at\n`https://mcp.solarstorm.today/mcp`.\n\n**Any other MCP client** — streamable HTTP transport, same URL, no auth.\n\n## Run it locally (stdio)\n\nRequires Python 3.10+ — the floor set by the `mcp` SDK.\n\n```bash\ngit clone https://github.com/newminya/solarstorm-mcp.git\ncd solarstorm-mcp\npip install -r requirements.txt\npython server.py          # waits for a stdio client; Ctrl+C to quit\n```\n\n`claude_desktop_config.json`:\n\n```json\n{\n  \"mcpServers\": {\n    \"solarstorm\": {\n      \"command\": \"python\",\n      \"args\": [\"/absolute/path/to/solarstorm-mcp/server.py\"]\n    }\n  }\n}\n```\n\nClaude Code:\n\n```bash\nclaude mcp add solarstorm -- python /absolute/path/to/solarstorm-mcp/server.py\n```\n\n## Self-host it (streamable HTTP)\n\nThree environment variables control the transport:\n\n| Variable | Default | Purpose |\n|---|---|---|\n| `MCP_TRANSPORT` | `stdio` | Set to `streamable-http` for a network server |\n| `MCP_HOST` | `0.0.0.0` | Bind address — use `127.0.0.1` behind a reverse proxy |\n| `MCP_PORT` | `8765` | Listen port |\n\n<details>\n<summary>systemd + reverse proxy</summary>\n\n```bash\nmkdir -p /opt/solarstorm-mcp && cd /opt/solarstorm-mcp\n# copy server.py and requirements.txt here\npython3 -m venv venv && venv/bin/pip install -r requirements.txt\n```\n\n`/etc/systemd/system/solarstorm-mcp.service`:\n\n```ini\n[Unit]\nDescription=solarstorm.today MCP server\nAfter=network.target\n\n[Service]\nWorkingDirectory=/opt/solarstorm-mcp\nEnvironment=MCP_TRANSPORT=streamable-http\nEnvironment=MCP_HOST=127.0.0.1\nEnvironment=MCP_PORT=8765\nExecStart=/opt/solarstorm-mcp/venv/bin/python server.py\nRestart=always\nRestartSec=5\n\n[Install]\nWantedBy=multi-user.target\n```\n\n```bash\nsystemctl daemon-reload && systemctl enable --now solarstorm-mcp\nsystemctl status solarstorm-mcp\n```\n\nnginx in front, on a subdomain with a TLS certificate:\n\n```nginx\nserver {\n    server_name mcp.example.com;\n    location /mcp {\n        proxy_pass http://127.0.0.1:8765/mcp;\n        proxy_http_version 1.1;\n        proxy_set_header Host $host;\n        proxy_buffering off;\n        proxy_read_timeout 3600s;\n    }\n    # + certbot TLS lines\n}\n```\n\nOne thing that bites people: the MCP SDK rejects requests whose `Host` header\ndoesn't match what it expects (DNS-rebinding protection). If handshakes fail\nwith a 4xx while the service itself is healthy, check what `Host` your proxy\nforwards.\n\n</details>\n\n## How the numbers are derived\n\n- **Data sources.** `services.swpc.noaa.gov` — planetary K-index and its\n  forecast product, plus GOES primary 0.1–0.8 nm X-ray flux. 10-second timeout,\n  no caching, no keys.\n- **Daily maxima** are bucketed by Europe/Berlin calendar days, matching the\n  site's German-language audience. Only observed-blank, `estimated`, and\n  `predicted` points count toward forecasts.\n- **Flare classes** convert X-ray flux to the standard A/B/C/M/X scale\n  (X ≥ 1e-4 W/m², M ≥ 1e-5, and so on).\n- **Aurora thresholds** are European-sector guide values for naked-eye\n  visibility: Kp 1 above 66°, 3 above 62°, 4.5 above 58°, 6 above 55°,\n  7 above 52°, 8 above 48°, 9 above 44.5°. Below ~44.5° only extreme\n  historical storms qualify. A camera typically catches aurora about one Kp\n  level earlier than the eye does.\n- **Not modelled:** the Bz component of the interplanetary magnetic field.\n  A southward Bz makes a given Kp far more productive, and it can't be\n  forecast days ahead — treat verdicts as odds, not promises.\n\n## Related\n\n- [solarstorm.today](https://solarstorm.today) — the site this mirrors (EN/DE)\n- [Aurora tonight](https://solarstorm.today/aurora-tonight/) — live map with the NOAA OVATION oval\n- [3-day forecast](https://solarstorm.today/3-day-forecast/)\n- [About this MCP server](https://solarstorm.today/mcp/)\n\n## Tests\n\n```bash\npip install -r requirements-dev.txt\npytest -m \"not live\"    # offline: parsing, thresholds, formatting\npytest -m live          # hits NOAA, asserts the live response contract\n```\n\nThe offline suite runs on every push against Python 3.10–3.13. The live suite\nalso runs daily on a schedule, because the one bug that reached production\nwasn't a logic error: NOAA's observed feed spells its key `Kp` while the\nforecast feed says `kp`, so valid 200 responses parsed to zero rows. Only a\nreal call catches that kind of drift.\n\n## License\n\nMIT — see [LICENSE](LICENSE).\n",
  "bytes": 7830,
  "sha": "17719f9a844d01ed256fb32d8c8589d6d5ebff82781ee0058dc39e86b1c02155",
  "repo_slug": "newminya/solarstorm-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_today_solarstorm_solarstorm_6e0fc827/readme"
}