# MCP tools

> Five read-only tools, three catalog resources and three prompts. Each tool returns the same JSON as its HTTP route.

Source: https://docs.invariant-ai.com/mcp/tools

Every tool is read-only. Answers come back twice: as `structuredContent` (JSON) and as text for apps that only show text. A tool that can't answer returns `isError: true` with an `error` code and a message the model can act on, for example `fields_unknown` with the names it didn't recognise.

## Which tool do I need?

| You want | Tool |
| --- | --- |
| Facts at a point: elevation, flood zone, nearest substation, wind speed, fiber | `invariant_fetch` |
| The parcel at a point: owner, acres, zoning, value, buildings | `invariant_enrich` |
| An address turned into a coordinate | `invariant_geocode` |
| The right field names | `invariant_list_fields` |
| Distance, drive time, nearest airports or 230 kV substations, a labor shed | `invariant_proximity` |

## invariant\_fetch

Public facts at one US point. Same answer as [`POST /v1/fetch`](https://docs.invariant-ai.com/api/fetch).

| Input | Type | Notes |
| --- | --- | --- |
| `lat`, `lng` | number | WGS84. Send both, or send `address`. |
| `address` | string | A US street address with a house number. It's geocoded first, and the answer includes `geocode` so you can check `accuracy_type`. |
| `fields` | string[] | Required. Names from `invariant_list_fields`. |

```json
{"lat": 39.0438, "lng": -77.4874, "fields": ["elevation", "nearest_substation_distance_m", "within_floodplain_polygon"]}
```

Each field has `value`, `unit`, `status` (`ok`, `absent`, `failed`), `source`, `source_url`, `confidence` and `dataset_vintage`. Parcel fields such as the owner are not here; use `invariant_enrich`.

## invariant\_enrich

The parcel that contains a point. Same answer as [`POST /v1/enrich`](https://docs.invariant-ai.com/api/enrich).

| Input | Type | Notes |
| --- | --- | --- |
| `lat`, `lng` or `address` |  | As for `invariant_fetch`. A coordinate inside the parcel is safest. |
| `fields` | string[] | Enrich field names. |
| `preset` | string[] | Bundles: `parcel`, `zoning`, `buildings`, `valuation`, `legal`, `power`, `access`, `water`, `terrain`, `environment`, `climate`, `hazards`, `market`, `constraints`. |
| `all_fields` | boolean | Every field. A large answer, so prefer `fields` or `preset`. |

Send at least one of `fields`, `preset` or `all_fields`. Read `parcel_match.status` first: only `matched` returns parcel fields, and `field_omissions` says why each missing field has no value.

## invariant\_geocode

| Input | Type | Notes |
| --- | --- | --- |
| `address` | string | A US street address. |

Returns `lat`, `lng`, `accuracy_type` (`rooftop` or `range_interpolation`) and the normalized address. City names, ZIP codes alone and PO boxes are refused rather than answered with a centroid. See [`POST /v1/geocode`](https://docs.invariant-ai.com/api/geocode).

## invariant\_list\_fields

| Input | Type | Notes |
| --- | --- | --- |
| `endpoint` | `"fetch"` or `"enrich"` | Default `fetch`. |
| `query` | string | Words that must all appear in the name, layer, preset or description, such as `flood` or `substation kv`. |

Returns up to 200 rows with name, layer, unit, source and a short description. For `enrich` it also lists each preset and its size. No upstream calls, so it's instant.

## invariant\_proximity

One operation, wrapped in `req`. Same answer as [`POST /v1/proximity`](https://docs.invariant-ai.com/api/proximity).

```json
{"req": {"op": "nearest", "origin": "39.0438,-77.4874", "set": "@substations", "filters": {"min_kv": 230}, "n": 3, "mode": "driving"}}
```

| `op` | Does |
| --- | --- |
| `distance` | Every origin to every destination, straight-line or driving. |
| `nearest` | The closest records of a curated set: `@substations`, `@power_plants`, `@airports`, `@rail`, `@ports`, `@urban_areas`, `@hospitals`. |
| `screen` | Which origins are within a drive-time band of any anchor. |
| `labor_shed` | Civilian labor force and population within a drive time (5 to 90 minutes). |

Places are `"lat,lng"` text or full street addresses, never place names like "Dulles Airport".

## Resources

| URI | Holds |
| --- | --- |
| `invariant://catalog/fields` | Every fetch field with layer, unit, sources, TTL, description and what null means. |
| `invariant://enrich/fields` | Every enrich field with its presets and source. |
| `invariant://enrich/presets` | Each preset and the fields it expands to. |

## Prompts

| Prompt | Arguments | Produces |
| --- | --- | --- |
| `invariant_site_report` | `location` | A cited one-page profile: parcel, terrain and flood, power, access, hazards. |
| `invariant_flood_check` | `location` | In or out of a mapped flood zone, then the evidence. |
| `invariant_data_center_siting_report` | `location`, `target_mw` (optional) | Advance, hold or kill, with the power path, water, fiber, hazards and labor shed behind it. |

Prompts only tell the model which tools to call in what order. They don't change what the tools can read.
