catastro-gps-mcp 2.1.0 → 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## 2.2.0 (2026-10-23)
4
+
5
+ - New `get_parcel_sigpac`: every SIGPAC enclosure of a Spanish parcel (ES, PV, NA) from `GET /v1/parcels/{ref}/sigpac`: SIGPAC parcel key, `match`, `land_use_code`, `land_use` in `lang`, `crop_code`, `use_class`, `area_ha`, `irrigation_pct`, `mean_slope_pct`, `altitude_m`, `pasture_eligibility_pct`, `cap_region` (null when SIGPAC does not apply them), `incidents`, attribution and licence, outline with `include_geometry`. `SIG_001` (SIGPAC down) is explained as retryable and not charged.
6
+ - `get_parcel_subparcels` states its real coverage: Spain, Austria, Germany, Czechia, the Netherlands, France, Portugal, Sweden, Switzerland, Finland, Belgium, Ireland, Slovenia, Estonia and Greece.
7
+
3
8
  ## 2.1.0 (2026-10-21)
4
9
 
5
10
  - New `get_parcel_subparcels`: every crop or land-use subparcel (`crop_code`, `crop` in `lang`, `crop_original`, `area_m2`, `kind`, `use_class`, `intensity`, `land_type`, `land_class`, `source`, outline with `include_geometry`). Spain (foral territories included), Austria, Estonia and Greece. `SUB_001` (source down) is explained as retryable and not charged.
package/README.md CHANGED
@@ -49,7 +49,8 @@ Use the same `npx -y catastro-gps-mcp` command with `CATASTROGPS_API_KEY` in the
49
49
  | `search_address` | Postal address in free text to ranked parcels, with confidence and whether the number and municipality match | ES (with PV and NA entrances) and FR, IT, DE, AT, NL, BE, PL, CH, CZ, DK, NO, FI, EE, LV, LT, SI, SK, BG, GR, CY, LU, LI, IS, IE, UK, PT |
50
50
  | `get_units` | Every unit (dwelling, shop, garage, storage) of a Spanish building: stair, floor, door, use, area, participation, year. Paginated, 200 per page | ES, PV, NA |
51
51
  | `resolve_reference` | Free, no quota: is this text a reference, coordinates or a place name, and of which country | All |
52
- | `get_parcel_subparcels` | Every crop or land-use part of the parcel: crop code, crop name in 10 languages, original label, area, land-use class, source and (optionally) outline. A source failure is `SUB_001`, not charged | ES (with Bizkaia, Álava, Navarre, Gipuzkoa), AT, EE, GR |
52
+ | `get_parcel_subparcels` | Every crop or land-use part of the parcel: crop code, crop name in 10 languages, original label, area, land-use class, source and (optionally) outline. A source failure is `SUB_001`, not charged | ES (with Bizkaia, Álava, Navarre, Gipuzkoa), AT, DE, CZ, NL, FR, PT, SE, CH, FI, BE, IE, SI, EE, GR |
53
+ | `get_parcel_sigpac` | Every SIGPAC enclosure (recinto) of a Spanish parcel: land-use code and name in 10 languages, area in ha, irrigation coefficient, slope, altitude, CAP pasture eligibility and region, incidents and (optionally) outline. Cite "Fuente: FEGA — SIGPAC". A SIGPAC failure is `SIG_001`, not charged | ES, PV, NA |
53
54
  | `get_crop_catalog` | Free, no quota: every crop code with its name in the chosen language and its land-use class | All crop catalogues |
54
55
  | `get_neighbors` | Parcels that touch or surround the parcel (up to 60) with reference and centre point | ES from the cadastre; elsewhere from our own copy (`supported: false` when not) |
55
56
  | `list_provinces`, `list_municipalities`, `list_streets` | Spanish cadastre provinces, municipalities (with INE code) and streets of a municipality | ES (common territory) |
