env-data-mcp
cohere-llc/env-data-mcp
Acesso integrado a dados ambientais via MCP para consultas climáticas e geoespaciais
Ver no GitHubMCP Server que expõe dados ambientais (clima, solo, composição atmosférica, observações de satélite) como ferramentas chamáveis por assistentes IA compatíveis com MCP. Integra 9 fontes de dados operacionais (NASA POWER, SSURGO, SoilGrids, GBIF, Sentinel-5P, OCO-2, EMIT, ESS-DIVE, OpenAQ) e retorna JSON estruturado com proveniência completa.
Instalação
npx convez-ai cohere-llc/env-data-mcp1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.
Métricas
Casos de uso
- Análise climática e meteorológica
- Pesquisa ambiental e sustentabilidade
- Consultas de qualidade do ar e solo
Veredito

Ferramenta robusta para quem precisa de dados ambientais estruturados em workflows IA. Prototipagem completa com 9 fontes operacionais, CI/CD estabelecido e documentação clara; requer conhecimento técnico para integração e configuração de credenciais.
README
A tradução para o português deste README ainda está na fila.
env-data-mcp
MCP server that exposes environmental data — weather, soil, atmospheric composition,
and satellite observations — as tools callable by any MCP-compatible AI assistant or
workflow. Tools accept a location (point or bounding box) and a date range and return
structured JSON with the data and a _meta block that includes the data licence,
latency, and enough provenance information to reproduce the query.
Status: Prototype complete — 9 sources operational (NASA POWER, SSURGO, SoilGrids, GBIF, Sentinel-5P, OCO-2, EMIT, ESS-DIVE, OpenAQ). CI matrix on Python 3.11/3.12, nightly integration tests, schema stability assertions.
Quick start
git clone https://github.com/cohere-llc/env-data-mcp.git
cd env-data-mcp
uv sync
# Start the server (stdio transport; runs until killed with Ctrl-C)
uv run env-data-mcp
The server prints no output on start; an MCP client connects via stdio.
Hello-world example
With the server running, verify it works with this self-contained Python snippet:
# hello_world.py — run with: uv run python hello_world.py
import asyncio
from mcp import ClientSession, StdioServerParameters
from mcp.client.stdio import stdio_client
async def main():
params = StdioServerParameters(
command="uv",
args=["run", "env-data-mcp"],
)
async with stdio_client(params) as (read, write):
async with ClientSession(read, write) as session:
await session.initialize()
result = await session.call_tool(
"nasa_power_merra2_query",
arguments={
"latitude": 46.253,
"longitude": -119.477,
"start_date": "2023-05-01",
"end_date": "2023-05-03",
"temporal_resolution": "daily",
},
)
print(result)
asyncio.run(main())
Expected output shape:
{
"data": [
{"date": "2023-05-01", "T2M": 14.2, "T2M_units": "C", "PRECTOTCORR": 0.0, ...},
{"date": "2023-05-02", "T2M": 15.8, "T2M_units": "C", "PRECTOTCORR": 1.3, ...},
{"date": "2023-05-03", "T2M": 13.1, "T2M_units": "C", "PRECTOTCORR": 0.0, ...}
],
"_meta": {
"source": "nasa_power",
"rows_returned": 3,
"latency_s": 1.4,
"auth_required": false,
"success": true,
"license": "Public domain (NASA/US Government). Citation requested.",
"query_params": {"latitude": 46.253, "longitude": -119.477, ...}
}
}
Register in VS Code (.mcp.json)
Add to your VS Code workspace .mcp.json to make all tools available to GitHub Copilot:
{
"mcpServers": {
"env-data": {
"command": "uv",
"args": ["--directory", "/path/to/env-data-mcp", "run", "env-data-mcp"],
"env": {
"EARTHDATA_TOKEN": "${EARTHDATA_TOKEN}",
"OPENAQ_API_KEY": "${OPENAQ_API_KEY}",
"ESSDIVE_TOKEN": "${ESSDIVE_TOKEN}"
}
}
}
}
Replace /path/to/env-data-mcp with the absolute path to your local clone. The ${VAR} syntax reads from your shell environment (or from a .env file if your MCP host supports it).
Register on JupyterHub / Lakehouse
If the package wheel has been installed into the JupyterHub environment:
{
"mcpServers": {
"env-data": {
"command": "uvx",
"args": ["--from", "env-data-mcp", "env-data-mcp"],
"env": {
"EARTHDATA_TOKEN": "${EARTHDATA_TOKEN}",
"OPENAQ_API_KEY": "${OPENAQ_API_KEY}",
"ESSDIVE_TOKEN": "${ESSDIVE_TOKEN}"
}
}
}
}
See Credential setup for how to obtain each token.
Available tools
| Tool | Source | Auth | Description |
|---|---|---|---|
nasa_power_merra2_query | NASA POWER MERRA-2 | none | Atmospheric data (T, precip, RH, radiation) at a point |
nasa_power_merra2_bbox_query | NASA POWER MERRA-2 | none | Atmospheric data over a bounding box |
nasa_power_syn1deg_query | NASA POWER CERES SYN1deg | none | Radiation fluxes at a point |
nasa_power_syn1deg_bbox_query | NASA POWER CERES SYN1deg | none | Radiation fluxes over a bounding box |
ssurgo_*_query | USDA SSURGO | none | Soil properties for a US point |
ssurgo_*_bbox_query | USDA SSURGO | none | Soil properties within a bounding box |
gbif_occurrence_query | GBIF | none | Species occurrence records within a radius |
gbif_occurrence_bbox_query | GBIF | none | Species occurrence records within a bounding box |
soilgrids_query | ISRIC SoilGrids v2 | none | Global soil properties at a point |
soilgrids_bbox_query | ISRIC SoilGrids v2 | none | Global soil properties over a bounding box |
sentinel5p_query | Sentinel-5P TROPOMI | none | Atmospheric column at a point (CO / NO₂ / CH₄) |
sentinel5p_bbox_query | Sentinel-5P TROPOMI | none | Atmospheric column mean over a bounding box |
oco2_query | OCO-2 GEOS L3 | NASA EarthData token | Daily XCO₂ column at a point |
oco2_bbox_query | OCO-2 GEOS L3 | NASA EarthData token | Daily XCO₂ column over a bounding box |
emit_query | NASA EMIT L2B | NASA EarthData token | Mineral identification at a point |
emit_bbox_query | NASA EMIT L2B | NASA EarthData token | Mineral identification over a bounding box |
essdive_query | ESS-DIVE | ESS-DIVE token (free) | DOE environmental field datasets near a point |
essdive_bbox_query | ESS-DIVE | ESS-DIVE token (free) | DOE environmental field datasets within a bounding box |
openaq_query | OpenAQ v3 | API key (free) | Surface air quality measurements near a point |
openaq_bbox_query | OpenAQ v3 | API key (free) | Surface air quality measurements within a bounding box |
* For SSURGO tools, replace the (*) with one of: area_summary, ecological_site, parent_material, seasonal_hydrology, soil_profile, soil_suitability, soil_temperature, or subsurface_barriers.
Environment variables
| Variable | Required by | Description |
|---|---|---|
EARTHDATA_TOKEN | OCO-2, EMIT | NASA EarthData bearer token — register free at urs.earthdata.nasa.gov |
ESSDIVE_TOKEN | ESS-DIVE | ESS-DIVE API token — register free at ess-dive.lbl.gov |
OPENAQ_API_KEY | OpenAQ | Free key from openaq.org — requests without a key are rejected by the API |
Development
Requirements
- Python ≥ 3.11
- uv (install with
pip install uvorcurl -Lsf https://astral.sh/uv/install.sh | sh)
Install with dev dependencies
uv sync --extra dev
Run the unit tests (no network required)
uv run pytest tests/unit/ -m "not integration" -v
Expected output: 250+ unit tests pass; all HTTP / S3 calls are mocked.
Run tests with coverage report
uv run pytest tests/unit/ -m "not integration" --cov=env_data_mcp --cov-report=html
# then open htmlcov/index.html
Run integration tests (requires network)
uv run pytest tests/ -m integration -v
OpenAQ integration tests also require OPENAQ_API_KEY to be set.
Run example notebooks
Two demonstration notebooks are included:
| Notebook | Description |
|---|---|
notebooks/grow_point_sample_demo.ipynb | All 6 sources for 5 real GROW field samples |
notebooks/pnnl_bbox_demo.ipynb | NASA POWER + Sentinel-5P over the PNNL Richland bbox |
# load notebook dependencies
uv sync --extra dev --extra notebook
# Run interactively
jupyter lab notebooks/
# Or run headlessly via nbmake (network required; S5P cells take 30–120 s each)
uv run pytest notebooks/ --no-cov
Data licences
Each data source adapter carries a LICENSE_INFO constant with SPDX identifier, full
licence name, and URL. Human-readable licence text and citation requirements for all
sources are collected in LICENSES.md.
| Source | Licence |
|---|---|
| NASA POWER | Public domain (NASA) |
| SSURGO | Public domain (USDA) |
| SoilGrids v2 | CC BY 4.0 |
| GBIF | CC0 / CC BY / CC BY-NC per record |
| Sentinel-5P | ESA Copernicus Open Access |
| OpenAQ | CC BY 4.0 |
| OCO-2 | Public domain (NASA) |
| EMIT | Public domain (NASA) |
| ESS-DIVE | Varies per dataset |
Contributing
To add a new data source:
- Create
src/env_data_mcp/sources/<name>.pywith aLICENSE_INFOdict constant and one or more@mcp.toolfunctions. - Write unit tests in
tests/unit/test_<name>.pythat mock all HTTP / S3 calls. - Write an integration test in
tests/integration/test_<name>.pymarked@pytest.mark.integration. - Add licence text to
LICENSES.md. - Add a notebook cell to
notebooks/api_smoke_test.ipynbdemonstrating a real call.