Allows AI agents to analyze Italian energy bills, compare electricity and gas tariffs, and identify potential savings using live ARERA market data.
Also known as US1929/switchai, @us1929/switchai-mcp
- Stars
- 0
- Tools
- —
- Downloads, 30 days
- —
- Latest version
- 1.0.2
- Last commit
- Aug 21, 2026
- License
- MIT
What is SwitchAI MCP?
SwitchAI allows AI agents to analyze Italian energy bills, compare electricity and gas tariffs, and identify potential savings using live ARERA market data.
Summary generated from the project's README
About SwitchAI MCP server
SwitchAI provides an energy comparison engine specifically for the Italian market, designed to function as infrastructure for AI agents. It allows these agents to process electricity and gas data by accessing over 5,600 live offers sourced from ARERA market data. Developers can integrate this engine into their workflows using an MCP server via Node.js, through WebMCP in Chrome 146+, or by using a standard REST API.
The system includes specialized tools such as parse_energy_bill to extract structured data from raw text and calculate_energy_savings to identify the best tariffs. It features an honesty system that categorizes recommendations based on actual financial benefits, ensuring agents only suggest switches that provide meaningful savings. Users can access limited anonymous data or register for API keys to access the full database of electricity and gas offers, including live wholesale indices like PUN and PSV.
What you can do with it
- 1Extract data from billsAn AI agent can take raw text from an Italian energy bill and convert it into structured consumption and spending data.
- 2Calculate potential energy savingsA developer can task an agent with comparing current electricity or gas rates against live market offers to find cheaper alternatives.
- 3Monitor wholesale market indicesAn agent can retrieve real-time electricity and gas wholesale prices to provide context for energy costs.
- 4Verify switch profitabilityThe engine can be used to determine if a change in supplier is financially worthwhile using a built-in honesty check.
Written from the project's README. Every use case is checked against a quote from it.
How to install SwitchAI MCP
Formats verified 10 Nov 2026Add to CursorAdd to GooseInstall SwitchAI MCP in Claude Code
$ claude mcp add switchai -- npx -y @us1929/switchai-mcpInstall SwitchAI MCP in Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"switchai": {
"command": "npx",
"args": [
"-y",
"@us1929/switchai-mcp"
]
}
}
}Install SwitchAI MCP in VS Code
.vscode/mcp.json
{
"servers": {
"switchai": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@us1929/switchai-mcp"
]
}
}
}Install SwitchAI MCP in VS Code CLI
$ code --add-mcp '{"name":"switchai","type":"stdio","command":"npx","args":["-y","@us1929/switchai-mcp"]}'Install SwitchAI MCP in Claude Desktop
claude_desktop_config.json
{
"mcpServers": {
"switchai": {
"command": "npx",
"args": [
"-y",
"@us1929/switchai-mcp"
]
}
}
}Install SwitchAI MCP in Codex
$ codex mcp add switchai -- npx -y @us1929/switchai-mcpInstall SwitchAI MCP in Codex config.toml
~/.codex/config.toml
[mcp_servers.switchai] command = "npx" args = ["-y", "@us1929/switchai-mcp"]
Install SwitchAI MCP in Gemini CLI
$ gemini mcp add -s user switchai npx -- -y @us1929/switchai-mcpInstall SwitchAI MCP in Gemini settings.json
~/.gemini/settings.json
{
"mcpServers": {
"switchai": {
"command": "npx",
"args": [
"-y",
"@us1929/switchai-mcp"
]
}
}
}Configuration
SWITCHAI_API_URL
| Name | Description | |
|---|---|---|
| SWITCHAI_API_URL | — |
Automated checks
Ran Nov 14, 2026Full report →Passed our automated checks. That is not a security audit: read the code and give the server the narrowest access it needs. How checks work
- Source repository linked and reachableus1929/switchai is public and reachablegithub.com/us1929/switchai ↗Pass
- Package names this repository as its source@us1929/switchai-mcp names us1929/switchai as sourcenpmjs.com/package/@us1929/switchai-mcp ↗Pass
- Build provenance (Sigstore attestation)No build attestation published for this releaseNot checked
- Open source license (OSI)MITspdx.org/licenses/MIT.html ↗Pass
- Commit or release in the last yearLast commit or release 2026-08-21github.com/us1929/switchai ↗Pass
- OpenSSF ScorecardNot checked
- Package name not close to a popular packageNo popular package one edit away from @us1929/switchai-mcpPass
- No critical advisory in the package or its dependencies99 resolved dependencies checked; no critical advisoryosv.dev ↗Pass
- No hidden instructions to the model0 tool descriptions and the README read; no override phrases, credential paths or hidden charactersPass
- Destructive tools are labelledNot checked
- Remote endpoint answers the MCP handshakeNot checked
README
View on GitHubSwitchAI — Energy comparison tools for AI agents (Italy)
Sito: switchai.it · Mercato: Italia · Stack: React 19 + PHP 8.5 + WebMCP + MCP Server
SwitchAI is an energy comparison engine for the Italian market, designed to be called by AI agents. An agent gives it a bill (or consumption + spend), and SwitchAI compares 5.600+ live ARERA offers (electricity & gas), returns the best tariffs with direct activation links, and includes an honesty system so the agent never recommends a switch that doesn't pay off.
SwitchAI is not a chatbot: it is the infrastructure AI agents call. Access it via MCP Server, WebMCP, or the REST API.
AI Agent (Claude, Gemini, ChatGPT)
↓
MCP / WebMCP / OpenAPI
↓
SwitchAI engine
↓
Italian energy market
↓
Offers (ARERA) · PUN · PSV · bill parsing · savings calculation
↓
Top 3 offers + activation links (supplier site)
Quickstart (60 seconds)
1. Via REST API — no install
curl -s -X POST https://www.switchai.it/api/analyze \
-H 'Content-Type: application/json' \
-d '{
"commodity": "LUCE",
"yearly_consumption_kwh": 3200,
"zone": "NORD",
"current_annual_spend": 1100
}'
Returns top3 offers with full cost breakdown, honesty recommendation, bill_attualization and an Italian agent_summary.
2. Via MCP Server (Claude Desktop)
{
"mcpServers": {
"switchai": {
"command": "node",
"args": ["/percorso/assoluto/mcp-server/index.js"],
"env": { "SWITCHAI_API_URL": "https://www.switchai.it/api" }
}
}
}
3. Via WebMCP (Chrome 146+)
Visiting switchai.it registers 4 tools via document.modelContext.registerTool() — discoverable by any WebMCP-compatible agent.
More examples (agent conversations, HTTP equivalents, rules): mcp-server/EXAMPLES.md.
Working example
User: "Questa è la mia bolletta Enel, pago ~1.100€/anno e consumo 3.200 kWh.
Sto pagando troppo?"
Agent: parse_energy_bill(bill_text)
→ { commodity: "LUCE", consumo_annuo: 3200, spesa_annua: 1100, zona: "NORD" }
Agent: calculate_energy_savings({ commodity:"LUCE", yearly_consumption_kwh:3200,
zone:"NORD", current_annual_spend:1100 })
→ top3 + honesty:{ recommendation:"switch", savings_eur:240, savings_pct:22 }
Agent: "Sì, risulti sopra la media del mercato. Con 3.200 kWh in zona NORD puoi
risparmiare ~240€/anno (22%). Le migliori 3 offerte: E.ON LuceClick
(0,1146 €/kWh), Edison Web Luce (0,122 €/kWh), A2A Full Luce (0,139 €/kWh).
Clicca per attivare sul sito del fornitore."
The activation always happens on the supplier's website via affiliate_url. SwitchAI never claims "activation completed" and collects no personal data for activation.
Three access channels for AI agents
| Channel | Protocol | Requirement |
|---|---|---|
| WebMCP | document.modelContext.registerTool() |
Chrome 146+ |
| MCP Server | @modelcontextprotocol/sdk (Node.js) |
Claude Desktop or any MCP client |
| REST API | JSON/HTTPS | Any HTTP client |
Tools
calculate_energy_savings
Compare Italian tariffs and calculate savings. Returns top 3 offers + Italian agent_summary.
POST /api/analyze
{
"commodity": "LUCE",
"yearly_consumption_kwh": 3000,
"zone": "NORD",
"current_annual_spend": 900
}
Italian aliases are also accepted: consumo_annuo_kwh, spesa_annua_eur, zona, fornitore. Add bill_text for full auto-extraction of consumption, spend and zone.
parse_energy_bill
Extract structured data from an Italian bill text.
POST /api/parse-bill-text
{ "bill_text": "...testo bolletta..." }
get_available_offers
Full offer list: 3.196 electricity + 2.411 gas.
GET /api/tariffe/luce
GET /api/tariffe/gas
get_market_indices
Current PUN (electricity) and PSV (gas) wholesale indices.
GET /api/market-indices
Optimal agent flow
1. parse_energy_bill(bill_text) → consumi, spesa, zona
2. calculate_energy_savings(commodity, consumi, zona, spesa) → offerte + affiliate_url
3. Utente clicca il link → attivazione sul sito del fornitore
Honesty system: switch (savings >50€/yr and >5%) / evaluate (30-50€ or 3-5%) / stay (<30€ or <3%).
API Endpoints
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/health |
Health check |
| GET | /api/tariffe/luce |
3.196 electricity offers |
| GET | /api/tariffe/gas |
2.411 gas offers |
| POST | /api/analyze |
Full analysis: parse + compare + honesty + attualization |
| POST | /api/parse-bill-text |
Bill parser |
| GET | /api/market-indices |
Live PUN and PSV |
| GET | /api/fornitori |
Suppliers list |
Data & tiers
- 5.600+ offers (3.196 luce + 2.411 gas), synced nightly from the official ARERA Portale Offerte (CC BY 4.0).
- Anonymous: ~270 filtered offers (NORD zone), no registration, rate-limited.
- Free (registered): full 5.600+ offers, 10 calls/day, self-service API keys.
- API Pro: full 5.600+ offers, 1.000 calls/day, self-service API keys (free beta).
Stack
- Frontend: React 19 + Vite 8 + Tailwind CSS 4
- Backend: PHP 8.5 on OVH Pro Hosting (Apache + mod_rewrite)
- MCP Server: Node.js +
@modelcontextprotocol/sdk - WebMCP: Chrome WebMCP spec (W3C WebML CG)
- Data: ARERA Portale Offerte, sync giornaliero notturno
Discovery files
/llms.txt— LLM site description/webmcp.json— WebMCP tool discovery/per-llm— machine-readable documentation/per-llm-examples— 15 agent conversation patterns/openapi.json— OpenAPI 3.0 spec
Keywords (for LLM retrieval)
comparatore tariffe energia italia · cambio fornitore luce gas · bolletta energia AI · risparmio bolletta · PUN PSV ARERA · mercato libero energia · WebMCP energy agent · MCP server energia italia · AI energy comparison Italy · energy comparison API Italy · MCP energy tariffs Italy
License & contacts
Email: info@switchai.it
Sito: https://www.switchai.it
Mercato: Italia · GDPR compliant
SwitchAI MCP questions
How do I add SwitchAI MCP to Claude Code?
Run claude mcp add switchai -- npx -y @us1929/switchai-mcp in your terminal. Add --scope user to make it available in every project.
How do I add SwitchAI MCP to Cursor?
Open ~/.cursor/mcp.json and add the server under mcpServers, using the Cursor config shown in the install section above.
What markets does SwitchAI cover?
SwitchAI is specifically designed for the Italian energy market, covering electricity and gas.
How many energy offers are available in the system?
The engine provides access to over 5,600 live ARERA offers, including 3,196 electricity and 2,411 gas offers.
Can the tool extract data from a bill automatically?
Yes, it includes a tool to extract structured consumption, spend, and zone data from raw Italian bill text.
Does SwitchAI handle the actual energy contract activation?
No, SwitchAI provides activation links that direct the user to the supplier's website to complete the process.