@@ -58,14 +59,14 @@ Use the same `npx -y catastro-gps-mcp` command with `CATASTROGPS_API_KEY` in the
58
59
  | `get_ground_motion` | Ground motion measured by satellite (Copernicus EGMS, 2020-2024): subsidence or uplift in mm/year, fastest-sinking cell, east-west motion, yearly displacement; says so when there are no radar reflectors | Same as `get_terrain` |
59
60
  | `get_solar_potential` | PVGIS photovoltaic estimate: kWp, kWh/year, savings, payback, CO2, tilt | ES, PV, NA, PT, FR, IT, DE |
60
61
  | `get_agriculture` | Land use, main crop, NDVI and a reference crop price (SIGPAC detail in Spain) | ES, PV, NA, PT, FR, IT, DE |
61
- | `get_market_data` | Aggregated price reference for the parcel's area. Never individual sales | Sales: FR, IT, DE (NRW only). ES, PV, NA: official province prices (`zone_prices`). PT: none |
62
+ | `get_market_data` | Rural land prices, paid API plans only. Never individual sales or housing figures | ES, PV, NA: rural parcels only, small agricultural buildings allowed (`crop_prices`, `zone_prices.rural`); anything else answers `MKT_001`, not charged |
62
63
  | `get_investment_score` | Score 0-100 with a rating and qualitative factor levels (high / medium / low / not available) | ES, PV, NA, PT, FR, IT, DE |
63
64
  | `get_value_history` | Area and land-use snapshots of the parcel over time | ES, PV, NA, PT, FR, IT, DE, AT |
64
65
  | `compare_parcels` | Two or three parcels side by side: location, solar, agriculture, score | ES, PT, FR, IT, DE (not PV or NA) |
65
66
 
66
67
  ## Quota, prepaid balance and limits
67
68
 
68
- - Only successful answers with data spend quota: a not found, a validation error, `CNV_COVERAGE`, `CNV_AMBIGUOUS`, a 5xx and an answer without data (`available: false`) are free. `resolve_reference` and `get_crop_catalog` never spend; `get_parcel_subparcels` is free when the parcel has none.
69
+ - Only successful answers with data spend quota: a not found, a validation error, `CNV_COVERAGE`, `CNV_AMBIGUOUS`, a 5xx and an answer without data (`available: false`) are free. `resolve_reference` and `get_crop_catalog` never spend; `get_parcel_subparcels` and `get_parcel_sigpac` are free when the parcel has none.
69
70
  - Each successful call costs 1 unit, except `get_units` (one unit per unit served in the page, minimum 1) and `compare_parcels` (one per parcel found).
70
71
  - Every result carries a `quota` object read from that same response: `remaining`, `limit`, `resets_at`, `plan`, and when they apply `prepaid_overage`, `prepaid_balance_eur`, `overage_units_left`, `per_minute_remaining`, and on `get_units` with a contract per-finca cap `finca_cap` / `finca_cap_used`.
