Skip to main content
Glama

DatiTuristici.it

Read tourism figures of an Italian comune

leggi_dati_comune
Read-onlyIdempotent

Reads the tourism figures of one Italian municipality (comune) in one year: nights spent (presenze), arrivals, bed places, accommodation establishments and resident population. Use it when you have the 6-digit cod_istat from cerca_comune; do not use it to look a place up by name (use cerca_comune instead), to follow a comune over the years (use leggi_serie_comune instead) or to put comuni side by side (use confronta_comuni instead). Presenze are nights, not people (one guest staying three nights counts three); anno defaults to the latest year with data, and capacity figures are for anno_capacita: the latest year published, as on the comune's page, or the latest up to anno when anno is given; profilo adds the comune's altitude, surface, coordinates, UNESCO sites and tourism pressure, each group with its own year. Missing figures are null and nota says why (also from 2025, when the counts changed scope, and when profilo is null), and a year outside anni_disponibili or an unknown code returns an error that says what to pass. Read-only, public, no authentication; 30 requests per minute per client, shared across tools.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "cod_istat": "<cod_istat>"
    },
    "name": "leggi_dati_comune"
  }
}

Input Schema

NameRequiredDescriptionDefault
annoNoYear of the figures, e.g. 2024; default: the latest year with data for this comune. A year outside its years with data returns an error that gives them.
cod_istatYes6-digit ISTAT code of the comune as a string, leading zeros kept ("058091" is Roma); it comes from cerca_comune.

Output Schema

