spot-mcp-server
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
spot-mcp-server
MCP server for Finnish electricity spot prices, powered by api.spot-hinta.fi.
Exposes real-time and forward-looking spot price data as MCP tools, making electricity prices available to AI agents and LLM-based automations without requiring them to call external APIs directly.
Background
Finnish electricity prices change every 15 minutes (96 slots per day). Knowing the current price rank and upcoming price windows is essential for smart home automations — pre-heating during cheap hours, deferring loads during expensive ones, and letting an AI agent reason about trade-offs between comfort and cost.
This server fills the gap: a lightweight MCP endpoint that any MCP-compatible AI client (Claude, etc.) can query to get structured, reasoned price data.
Related MCP server: tibber-mcp-server
Tools
Tool | Description |
| Current quarter-hour: rank, price with/without tax. Served from cache. |
| All quarter-hour slots for today. |
| All quarter-hour slots for tomorrow, if published (~14:15 Finnish time). |
| Filtered time window with min/max/avg summary and cheapest/most expensive slot. |
| Top N cheapest slots remaining today, sorted by price. |
| Current price context: rank, assessment (very cheap → very expensive), position in today's range, tomorrow availability. |
Prices are in EUR/kWh. Rank is a 1–96 percentile within today's prices (1 = cheapest quarter-hour, 96 = most expensive). Days may have 23, 24, or 25 slots per hour due to DST transitions.
Cache strategy
A single /TodayAndDayForward fetch populates all data. Prices are static once published; cache expires only when new data can appear:
Tomorrow's data present → expires at midnight after tomorrow
Only today's data, before 14:15 → expires at midnight tonight
Only today's data, after 14:15 → expires in 15 min (lazy poll until tomorrow is published)
Current price is derived from the cache by matching the current quarter-hour slot — no separate /JustNow call is made.
Requirements
Python 3.10+
fastmcphttpxtzdata
Installation
git clone https://github.com/JussiSavola/spot-mcp-server.git
cd spot-mcp-server
pip install -r requirements.txtRunning
python spot_hinta_mcp.pyDefault port: 8765. Override with environment variable:
SPOT_HINTA_PORT=9000 python spot_hinta_mcp.pyMCP endpoint (Streamable HTTP transport):
http://localhost:8765/mcpOr via run.sh:
bash run.shConnecting to Claude
Add to your Claude MCP configuration:
{
"mcpServers": {
"spot-hinta": {
"type": "url",
"url": "http://localhost:8765/mcp"
}
}
}Tests
pip install pytest
pytest test_spot_hinta.py -vTests cover cache TTL logic, quarter-hour slot matching, DST transition handling, and data parsing. Network calls are mocked.
Data source
api.spot-hinta.fi — free Finnish electricity spot price API.
Endpoint used: /TodayAndDayForward.
License
PolyForm Noncommercial 1.0.0. Personal, hobby, educational and research use, and use by noncommercial organizations, is permitted. Commercial use requires a separate license from the author: Jussi Savola, https://github.com/JussiSavola.
Versions up to and including commit e611c45 were published with "MIT" stated
in this README; those versions remain available under MIT.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Real-time electricity price signals for AI agents. Spot prices, cheapest hours, and contract recommendations. 31 countries across Europe and Oceania. No authentication required.
Real-time electricity prices for AI agents. 40+ countries, 100+ zones. No auth required.
Compare Finnish electricity contracts, estimate annual kWh, and check live Finland spot prices.
51Paid Electricity Market & Grid Intelligence API via x402. Unpaid tool calls return 402.
Related MCP Servers
- FlicenseNot gradedqualityCmaintenanceA read-only MCP server that exposes European day-ahead electricity prices for ~41 bidding zones via tools like hourly prices, cheapest hours, current price, and cross-zone summary, enabling AI agents to query energy market data.1-
- AlicenseAqualityBmaintenanceEnables querying Tibber electricity prices, forecasts, consumption data, cheapest hours, and live Pulse measurements through natural language.7MIT
- FlicenseNot gradedqualityCmaintenanceProvides real-time electricity prices, cheapest hours, and contract comparison for 40+ countries, enabling AI agents to make energy-aware decisions.5-
- AlicenseAqualityBmaintenanceEnables AI agents and assistants to query Polish electricity market data from the SENS Energy Data API by discovering operators and tariffs, fetching composite prices, and inspecting tariff components through natural language.4MIT