71
72
  - When the monthly quota runs out the API does not cut you off if you have prepaid balance: each extra unit is paid from it (top up at [parcelgps.com/app/developer](https://parcelgps.com/app/developer)). With the quota used up and no balance the call fails with `KEY_AUTH_004` (HTTP 429, never 402) and the error says whether to top up or upgrade, and when the quota resets.
@@ -73,7 +74,7 @@ Use the same `npx -y catastro-gps-mcp` command with `CATASTROGPS_API_KEY` in the
73
74
 
74
75
  ### What the market, score and history tools can and cannot tell
75
76
 
76
- - **`get_market_data`** has numbers only where an official source gives them: France (DVF recorded sales: average €/m², number of sales, last sale date, estimated value), Italy (OMI zone values from the Agenzia delle Entrate) and Germany (official *Bodenrichtwert* land value per m², North Rhine-Westphalia only; elsewhere in Germany it answers `available: false`). In Spain (PV and NA included) it returns `zone_prices`: the official average prices of the parcel's province (housing per built m² from MIVAU, farmland per hectare from MAPA) with statistic, authority and period; there are no parcel-level sales. Portugal answers `available: false`.
77
+ - **`get_market_data`** is for paid API plans only (a Free-plan key gets `KEY_PLAN_001`, not charged) and only prices rural land: agricultural parcels in Spain (Basque Country and Navarre included), small agricultural buildings (sheds, farm stores, ponds, greenhouses) allowed; the figure is the land price, buildings are not valued. It returns `crop_prices` (price per hectare for each crop group of the parcel, with the number of sales behind it) and `zone_prices.rural` (the province farmland price per hectare). Housing, industrial or any other non-agricultural property is not supported and answers `MKT_001` with nothing charged; so does rural land without a price and any other country.
77
78
  - **`get_investment_score`** combines what the API can gather for the parcel: solar potential and agricultural use everywhere it answers, market prices only in France, Italy and Germany (NRW). Accessibility and risk are not computed yet and come back as `not_available`, so the score is relative to the factors that were available. You get the score, the rating and qualitative factor levels, never the weights.
78
79
  - **`get_value_history`** starts the first time anyone looks the parcel up through Catastro GPS (at most one snapshot every 30 days). A parcel nobody has queried returns an empty list. It records area and land use; the official cadastral value is not recorded yet, so `cadastral_value_eur` is always `null` and `change_pct` is the change in area.
79
80
  - **`compare_parcels`** fills area, land use and municipality only for Spanish parcels; for Portugal, France, Italy and Germany it returns the location, solar, agriculture and score. It does not include market prices. A parcel that is not found comes back with an error and the others are still compared.
@@ -1,4 +1,4 @@
1
- import type { Quota, ServerConfig, ApiResponse, ParcelData, PolygonData, SolarData, TerrainData, GroundMotionData, AgroData, MarketData, ScoreData, ValueHistoryData, CompareData, CoordinatesSearchData, AddressCandidatesData, UnitsPageData, ResolveData, SubparcelsData, CropCatalogData, NeighborsData, ProvincesData, MunicipalitiesData, StreetsData } from "../types/index.js";
1
+ import type { Quota, ServerConfig, ApiResponse, ParcelData, PolygonData, SolarData, TerrainData, GroundMotionData, AgroData, MarketData, ScoreData, ValueHistoryData, CompareData, CoordinatesSearchData, AddressCandidatesData, UnitsPageData, ResolveData, SubparcelsData, SIGPACData, CropCatalogData, NeighborsData, ProvincesData, MunicipalitiesData, StreetsData } from "../types/index.js";
2
2
  export interface ApiErrorExtras {
3
3
  quota?: Quota;
4
4
  retryAfterSeconds?: number;
@@ -25,6 +25,7 @@ export declare class CatastroGPSClient {
25
25
  private parcelPath;
26
26
  getParcelByReference(reference: string, country?: string, lang?: string): Promise<ApiResponse<ParcelData>>;
27
27
  getSubparcels(reference: string, country?: string, lang?: string): Promise<ApiResponse<SubparcelsData>>;
28
+ getSIGPAC(reference: string, country?: string, lang?: string): Promise<ApiResponse<SIGPACData>>;
28
29
  getNeighbors(reference: string, country?: string): Promise<ApiResponse<NeighborsData>>;
29
30
  getCropCatalog(lang?: string): Promise<ApiResponse<CropCatalogData>>;
30
31
  listProvinces(): Promise<ApiResponse<ProvincesData>>;
@@ -151,6 +151,9 @@ export class CatastroGPSClient {
151
151
  async getSubparcels(reference, country, lang) {
152
152
  return this.send("GET", this.parcelPath(reference, "/subparcels"), { country, lang });
153
153
  }
154
+ async getSIGPAC(reference, country, lang) {
155
+ return this.send("GET", this.parcelPath(reference, "/sigpac"), { country, lang });
156
+ }
154
157
  async getNeighbors(reference, country) {
155
158
  return this.send("GET", this.parcelPath(reference, "/neighbors"), { country });
156
159
  }
package/build/server.js CHANGED
@@ -14,6 +14,7 @@ import { registerCompareParcels } from "./tools/compare-parcels.js";
14
14
  import { registerGetUnits } from "./tools/get-units.js";
15
15
  import { registerResolveReference } from "./tools/resolve-reference.js";
16
16
  import { registerGetParcelSubparcels } from "./tools/get-parcel-subparcels.js";
17
+ import { registerGetParcelSIGPAC } from "./tools/get-parcel-sigpac.js";
17
18
  import { registerGetCropCatalog } from "./tools/get-crop-catalog.js";
18
19
  import { registerGetNeighbors } from "./tools/get-neighbors.js";
19
20
  import { registerListProvinces } from "./tools/list-provinces.js";
@@ -42,6 +43,7 @@ export function createServer(config) {
42
43
  registerGetUnits(server, client);
43
44
  registerResolveReference(server, client);
44
45
  registerGetParcelSubparcels(server, client);
46
+ registerGetParcelSIGPAC(server, client);
45
47
  registerGetCropCatalog(server, client);
46
48
  registerGetNeighbors(server, client);
47
49
  registerListProvinces(server, client);
@@ -7,8 +7,6 @@ function zonePrice(price) {
7
7
  return compact({
8
8
  price_per_m2_eur: price.pricePerM2Eur,
9
9
  price_per_ha_eur: price.pricePerHaEur,
10
- statistic: price.statistic,
11
- authority: price.authority,
12
10
  period: price.period,
13
11
  });
14
12
  }
@@ -19,48 +17,51 @@ function zonePrices(prices) {
19
17
  zone: prices.zone,
20
18
  zone_level: prices.zoneLevel,
21
19
  municipality: prices.municipality ?? null,
22
- urban: zonePrice(prices.urban),
23
20
  rural: zonePrice(prices.rural),
24
21
  };
25
22
  }
23
+ function cropPrices(prices) {
24
+ return (prices ?? []).map((price) => compact({
25
+ crop_group: price.cropGroup,
26
+ crop_group_name: price.cropGroupName,
27
+ land_use_codes: price.landUseCodes,
28
+ area_ha: price.areaHa,
29
+ price_per_ha_eur: price.pricePerHaEur,
30
+ sales_count: price.salesCount,
31
+ level: price.level,
32
+ zone: price.zone,
33
+ period: price.period,
34
+ }));
35
+ }
26
36
  export function registerGetMarket(server, client) {
27
37
  server.registerTool("get_market_data", {
28
38
  title: "Get Market Data",
29
- description: "Aggregated land and property price reference for the area around a parcel. Never returns " +
30
- "individual sales. Price figures exist only in France (DVF recorded sales: average EUR/m2, " +
31
- "number of sales, last sale date, estimated value), Italy (OMI zone values from Agenzia delle " +
32
- "Entrate) and Germany (official Bodenrichtwert land value per m2, North Rhine-Westphalia only; " +
33
- "elsewhere in Germany it answers available=false). For Spain (ES, PV, NA) it returns zone_prices: " +
34
- "the official average prices of the parcel's province (housing per built m2 from MIVAU, farmland " +
35
- "per hectare from MAPA), each with statistic, authority and period; no parcel-level sales. " +
36
- "Portugal answers available=false. " +
37
- "One API call.",
39
+ description: "Paid API plans only (Developer, Startup, Growth, Enterprise): with a Free-plan key it answers " +
40
+ "KEY_PLAN_001 and nothing is charged. Rural land only: prices agricultural parcels in Spain (ES, PV, NA), " +
41
+ "small agricultural buildings allowed (sheds, farm stores, ponds, greenhouses), with crop_prices (EUR per " +
42
+ "hectare for each crop group of the parcel, with the number of sales behind it) and zone_prices.rural (the " +
43
+ "province farmland price per hectare). It is the price of the land; buildings are not valued (price_note). " +
44
+ "Housing, industrial or any other non-agricultural property is not supported and answers MKT_001 with " +
45
+ "nothing charged; so does rural land without a price, and any other country. One API call, charged only " +
46
+ "when a price comes back.",
38
47
  inputSchema: {
39
48
  reference: z.string().min(1).describe("Official cadastral reference"),
40
49
  country: z
41
50
  .enum(ENRICHMENT_COUNTRIES)
42
51
  .optional()
43
- .describe("Optional country code: ES, PV, NA, PT, FR, IT or DE. Omit to auto-detect."),
52
+ .describe("Optional country code. Rural land prices exist for ES, PV and NA; other countries answer MKT_001. Omit to auto-detect."),
44
53
  },
45
54
  }, async ({ reference, country }) => {
46
55
  try {
47
56
  const { data: d, quota } = await client.getMarketData(reference, country);
48
- const hasFigures = (d.pricePerM2Eur ?? 0) > 0 || (d.estimatedPriceEur ?? 0) > 0;
49
57
  return jsonResult({
50
58
  reference,
51
59
  country: country ?? null,
52
60
  available: d.available,
53
- has_price_figures: hasFigures,
54
- price_per_m2_eur: d.pricePerM2Eur || null,
55
- estimated_value_eur: d.estimatedPriceEur || null,
56
- sales_count: d.salesCount || null,
57
- last_sale_date: d.lastSaleDate || null,
58
61
  granularity: d.granularity || null,
59
- data_quality: d.dataQuality ?? null,
60
- updated: d.updatedAt || null,
61
- source: d.source ?? null,
62
- note: d.message || null,
62
+ crop_prices: cropPrices(d.cropPrices),
63
63
  zone_prices: zonePrices(d.zonePrices),
64
+ price_note: d.priceNote ?? null,
64
65
  }, quota);
65
66
  }
66
67
  catch (error) {
@@ -0,0 +1,4 @@
1
+ import type { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
2
+ import type { CatastroGPSClient } from "../client/catastrogps-api.js";
3
+ export declare function registerGetParcelSIGPAC(server: McpServer, client: CatastroGPSClient): void;
4
+ //# sourceMappingURL=get-parcel-sigpac.d.ts.map
@@ -0,0 +1,80 @@
1
+ import { z } from "zod";
2
+ import { CROP_LANGUAGES, SIGPAC_COUNTRIES } from "../types/index.js";
3
+ import { compact, handleToolError, jsonResult } from "./shared.js";
4
+ function mapEnclosure(row, includeGeometry) {
5
+ return {
6
+ ...compact({
7
+ id: row.id,
8
+ enclosure: row.enclosure,
9
+ land_use_code: row.landUseCode,
10
+ land_use: row.landUse,
11
+ crop_code: row.cropCode,
12
+ use_class: row.useClass,
13
+ use_class_name: row.useClassName,
14
+ area_ha: row.areaHa,
15
+ }),
16
+ irrigation_pct: row.irrigationPct ?? null,
17
+ mean_slope_pct: row.meanSlopePct ?? null,
18
+ altitude_m: row.altitudeM ?? null,
19
+ pasture_eligibility_pct: row.pastureEligibilityPct ?? null,
20
+ cap_region: row.capRegion ?? null,
21
+ incidents: row.incidents ?? [],
22
+ ...(includeGeometry ? { geometry: row.geometry ?? null } : {}),
23
+ };
24
+ }
25
+ export function registerGetParcelSIGPAC(server, client) {
26
+ server.registerTool("get_parcel_sigpac", {
27
+ title: "Get Parcel SIGPAC Enclosures",
28
+ description: "Every SIGPAC enclosure (recinto) of a Spanish parcel, the CAP land parcel identification system: " +
29
+ "SIGPAC id, land-use code (TA, OV, VI, FY, PS...) with its name in the requested language, area in " +
30
+ "hectares, irrigation coefficient, mean slope, altitude, CAP pasture eligibility and region, " +
31
+ "incidents with their official text and, with include_geometry, the GeoJSON outline. Spain, the " +
32
+ "Basque Country and Navarre only; other countries answer CNV_COVERAGE. match tells whether the " +
33
+ "SIGPAC parcel was found by the cadastral reference or under the parcel's point. Source FEGA " +
34
+ "SIGPAC: cite 'Fuente: FEGA - SIGPAC'. One API call; free when there are no enclosures. If SIGPAC " +
35
+ "does not answer it returns SIG_001: nothing is charged, retry in a few seconds.",
36
+ inputSchema: {
37
+ reference: z.string().min(1).describe("Official Spanish cadastral reference of the parcel or unit"),
38
+ country: z
39
+ .enum(SIGPAC_COUNTRIES)
40
+ .optional()
41
+ .describe("Optional: ES, PV (Basque Country) or NA (Navarre). Omit to auto-detect."),
42
+ lang: z.enum(CROP_LANGUAGES).optional().describe("Language of land-use names (default English)"),
43
+ include_geometry: z
44
+ .boolean()
45
+ .optional()
46
+ .describe("Include the GeoJSON outline of each enclosure (large). Default false."),
47
+ },
48
+ }, async ({ reference, country, lang, include_geometry }) => {
49
+ try {
50
+ const { data: d, quota } = await client.getSIGPAC(reference, country, lang);
51
+ const parcel = d.sigpacParcel;
52
+ return jsonResult({
53
+ reference: d.reference,
54
+ country: d.country ?? country ?? null,
55
+ sigpac_parcel: parcel
56
+ ? {
57
+ province: parcel.province,
58
+ municipality: parcel.municipality,
59
+ aggregate: parcel.aggregate,
60
+ zone: parcel.zone,
61
+ polygon: parcel.polygon,
62
+ parcel: parcel.parcel,
63
+ }
64
+ : null,
65
+ match: d.match ?? null,
66
+ count: d.count,
67
+ total_area_ha: d.totalAreaHa,
68
+ crs: d.crs,
69
+ retrieved_at: d.retrievedAt ?? null,
70
+ attribution: d.source?.attribution ?? null,
71
+ license: d.source?.license ?? null,
72
+ enclosures: (d.enclosures ?? []).map((row) => mapEnclosure(row, include_geometry)),
73
+ }, quota);
74
+ }
75
+ catch (error) {
76
+ return handleToolError(error);
77
+ }
78
+ });
79
+ }
80
+ //# sourceMappingURL=get-parcel-sigpac.js.map
@@ -9,7 +9,8 @@ export function registerGetParcelSubparcels(server, client) {
9
9
  "(cadastral, declaredCrop, landCover), a common use_class (arable, vineyard, olive, forest...), " +
10
10
  "intensity, land type and class, source and, with include_geometry, its GeoJSON outline. " +
11
11
  "Spain (Catastro, including Bizkaia, Alava, Navarre; Gipuzkoa without outlines), Austria, " +
12
- "Estonia and Greece. One API call; free when the parcel has none. If the source does not " +
12
+ "Germany, Czechia, the Netherlands, France, Portugal, Sweden, Switzerland, Finland, Belgium, " +
13
+ "Ireland, Slovenia, Estonia and Greece. One API call; free when the parcel has none. If the source does not " +
13
14
  "answer it returns SUB_001: nothing is charged, retry in a few seconds. Translate codes with " +
14
15
  "get_crop_catalog.",
15
16
  inputSchema: {
@@ -4,7 +4,8 @@ import { handleToolError, jsonResult } from "./shared.js";
4
4
  export function registerGetValueHistory(server, client) {
5
5
  server.registerTool("get_value_history", {
6
6
  title: "Get Parcel History",
7
- description: "Snapshots of a parcel as the official cadastre reported it over time: area and land use, " +
7
+ description: "Paid API plans only: with a Free-plan key it answers KEY_PLAN_001 and nothing is charged. " +
8
+ "Snapshots of a parcel as the official cadastre reported it over time: area and land use, " +
8
9
  "at most one snapshot every 30 days. History starts the first time anyone looks the parcel " +
9
10
  "up through CatastroGPS (get_parcel) and grows from there, so a parcel never queried before " +
10
11
  "returns an empty list. The official cadastral value is not recorded yet (always null). " +
@@ -13,6 +13,8 @@ const FRIENDLY_MESSAGES = {
13
13
  RATE_LIMIT_EXCEEDED: "Too many requests. Slow down and retry.",
14
14
  UNAUTHORIZED: `Missing or invalid API key. Get one at ${PRICING_URL}`,
15
15
  PRO_REQUIRED: `This endpoint needs a developer API key. Get one at ${PRICING_URL}`,
16
+ KEY_PLAN_001: `Price data (market and value history) is only available on paid API plans. Nothing was charged. Upgrade at ${PRICING_URL}`,
17
+ MKT_001: "No price can be estimated for this parcel: price data only covers rural land (agricultural parcels in Spain; small agricultural buildings such as sheds, ponds or greenhouses are allowed). Housing, industrial or any other non-agricultural property is not supported, and rural land without a price gives the same answer. Nothing was charged.",
16
18
  NOT_FOUND: "Nothing found. Check the reference (or address) and the country code.",
17
19
  VALIDATION_ERROR: "Invalid input. Check the reference format for this country.",
18
20
  CNV_COVERAGE: "That reference or point is in a country that is not covered yet.",
@@ -20,6 +22,7 @@ const FRIENDLY_MESSAGES = {
20
22
  CNV_PLACE_NAME: "That looks like a place name, not a cadastral reference. Use coordinates or search_address instead.",
21
23
  SERVICE_UNAVAILABLE: "The official cadastre for this country is not responding. Try again in a few minutes.",
22
24
  SUB_001: "The subparcels of this parcel could not be read right now. Nothing was charged; retry in a few seconds.",
25
+ SIG_001: "SIGPAC could not be read right now. Nothing was charged; retry in a few seconds.",
23
26
  INTERNAL_ERROR: "Internal server error. Try again later.",
24
27
  MCP_TIMEOUT: "The request timed out. Official cadastres can be slow; try again or raise CATASTROGPS_TIMEOUT.",
25
28
  MCP_NETWORK: "Could not reach the CatastroGPS API. Check your connection or CATASTROGPS_API_URL.",
@@ -117,6 +117,53 @@ export interface SubparcelsData {
117
117
  count: number;
118
118
  subparcels: Subparcel[];
119
119
  }
120
+ export declare const SIGPAC_COUNTRIES: readonly ["ES", "PV", "NA"];
121
+ export interface SIGPACParcelKey {
122
+ province: number;
123
+ municipality: number;
124
+ aggregate: number;
125
+ zone: number;
126
+ polygon: number;
127
+ parcel: number;
128
+ }
129
+ export interface SIGPACEnclosure extends SIGPACParcelKey {
130
+ id: string;
131
+ enclosure: number;
132
+ landUseCode: string;
133
+ landUse?: string;
134
+ cropCode?: string;
135
+ useClass?: string;
136
+ useClassName?: string;
137
+ areaHa: number;
138
+ irrigationPct: number | null;
139
+ meanSlopePct: number | null;
140
+ altitudeM: number | null;
141
+ pastureEligibilityPct: number | null;
142
+ capRegion: number | null;
143
+ incidents: Array<{
144
+ code: number;
145
+ description?: string;
146
+ }> | null;
147
+ geometry: unknown;
148
+ }
149
+ export interface SIGPACData {
150
+ reference: string;
151
+ country: string;
152
+ sigpacParcel: SIGPACParcelKey | null;
153
+ match?: "reference" | "point";
154
+ count: number;
155
+ totalAreaHa: number;
156
+ crs: string;
157
+ retrievedAt?: string;
158
+ source?: {
159
+ name?: string;
160
+ provider?: string;
161
+ license?: string;
162
+ attribution?: string;
163
+ url?: string;
164
+ };
165
+ enclosures: SIGPACEnclosure[] | null;
166
+ }
120
167
  export interface CropReference {
121
168
  code: string;
122
169
  source: string;
@@ -425,6 +472,20 @@ export interface MarketData {
425
472
  dataQuality?: string;
426
473
  updatedAt?: string;
427
474
  zonePrices?: ZonePrices;
475
+ cropPrices?: CropLandPrice[];
476
+ priceNote?: string;
477
+ }
478
+ export interface CropLandPrice {
479
+ cropGroup: string;
480
+ cropGroupName?: string;
481
+ landUseCodes?: string[];
482
+ basis?: string;
483
+ areaHa?: number;
484
+ pricePerHaEur: number;
485
+ salesCount?: number;
486
+ level?: string;
487
+ zone?: string;
488
+ period?: string;
428
489
  }
429
490
  export interface OfficialZonePrice {
430
491
  pricePerM2Eur: number;
@@ -30,4 +30,5 @@ export const COUNTRY_CODES_TEXT = "ES Spain, PV Basque Country, NA Navarre, PT P
30
30
  "PL Poland, CZ Czechia, SK Slovakia, SI Slovenia, HR Croatia, BG Bulgaria, GR Greece, " +
31
31
  "CY Cyprus, DK Denmark, SE Sweden, NO Norway, FI Finland, IS Iceland, EE Estonia, " +
32
32
  "LV Latvia, LT Lithuania, IE Ireland, UK United Kingdom";
33
+ export const SIGPAC_COUNTRIES = ["ES", "PV", "NA"];
33
34
  //# sourceMappingURL=index.js.map
@@ -1,4 +1,4 @@
1
1
  export declare const SERVER_NAME = "catastro-gps-mcp";
2
- export declare const SERVER_VERSION = "2.1.0";
3
- export declare const USER_AGENT = "catastro-gps-mcp/2.1.0";
2
+ export declare const SERVER_VERSION = "2.2.0";
3
+ export declare const USER_AGENT = "catastro-gps-mcp/2.2.0";
4
4
  //# sourceMappingURL=version.d.ts.map
package/build/version.js CHANGED
@@ -1,4 +1,4 @@
1
1
  export const SERVER_NAME = "catastro-gps-mcp";
2
- export const SERVER_VERSION = "2.1.0";
2
+ export const SERVER_VERSION = "2.2.0";
3
3
  export const USER_AGENT = `${SERVER_NAME}/${SERVER_VERSION}`;
4
4
  //# sourceMappingURL=version.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "catastro-gps-mcp",
3
- "version": "2.1.0",
3
+ "version": "2.2.0",
4
4
  "mcpName": "com.parcelgps/catastro-gps",
5
5
  "description": "MCP server for cadastral parcels from 29 European countries (including the Basque Country and Navarre foral cadastres): reference, coordinates, address search in 27 countries, dwellings of Spanish buildings, geometry, terrain, climate, ground motion, solar, agriculture, market, score and comparison",
6
6
  "author": "The Hidden Panda <soporte@catastrogps.es>",
package/server.json CHANGED
@@ -24,13 +24,13 @@
24
24
  ]
25
25
  }
26
26
  ],
27
- "version": "2.1.0",
27
+ "version": "2.2.0",
28
28
  "packages": [
29
29
  {
30
30
  "registryType": "npm",
31
31
  "registryBaseUrl": "https://registry.npmjs.org",
32
32
  "identifier": "catastro-gps-mcp",
33
- "version": "2.1.0",
33
+ "version": "2.2.0",
34
34
  "transport": {
35
35
  "type": "stdio"
36
36
  },