NameRequiredDescriptionDefault
annoNoYear of the movement figures (presenze and arrivi): `anno_richiesto`, or the latest year with data when it was omitted; null if the comune has no tourism data.
nomeYesOfficial name of the comune.
notaNoNotes in English on reading the figures, null when there is nothing to say: from 2025 ISTAT counts include privately rented holiday flats, so totals and non-hotel figures are not comparable with years before 2025 (hotel figures are); capacity from a year other than `anno`; a year or a comune without movement figures; a comune without a `profilo`.
fonteYesSource to cite with the figures: processed by DatiTuristici.it from institutional data (ISTAT).
schedaYesLink to the comune's public page on datituristici.it, to cite.
profiloNoThe comune's territorial profile, the free Territorial profile section of its page, without the two seasonal indices shown on the site: altitude, surface, coordinates, UNESCO World Heritage sites and two tourism-pressure ratios, with the year of each group in `anni` and its own `fonte`. Null when no profile is recorded for the comune or this server does not serve it; `nota` then says which.
regioneNoRegion as recorded by ISTAT (Bolzano and Trento are provinces of TRENTINO-ALTO ADIGE); null if not recorded.
eserciziNoNumber of accommodation establishments in `anno_capacita`; null if not available.
cod_istatYes6-digit ISTAT code of the comune, as a string with leading zeros kept.
provinciaNoProvince (or metropolitan city) as recorded by ISTAT; null if not recorded.
popolazioneNoResident population in `popolazione_anno` (the latest year loaded, whatever `anno` is); null if not available.
posti_lettoNoBed places in accommodation establishments in `anno_capacita`: the ISTAT total, or hotel plus non-hotel beds where the total is missing, as on the site; null if not available.
anno_capacitaNoYear of the capacity figures (bed places and establishments): with `anno`, the latest year published up to it; without, the latest year published, as on the comune's page. It can be earlier or later than `anno`, and `nota` then gives both years; null if none is published.
arrivi_totaliNoGuest arrivals (check-ins) at accommodation establishments during `anno`; null if not available.
anno_richiestoNoThe `anno` argument as given; null when it was omitted.
arrivi_italianiNoArrivals of guests resident in Italy during `anno`; null if not available.
presenze_totaliNoNights spent by all guests in accommodation establishments during `anno` (one guest staying three nights counts three); null if not available.
anni_disponibiliNoFirst and last year with movement figures for this comune, the accepted range of `anno`; null if the comune has none.
arrivi_stranieriNoArrivals of guests resident abroad during `anno`; null if not available.
popolazione_annoNoReference year of `popolazione`; null if not available.
presenze_italianiNoNights spent by guests resident in Italy during `anno`; null if not available.
presenze_stranieriNoNights spent by guests resident abroad during `anno`; null if not available.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / properties / profilo / description
      Previous value: -"The comune's territorial profile, the same data as the Territorial profile section of its page: altitude, surface, coordinates, UNESCO World Heritage sites and two tourism-pressure ratios, with the year of each group in `anni` and its own `fonte`. Null when no profile is recorded for the comune or this server does not serve it; `nota` then says which."New value: +"The comune's territorial profile, the free Territorial profile section of its page, without the two seasonal indices shown on the site: altitude, surface, coordinates, UNESCO World Heritage sites and two tourism-pressure ratios, with the year of each group in `anni` and its own `fonte`. Null when no profile is recorded for the comune or this server does not serve it; `nota` then says which."
  2. Changed7 schema fields changed
    • addedOutput schema / properties / profilo / properties / anni / properties / arrivi
      Added value: +{
      +  "description": "Reference year of the arrivals used in `arrivi_per_abitante`: the latest year with movement figures; null if that group is not available.",
      +  "type": [
      +    "integer",
      +    "null"
      +  ]
      +}
    • changedOutput schema / properties / profilo / properties / anni / properties / popolazione / description
      Previous value: -"Reference year of the resident population used in `presenze_per_abitante`: the year closest to `anni.presenze`, which can differ from it; null if that group is not available."New value: +"Reference year of the resident population used in `arrivi_per_abitante`: the year closest to `anni.arrivi`, which can differ from it; null if that group is not available."
    • removedOutput schema / properties / profilo / properties / anni / properties / presenze
      Removed value: -{
      -  "description": "Reference year of the nights spent used in `presenze_per_abitante`: the latest year with movement figures; null if that group is not available.",
      -  "type": [
      -    "integer",
      -    "null"
      -  ]
      -}
    • changedOutput schema / properties / profilo / properties / anni / required
      Previous value: -[
      -  "classificazioni",
      -  "presenze",
      -  "popolazione",
      -  "posti_letto",
      -  "wikidata"
      -]New value: +[
      +  "classificazioni",
      +  "arrivi",
      +  "popolazione",
      +  "posti_letto",
      +  "wikidata"
      +]
    • addedOutput schema / properties / profilo / properties / arrivi_per_abitante
      Added value: +{
      +  "description": "Tourism pressure: arrivals in the latest year with movement figures (`anni.arrivi`) per resident (population of `anni.popolazione`), rounded to two decimals; null if a term is missing. Arrivals are guests checked in, not nights.",
      +  "type": [
      +    "number",
      +    "null"
      +  ]
      +}
    • removedOutput schema / properties / profilo / properties / presenze_per_abitante
      Removed value: -{
      -  "description": "Tourism pressure: nights spent in the latest year with movement figures (`anni.presenze`) per resident (population of `anni.popolazione`), rounded to two decimals; null if a term is missing. Nights are not people.",
      -  "type": [
      -    "number",
      -    "null"
      -  ]
      -}
    • changedOutput schema / properties / profilo / required
      Previous value: -[
      -  "zona_altimetrica",
      -  "altitudine_m",
      -  "litoraneo",
      -  "isolano",
      -  "montano",
      -  "grado_urbanizzazione",
      -  "superficie_kmq",
      -  "presenze_per_abitante",
      -  "posti_letto_per_kmq",
      -  "lat",
      -  "lon",
      -  "siti_unesco",
      -  "anni",
      -  "fonte"
      -]New value: +[
      +  "zona_altimetrica",
      +  "altitudine_m",
      +  "litoraneo",
      +  "isolano",
      +  "montano",
      +  "grado_urbanizzazione",
      +  "superficie_kmq",
      +  "arrivi_per_abitante",
      +  "posti_letto_per_kmq",
      +  "lat",
      +  "lon",
      +  "siti_unesco",
      +  "anni",
      +  "fonte"
      +]
  3. Changed2 schema fields changed
    • changedOutput schema / properties / nota / description
      Previous value: -"Notes in English on reading the figures, null when there is nothing to say: from 2025 ISTAT counts include privately rented holiday flats, so totals and non-hotel figures are not comparable with years before 2025 (hotel figures are); capacity from a year other than `anno`; a year or a comune without movement figures."New value: +"Notes in English on reading the figures, null when there is nothing to say: from 2025 ISTAT counts include privately rented holiday flats, so totals and non-hotel figures are not comparable with years before 2025 (hotel figures are); capacity from a year other than `anno`; a year or a comune without movement figures; a comune without a `profilo`."
    • addedOutput schema / properties / profilo
      Added value: +{
      +  "description": "The comune's territorial profile, the same data as the Territorial profile section of its page: altitude, surface, coordinates, UNESCO World Heritage sites and two tourism-pressure ratios, with the year of each group in `anni` and its own `fonte`. Null when no profile is recorded for the comune or this server does not serve it; `nota` then says which.",
      +  "properties": {
      +    "altitudine_m": {
      +      "description": "Altitude of the comune's centre in metres above sea level (ISTAT); null if not available.",
      +      "type": [
      +        "integer",
      +        "null"
      +      ]
      +    },
      +    "anni": {
      +      "description": "The reference year of each group of the profile, only of what was used; null where the group is not available.",
      +      "properties": {
      +        "classificazioni": {
      +          "description": "Reference year of the ISTAT group (`altitudine_m`, `superficie_kmq` and the classifications): the year the file refers to; null if that group is not available.",
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "popolazione": {
      +          "description": "Reference year of the resident population used in `presenze_per_abitante`: the year closest to `anni.presenze`, which can differ from it; null if that group is not available.",
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "posti_letto": {
      +          "description": "Reference year of the bed places used in `posti_letto_per_kmq`: the latest year of the accommodation establishments; null if that group is not available.",
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "presenze": {
      +          "description": "Reference year of the nights spent used in `presenze_per_abitante`: the latest year with movement figures; null if that group is not available.",
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "wikidata": {
      +          "description": "Reference year of the Wikidata group (`lat`, `lon`, `siti_unesco`): the year read; null if that group is not available.",
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        }
      +      },
      +      "required": [
      +        "classificazioni",
      +        "presenze",
      +        "popolazione",
      +        "posti_letto",
      +        "wikidata"
      +      ],
      +      "type": "object"
      +    },
      +    "fonte": {
      +      "description": "Sources to cite with the profile: processed by DatiTuristici.it from institutional data (ISTAT) and Wikidata (CC0).",
      +      "type": "string"
      +    },
      +    "grado_urbanizzazione": {
      +      "description": "Degree of urbanisation (ISTAT): 1 city, 2 towns and suburbs, 3 rural areas; null if not available.",
      +      "type": [
      +        "integer",
      +        "null"
      +      ]
      +    },
      +    "isolano": {
      +      "description": "True if the comune is on an island, false if not (ISTAT); null if not available.",
      +      "type": [
      +        "boolean",
      +        "null"
      +      ]
      +    },
      +    "lat": {
      +      "description": "Latitude of the comune in degrees (Wikidata, WGS 84); null if not available, including the few comuni with two different points, none of which is chosen.",
      +      "type": [
      +        "number",
      +        "null"
      +      ]
      +    },
      +    "litoraneo": {
      +      "description": "True if the comune is on the coast, false if not (ISTAT); null if not available.",
      +      "type": [
      +        "boolean",
      +        "null"
      +      ]
      +    },
      +    "lon": {
      +      "description": "Longitude of the comune in degrees (Wikidata, WGS 84); null when `lat` is null.",
      +      "type": [
      +        "number",
      +        "null"
      +      ]
      +    },
      +    "montano": {
      +      "description": "Mountain classification of the comune (ISTAT): T entirely mountain, P partly mountain, NM not mountain; null if not available.",
      +      "enum": [
      +        "T",
      +        "P",
      +        "NM",
      +        null
      +      ],
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "posti_letto_per_kmq": {
      +      "description": "Bed places in the latest year of the accommodation establishments (`anni.posti_letto`) per square kilometre of `superficie_kmq`, rounded to two decimals; null if a term is missing.",
      +      "type": [
      +        "number",
      +        "null"
      +      ]
      +    },
      +    "presenze_per_abitante": {
      +      "description": "Tourism pressure: nights spent in the latest year with movement figures (`anni.presenze`) per resident (population of `anni.popolazione`), rounded to two decimals; null if a term is missing. Nights are not people.",
      +      "type": [
      +        "number",
      +        "null"
      +      ]
      +    },
      +    "siti_unesco": {
      +      "description": "Number of UNESCO World Heritage sites located in the comune (Wikidata), a count taken from Wikidata as it is; 0 if none; null if the comune is not in Wikidata.",
      +      "type": [
      +        "integer",
      +        "null"
      +      ]
      +    },
      +    "superficie_kmq": {
      +      "description": "Surface area of the comune in square kilometres (ISTAT); null if not available.",
      +      "type": [
      +        "number",
      +        "null"
      +      ]
      +    },
      +    "zona_altimetrica": {
      +      "description": "Altimetric zone of the comune (ISTAT): 1 inland mountain, 2 coastal mountain, 3 inland hill, 4 coastal hill, 5 plain; null if not available.",
      +      "type": [
      +        "integer",
      +        "null"
      +      ]
      +    }
      +  },
      +  "required": [
      +    "zona_altimetrica",
      +    "altitudine_m",
      +    "litoraneo",
      +    "isolano",
      +    "montano",
      +    "grado_urbanizzazione",
      +    "superficie_kmq",
      +    "presenze_per_abitante",
      +    "posti_letto_per_kmq",
      +    "lat",
      +    "lon",
      +    "siti_unesco",
      +    "anni",
      +    "fonte"
      +  ],
      +  "type": [
      +    "object",
      +    "null"
      +  ]
      +}
  4. First observed

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well past the annotations: read-only, public, no authentication, 30 requests per minute per client shared across tools, missing values returned as null with a `nota` explaining why (including the 2025 scope change), and errors that state what to pass when the year or code is invalid. It also flags the semantics trap that presenze are nights, not people. None of this is derivable from readOnlyHint/idempotentHint alone.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with purpose, then routing, then behavior — the right order for an agent scanning it. It is a single dense paragraph with several semicolon-chained clauses, and the `profilo`/`anno_capacita` passage is the least parseable part and refers to a parameter the schema lacks.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return value structure need not be explained, and the description still covers nulls and the `nota` field, error behavior, defaults and rate limits — ample for a 2-parameter read tool. The gap is the undocumented-in-schema `profilo` parameter and the unexplained capacity-year interaction, which leave an agent guessing about a capability that isn't actually exposed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, so the baseline is 3; the description does add real meaning for `anno` (defaults to latest year with data, errors otherwise) and confirms `cod_istat` comes from cerca_comune. However, it describes a `profilo` parameter that does not exist in the schema (only `anno` and `cod_istat` are defined, with additionalProperties: false), which could lead an agent to pass a parameter that will be rejected.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb and resource — 'Reads the tourism figures of one Italian municipality (comune) in one year' — and enumerates the exact measures returned (presenze, arrivals, bed places, establishments, resident population). The scope (one comune, one year) is stated up front, which immediately separates it from the list, series and comparison siblings.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states the precondition ('when you have the 6-digit cod_istat from cerca_comune') and then names three exclusions with the tool to use instead: cerca_comune for name lookup, leggi_serie_comune for multi-year, confronta_comuni for side-by-side. This is the when/when-not/alternative pattern at full strength.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources