MCP.so
登录

SNCF API MCP Server

@Kryzo

关于 SNCF API MCP Server

This project provides a modular Python wrapper for the SNCF API, with an MCP server interface that integrates seamlessly with Claude Desktop for intelligent journey planning and train information retrieval across France.

基本信息

分类

开发工具

运行时

python

传输方式

stdio

发布者

Kryzo

配置

暂无标准配置

该服务器的 README 中没有可解析的 MCP 配置块,请前往代码仓库查看安装说明。

代码仓库

工具

未检测到工具

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is SNCF API MCP Server?

A modular Python wrapper for the SNCF API that provides an MCP server interface for Claude Desktop, enabling intelligent journey planning and train information retrieval across France.

How to use SNCF API MCP Server?

Clone the repository, install dependencies (pip install -r requirements.txt), obtain an SNCF API key from the Navitia service on the SNCF portal, then configure Claude Desktop by adding the server to its claude_desktop_config.json with the path to sncf_server.py and the API key. Once configured, Claude can invoke MCP tools via natural language prompts.

Key features of SNCF API MCP Server

  • Intelligent journey planning between French cities
  • Comprehensive station details (transport types, nearby places, coordinates)
  • Real-time departure and arrival schedules
  • Disruption monitoring across the SNCF network
  • Smart station lookup by city, name, or coordinates
  • Fallback hardcoded coordinates for major cities

Use cases of SNCF API MCP Server

  • Plan a train journey from Paris to Lyon and get departure/arrival times
  • Check available transport types at a specific station (e.g., Gare de Lyon)
  • View the next five departures from a station in real time
  • Monitor current disruptions affecting a route (e.g., Paris to Marseille)
  • Find nearby points of interest around a train station

FAQ from SNCF API MCP Server

What API key is required?

You need an SNCF API key obtained from the Navitta service on the SNCF API Portal. The key is a UUID string.

What are the runtime dependencies?

Python 3.6+ and the packages requests, pandas, and mcp. Also requires the train_stations_europe.csv file in the correct location.

Where does station location data come from?

The server uses a CSV database (train_stations_europe.csv) and hardcoded coordinates for major French cities as a fallback when the API search fails.

What should I do if I get "No stations found for city"?

Try a more specific city name. For smaller cities, use the name of a nearby larger city. The system’s hardcoded coordinates for major French cities should work reliably.

How do I fix a "Failed to connect to SNCF API" error?

Check your internet connection, verify the API key is valid and not expired, and try again later as the SNCF API may be experiencing downtime.

评论

开发工具 分类下的更多 MCP 服务器