Space MCP Server
MCP server giving AI agents access to NASA and space/astronomy data — APOD, Mars rover photos, near-Earth asteroids, exoplanets, Earth imagery, natural events, and space weather.
Features (10 Tools)
| Tool | Description |
|---|---|
get_astronomy_picture |
NASA's Astronomy Picture of the Day (APOD) |
search_nasa_images |
Search NASA's 140,000+ image/video library |
get_exoplanets |
Query 5,000+ confirmed exoplanets |
get_space_weather |
Solar flares, CMEs, geomagnetic storms (DONKI) |
get_mars_rover_photos |
Real photos from Curiosity, Perseverance, Opportunity, Spirit |
get_mars_rover_info |
Rover mission status, cameras, photo counts |
get_near_earth_objects |
Track asteroids approaching Earth (NeoWs) |
get_asteroid_details |
Orbital data and close approaches for specific asteroids |
get_earth_imagery |
Full-Earth photos from DSCOVR satellite (EPIC) |
get_natural_events |
Active wildfires, volcanoes, storms worldwide (EONET) |
Quick Start
Install from source
git clone https://github.com/AiAgentKarl/space-mcp-server.git
cd space-mcp-server
python -m venv .venv
.venv/Scripts/activate # Windows
# source .venv/bin/activate # Linux/Mac
pip install -e .
Configure
cp .env.example .env
# Edit .env and add your NASA API key (optional, DEMO_KEY works out of the box)
Get a free API key at https://api.nasa.gov/ for higher rate limits.
Run
space-mcp
# or
python -m src.server
Claude Code Integration
Add to your .mcp.json:
{
"mcpServers": {
"space": {
"type": "stdio",
"command": "path/to/.venv/Scripts/python.exe",
"args": ["-m", "src.server"],
"env": {
"NASA_API_KEY": "your-api-key-here"
}
}
}
}
API Sources
| API | Key Required | Rate Limit |
|---|---|---|
| NASA API (APOD, Mars, NeoWs, DONKI) | Yes (DEMO_KEY works) | 30/hour (DEMO), 1000/hour (registered) |
| EPIC | No | No limit |
| EONET | No | No limit |
| NASA Image Library | No | No limit |
| Exoplanet Archive | No | No limit |
Architecture
src/
├── server.py # FastMCP server entry point
├── config.py # Settings & environment variables
├── analytics.py # Usage tracking
├── clients/
│ ├── nasa.py # NASA API (APOD, Mars, NeoWs, DONKI)
│ ├── epic.py # EPIC Earth imagery
│ ├── eonet.py # EONET natural events
│ ├── nasa_images.py # NASA Image Library
│ └── exoplanet.py # Exoplanet Archive
└── tools/
├── astronomy.py # APOD, image search, exoplanets, space weather
├── mars.py # Mars rover photos & info
├── asteroids.py # Near-Earth objects & asteroid details
└── earth.py # EPIC imagery & natural events
License
MIT
Metadata
Release files for space-mcp-server 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| space_mcp_server-0.1.0.tar.gz | 12.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| space_mcp_server-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 31.6 kB
Release files / space_mcp_server-0.1.0.tar.gz
| Download URL | space_mcp_server-0.1.0.tar.gz |
|---|---|
| Size | 12.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a0be7862fd7ea0c7638d92f238e6c6cdbbd23f0b015a89762902e1414a89f7f8
|
|
BLAKE2b-256 checksum How to use checksums |
6e37f2c9e3b87adc7f3cc015a9f1ee8c86aabb2c461d1a906672289d22a21a6f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.3
|
Release files / space_mcp_server-0.1.0-py3-none-any.whl
| Download URL | space_mcp_server-0.1.0-py3-none-any.whl |
|---|---|
| Size | 18.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
257f162abbf0cd01067e8d114b30a6adf16f070c5f3590dda70917da09a15364
|
|
BLAKE2b-256 checksum How to use checksums |
2cf6f580a4e32cab45f80a3e84c10723cb8a3ab5e4bbac5841f74d1a757640fd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.3
|