Skip to main content
Glama
cturkieh

France Data MCP

get_commune_by_code

Read-onlyIdempotent

Look up a French commune using its 5-character INSEE code. Returns detailed data if found, or directs to autocomplete for disambiguation.

Instructions

Récupère une commune par son code INSEE. Retourne un objet LookupResult discriminé par found. found: true → champs commune à plat (nom, codesPostaux, centre…). found: false{ found: false, key, lookupStatus: 'not_found', message } orientant vers autocomplete_commune pour disambiguer.

Alias acceptés : code_insee/codeInsee/inseecode.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYesCode INSEE 5 caractères. Ex: "75056" Paris, "59009" Villeneuve-d'Ascq, "2A004" Ajaccio.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
foundYes
lookupStatusYes
keyNoClé recherchée (SIREN, num_finess, code INSEE, …).
messageNoExplication actionnable quand `found=false` (cause probable + remédiation).
Behavior5/5

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

The description reveals the return structure (LookupResult discriminated by 'found') and the shape in both found and not found cases, adding behavioral detail beyond what annotations provide. No contradiction with annotations (readOnlyHint=true, etc.).

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

Conciseness5/5

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

The description is concise and well-structured. The first sentence states the core purpose, then the return behaviour, and a separate line for parameter aliases. Every sentence earns its place without redundancy.

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?

Given the tool's simplicity (one parameter, strong annotations, output schema), the description covers all necessary aspects: purpose, return structure, not-found handling, parameter semantics, and alternative tool suggestion. It is fully complete.

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

Parameters5/5

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

The description adds significant value beyond the input schema by documenting accepted aliases ('code_insee', 'codeInsee', 'insee') for the 'code' parameter. This is crucial information not present in the schema.

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?

The description clearly states the tool's action ('Récupère une commune par son code INSEE') and resource (commune). It distinguishes from siblings by referencing 'autocomplete_commune' for disambiguation in case of not found, providing clear differentiation.

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?

The description explicitly tells when to use the tool (to get a commune by INSEE code) and provides guidance on what to do if the commune is not found, directing to 'autocomplete_commune'. It also mentions accepted aliases for the parameter, aiding correct invocation.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cturkieh/france-data-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server