Skip to main content
Glama

Expat Living Italy

Where one nationality lives in Italy

get_nationality
Read-onlyIdempotent

For one tracked citizenship (ISO-2 code such as US, GB, DE): the comuni, provinces and regions where its holders concentrate, with counts and shares. It is CITIZENSHIP, not birthplace — foreign-born Italian citizens are not counted — and it carries small-number caveats: the comune ranking skips places under 1,000 residents by default and flags rows under 30 residents (smallNumber). A comune with no ISTAT row is left out, not counted as zero, so totals are floors. State those caveats when you quote a ranking; they are in the result's caveats. Province and comune lists are different levels of detail — say which.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ccYesISO-2 citizenship code of one of the citizenships this site tracks, e.g. "US".
limitNoHow many comuni and provinces to list, 1–50. Default 10.
rankByNoshare: residents with this citizenship as a fraction of the comune's population. count: absolute numbers.share
minPopulationNoSmallest comune, in residents, that may appear in the comune ranking. Default 1,000: in a village of sixty, four foreign residents is not a finding. Lowering it lets tiny places top the ranking.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
caveatsYesRead these before quoting a number; they travel with the data.
byRegionYes
topComuniYes
attributionYes
nationalityYes
topProvincesYesProvince grain: a different level of detail from the comuni above. Sums only the comuni ISTAT has a row for.
nationalTotalYesResidents with this citizenship in the comuni ISTAT reports on; `coverage` is how many comuni that is.
citizenshipNotBirthplaceYesEvery count here is by CITIZENSHIP, not country of birth: it leaves out foreign-born people who hold Italian citizenship.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / cc / description
      Previous value: -"ISO-2 citizenship code of one of the 25 citizenships this site tracks, e.g. \"US\"."New value: +"ISO-2 citizenship code of one of the citizenships this site tracks, e.g. \"US\"."
  2. Changed1 schema field changed
    • changedOutput schema / properties / topComuni / properties / value / anyOf
      Previous value: -[
      -  {
      -    "items": {
      -      "additionalProperties": false,
      -      "properties": {
      -        "count": {
      -          "maximum": 9007199254740991,
      -          "minimum": -9007199254740991,
      -          "type": "integer"
      -        },
      -        "istatCode": {
      -          "type": "string"
      -        },
      -        "name": {
      -          "type": "string"
      -        },
      -        "page": {
      -          "type": "string"
      -        },
      -        "population": {
      -          "maximum": 9007199254740991,
      -          "minimum": -9007199254740991,
      -          "type": "integer"
      -        },
      -        "province": {
      -          "type": "string"
      -        },
      -        "provinceCode": {
      -          "type": "string"
      -        },
      -        "rank": {
      -          "maximum": 9007199254740991,
      -          "minimum": -9007199254740991,
      -          "type": "integer"
      -        },
      -        "region": {
      -          "type": "string"
      -        },
      -        "shareOfPopulation": {
      -          "description": "A fraction, 0–1.",
      -          "type": "number"
      -        },
      -        "smallNumber": {
      -          "description": "True when fewer than 50 residents hold this citizenship here: the share rests on a handful of households.",
      -          "type": "boolean"
      -        }
      -      },
      -      "required": [
      -        "rank",
      -        "istatCode",
      -        "name",
      -        "province",
      -        "provinceCode",
      -        "region",
      -        "population",
      -        "count",
      -        "shareOfPopulation",
      -        "smallNumber",
      -        "page"
      -      ],
      -      "type": "object"
      -    },
      -    "maxItems": 50,
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "items": {
      +      "additionalProperties": false,
      +      "properties": {
      +        "count": {
      +          "maximum": 9007199254740991,
      +          "minimum": -9007199254740991,
      +          "type": "integer"
      +        },
      +        "istatCode": {
      +          "type": "string"
      +        },
      +        "name": {
      +          "type": "string"
      +        },
      +        "page": {
      +          "type": "string"
      +        },
      +        "population": {
      +          "maximum": 9007199254740991,
      +          "minimum": -9007199254740991,
      +          "type": "integer"
      +        },
      +        "province": {
      +          "type": "string"
      +        },
      +        "provinceCode": {
      +          "type": "string"
      +        },
      +        "rank": {
      +          "maximum": 9007199254740991,
      +          "minimum": -9007199254740991,
      +          "type": "integer"
      +        },
      +        "region": {
      +          "type": "string"
      +        },
      +        "shareOfPopulation": {
      +          "description": "A fraction, 0–1.",
      +          "type": "number"
      +        },
      +        "smallNumber": {
      +          "description": "True when fewer than 30 residents hold this citizenship here: the share rests on a handful of households.",
      +          "type": "boolean"
      +        }
      +      },
      +      "required": [
      +        "rank",
      +        "istatCode",
      +        "name",
      +        "province",
      +        "provinceCode",
      +        "region",
      +        "population",
      +        "count",
      +        "shareOfPopulation",
      +        "smallNumber",
      +        "page"
      +      ],
      +      "type": "object"
      +    },
      +    "maxItems": 50,
      +    "type": "array"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
  3. Added

TDQS

A4.6/5.0
Behavior5/5

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

Annotations only declare read-only/idempotent/closed-world; the description adds substantial non-obvious behavior: comuni under 1,000 residents are skipped by default, rows under 30 residents are flagged via `smallNumber`, and comuni without an ISTAT row are omitted so totals are floors, not zeros. This is exactly the data-quality disclosure an agent needs to interpret results honestly.

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-loads the core definition and keeps every sentence information-bearing. It is dense and a couple of long clauses stack multiple ideas, but there is no redundant filler.

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

Completeness5/5

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

With an output schema present, return-value explanation is unnecessary, and the description covers the remaining burden: caveat propagation, level-of-detail distinction, and the small-number/floors semantics. An agent can call this correctly and report results responsibly.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3. The description adds reasoning beyond the schema — explaining why minPopulation defaults to 1,000 and that lowering it lets tiny places top the ranking, and tying the `smallNumber` flag to the ranking logic — which meaningfully clarifies parameter effects.

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?

States a specific verb+resource (nationality concentration across comuni/provinces/regions) and pins the key semantic: tracked citizenship by ISO-2 code, with counts and shares. The 'CITIZENSHIP, not birthplace' clarification sharply distinguishes it from the general geographic siblings like get_comune and find_comuni.

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

Usage Guidelines4/5

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

Gives clear operational context — state the small-number caveats when quoting a ranking, and say whether province or comune level is being cited. However it never names an alternative tool or states when to prefer this over a sibling, so routing guidance is implied rather than explicit.

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