SG Gov MCP Server
Unified MCP server offering 30 tools for Singapore government and public data including weather, transport, education, and property, with many tools working immediately without API keys.
README
🇸🇬 SG Gov MCP Server
A unified MCP server that gives AI agents access to 30 tools covering Singapore government and public data — weather, transport, education, property, companies, and 2000+ datasets.
Works immediately with zero API keys. Transport and mapping tools unlock with free registration.
Quick Start
npm install
npm run build
Use with Kiro
Add to your agent config or .kiro/settings/mcp.json:
{
"mcpServers": {
"sg-gov": {
"command": "node",
"args": ["/path/to/sg-gov-mcp/dist/index.js"]
}
}
}
Use with Claude Desktop
Add to claude_desktop_config.json:
{
"mcpServers": {
"sg-gov": {
"command": "node",
"args": ["/path/to/sg-gov-mcp/dist/index.js"],
"env": {
"SG_LTA_KEY": "your_key_here",
"SG_ONEMAP_EMAIL": "your_email",
"SG_ONEMAP_PASSWORD": "your_password"
}
}
}
}
Available Tools (30)
Tier 1 — No API Key Required ✅
| Tool | Description |
|---|---|
sg_setup_status |
Check which API keys are configured |
sg_weather |
2-hour, 24-hour, or 4-day weather forecast |
sg_air_quality |
PSI and PM2.5 readings by region |
sg_uv_index |
Current UV index |
sg_dengue |
Active dengue cluster locations |
sg_rainfall |
Real-time rainfall across 76 stations |
sg_dataset_search |
Find data.gov.sg datasets |
sg_dataset_fetch |
Fetch rows from any dataset |
sg_hdb_prices |
HDB resale flat prices (1990-2025) |
sg_coe_prices |
COE bidding results and premiums |
sg_schools |
School directory (subjects, CCAs, programmes) |
sg_holidays |
Singapore public holidays |
sg_hawker_centres |
Hawker centre locations |
sg_nus_modules |
NUS module search (via NUSMods) |
sg_ntu_modules |
NTU module search (via ModGod API) |
sg_taxi_availability |
Real-time taxi locations |
sg_company_search |
ACRA company/business search by name |
sg_neighbourhood_report |
Combined area report (HDB prices, schools, weather, air quality) |
Tier 2 — Free API Key Required 🔑
| Tool | Requires | Description |
|---|---|---|
sg_bus_arrival |
SG_LTA_KEY |
Real-time bus arrival times |
sg_train_alerts |
SG_LTA_KEY |
MRT/LRT service disruptions |
sg_traffic_incidents |
SG_LTA_KEY |
Current road incidents |
sg_traffic_images |
SG_LTA_KEY |
Live traffic camera feeds |
sg_carpark |
SG_LTA_KEY |
Real-time carpark availability |
sg_ev_charging |
SG_LTA_KEY |
EV charging point availability |
sg_flood_alerts |
SG_LTA_KEY |
PUB flood alerts |
sg_mrt_crowd |
SG_LTA_KEY |
MRT station crowd density |
sg_geocode |
SG_ONEMAP_* |
Address → coordinates |
sg_reverse_geocode |
SG_ONEMAP_* |
Coordinates → address |
sg_route |
SG_ONEMAP_* |
Route planning (drive/walk/PT) |
sg_nearby |
SG_ONEMAP_* |
Find nearby amenities |
API Key Setup
All keys are free. Registration takes ~2 minutes each.
LTA DataMall (bus, train, traffic)
- Go to https://datamall.lta.gov.sg/content/datamall/en/request-for-api.html
- Fill in the form — you get the key via email instantly
- Set
export SG_LTA_KEY=your_key
OneMap (geocoding, routing)
- Go to https://www.onemap.gov.sg and register
- Set
export SG_ONEMAP_EMAIL=your_email - Set
export SG_ONEMAP_PASSWORD=your_password
The server handles token refresh automatically.
Data Sources
| Source | What It Provides |
|---|---|
| data.gov.sg | 2000+ government datasets + real-time APIs |
| LTA DataMall | Bus, train, traffic, carpark, taxi, EV charging |
| OneMap (SLA) | Geocoding, routing, demographics, nearby amenities |
| NUSMods | NUS modules and timetables |
| NTU ModGod | NTU modules, venues, graduation requirements |
Examples
Ask your AI agent:
- "What's the weather forecast for the next 2 hours?"
- "When's the next bus at stop 83139?"
- "Show me HDB resale prices in Tampines for 4-room flats"
- "Find NUS computer science modules about machine learning"
- "Are there any MRT service disruptions right now?"
- "What hawker centres are near Bishan?"
- "Plan a driving route from Changi Airport to NUS"
Development
npm run dev # Watch mode
npm run build # Compile TypeScript
npm start # Run the server
Architecture
stdio (JSON-RPC) ←→ MCP Server ←→ API Clients ←→ External APIs
├── data.gov.sg (no key)
├── NUSMods (no key)
├── NTU ModGod (no key)
├── LTA DataMall (key)
└── OneMap (key)
License
MIT
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。