SaferPlaces 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.
SaferPlaces MCP Server
Server MCP che espone i processi di simulazione delle REST API di SaferPlaces come tool utilizzabili da Claude, per lanciare e monitorare simulazioni direttamente dalla chat.
Processi supportati (descrizioni lette live dal server, nei formati f=json e f=jsonld):
untrim-process— modello UNTRIM, water depth da pioggia e DEMdigital-twin-process— preparazione DEM (edifici, land use, extrusion, seamask)terra-twin-process
Per aggiungere un processo basta inserire il suo id in PROCESS_IDS (e nel Literal associato) in cima a saferplaces_mcp.py.
Le credenziali (utente e token) vengono iniettate dal server nel body di ogni richiesta di esecuzione: non passano mai per la chat e Claude non le vede. I nomi dei campi (user e token, dentro inputs) sono verificati sulla descrizione live dei processi.
Tool esposti
Tool | Cosa fa |
| Elenco dei processi disponibili sull'API |
| Descrizione di un processo e dei suoi input (formato json o jsonld) |
| Lancia un processo (asincrono di default, sincrono su richiesta) |
| Stato di un job (accepted / running / successful / failed) |
| Risultati di un job completato |
| Elenco dei job recenti |
| Lancia un processo e attende il completamento (polling) |
Related MCP server: MCP OpenAPI Connector
Struttura del repo
saferplaces_mcp.py # il server MCP
requirements.txt # dipendenze Python (fastmcp, httpx)
README.mdConfigurazione
Il server richiede due variabili d'ambiente:
Variabile | Descrizione |
| Nome utente SaferPlaces |
| Token associato all'utente |
In cima a saferplaces_mcp.py ci sono tre costanti da verificare rispetto alla documentazione delle API:
USER_FIELDeTOKEN_FIELD: i nomi esatti dei campi del body in cui l'API si aspetta le credenziali (default:useretoken).CREDENTIALS_INSIDE_INPUTS:Truese le credenziali vanno annidate dentro l'oggettoinputsdel body (tipico delle OGC API Processes),Falsese vanno al livello principale.
Uso locale (Claude Code / Claude Desktop)
Richiede Python 3.10+.
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
export SAFERPLACES_USER="tuo-utente"
export SAFERPLACES_TOKEN="tuo-token"
# test rapido: deve avviarsi senza errori (Ctrl+C per fermarlo)
python saferplaces_mcp.pyCollegamento a Claude Code (usa i percorsi assoluti):
claude mcp add saferplaces \
-e SAFERPLACES_USER=tuo-utente \
-e SAFERPLACES_TOKEN=tuo-token \
-- /percorso/assoluto/.venv/bin/python /percorso/assoluto/saferplaces_mcp.pyVerifica con /mcp dentro Claude Code: il server saferplaces deve comparire tra quelli connessi.
Deploy remoto (connettore per Claude.ai)
In modalità remota il server gira su un hosting raggiungibile via HTTPS e si collega a Claude.ai da Impostazioni → Connettori → Aggiungi connettore personalizzato, incollando l'URL. Funziona da browser e da mobile, senza nulla in esecuzione in locale.
Il trasporto HTTP si attiva con la variabile d'ambiente MCP_TRANSPORT=http (la porta si imposta con PORT, default 8000).
Opzione A — FastMCP Cloud
Carica questo repo su GitHub.
Su fastmcp.cloud collega il repo: la piattaforma rileva l'oggetto
mcpinsaferplaces_mcp.pye lo deploya.Imposta
SAFERPLACES_USEReSAFERPLACES_TOKENtra le variabili d'ambiente del progetto.Copia l'URL HTTPS generato e incollalo nei connettori di Claude.ai.
Opzione B — hosting generico (Cloud Run, Render, Railway, ...)
Comando di avvio:
MCP_TRANSPORT=http python saferplaces_mcp.pyImposta SAFERPLACES_USER, SAFERPLACES_TOKEN e (se richiesto dalla piattaforma) PORT tra le variabili d'ambiente del servizio.
Sicurezza
⚠️ Un server remoto con le credenziali configurate permette a chiunque ne conosca l'URL di lanciare simulazioni con il tuo account e consumare la tua quota. Prima di esporlo su internet, proteggilo con l'autenticazione (FastMCP supporta bearer token e OAuth — vedi la documentazione di FastMCP, sezione Auth). Non committare mai le credenziali nel repo.
Risoluzione problemi
ModuleNotFoundError: httpx/fastmcp→ le dipendenze non sono installate nell'ambiente Python attivo:pip install -r requirements.txt.Errore all'avvio su variabili d'ambiente →
SAFERPLACES_USERoSAFERPLACES_TOKENnon impostate.Errore di autenticazione dalle API → controlla
USER_FIELD,TOKEN_FIELDeCREDENTIALS_INSIDE_INPUTSin cima asaferplaces_mcp.py: devono rispecchiare il body di una chiamata funzionante fatta a mano.Timeout su simulazioni lunghe → per
untrim_run_and_waitalzatimeout_seconds; il timeout delle singole richieste HTTP (300 s) si regola nella creazione del client httpx.
This server cannot be deployed
Maintenance
Related MCP Connectors
Location tools for Claude and other MCP clients, strongest in the US and Great Britain. Geocode whole lists with a confidence score per row, filter by distance, get road distances and drive-time areas, and plan multi-driver routes with Google Maps links. Check flood zones, crime and live warnings, find nearby places and UK registers (NHS, CQC, food hygiene), and keep shareable maps. Reads and writes Google Sheets. Free: sign in with Google.
Point Gecko at an OpenAPI spec; get first-call-correct, auth-hidden agent tools.
Climate and disaster risk for any place or property: flood risk, heat waves, storms and hurricanes, wildfires, earthquakes, sea level rise and 7-day weather risk. Is it safe to go there? Ask about any city, address or coordinates and get this week's weather risk (heat, cold, wind, heavy rain, snow), wildfires, earthquakes, floods and cyclones happening nearby right now, long-term exposure to 2050 and 2080 (flood depth, sea level rise, extreme heat, drought, water stress) and the country's disaster-risk profile and rank among 194 countries. Also compares and ranks countries by risk for ESG and insurance research, and in Claude and other MCP Apps hosts shows an interactive map of the place right in the chat. Every value cites its source: INFORM, ND-GAIN, World Bank, CMIP6, ERA5, IPCC AR6, WRI Aqueduct, GDACS, NASA FIRMS, OpenAQ, ECCC GDPS. Remote, free, no API key, read-only.
Every Canopy public API operation as a tool, run as you after a browser sign-in or on an API key.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceDynamically generates MCP tools from OpenAPI specifications, enabling AI assistants to interact with any REST API through natural language. Supports multiple APIs with authentication, parameter validation, and integration with Claude Desktop and LangChain.1MIT
- AlicenseNot gradedqualityDmaintenanceEnables Claude Desktop and other MCP clients to interact with any OAuth2-authenticated OpenAPI-based API through automatic tool generation from OpenAPI specifications, with built-in token management and authentication handling.5 npm3MIT
- AlicenseAqualityDmaintenanceWraps Claude Code as tools for MCP clients, enabling autonomous coding tasks via a 4-tool lifecycle with session management, async polling, and permission controls.473 npm21MIT
- AlicenseNot gradedqualityDmaintenanceConverts any OpenAPI/Swagger spec into an MCP server, exposing REST API endpoints as tools for Claude.MIT