Skip to main content
Glama

teryt_to_geometry

Retrieve a Polish administrative boundary by TERYT code and add it to the QGIS project as a layer. Supports wojewodztwo, powiat, and gmina levels.

Instructions

Fetch a Polish administrative unit's boundary by TERYT code and add it to the project as a layer.

level is one of "wojewodztwo", "powiat", "gmina". teryt_code must match that level's code format (e.g. gmina codes are 7 digits, zero-padded, like "1465011" for Warszawa) - use teryt_lookup to find the right code by name. The boundary is added as a new memory layer (EPSG:2180) unless target_layer_id is given, in which case it's appended to that existing layer instead. Only a summary is returned; inspect the result with get_layer_sample/features_get.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
levelYes
layer_nameNo
teryt_codeYes
target_layer_idNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

Discloses key behaviors: adds memory layer with EPSG:2180, conditional target_layer_id, and summary-only return. However, does not cover error handling or what happens with invalid TERYT codes.

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, front-loaded with the main purpose, and structured logically with details in subsequent sentences. No fluff or 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 4 parameters, no annotations, and an output schema (not shown), the description covers purpose, key parameters, behavioral details, and post-use inspection suggestions. Complete enough for correct usage.

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?

With 0% schema description coverage, the description adds significant meaning: level options, teryt_code format, target_layer_id customization, and layer_name existence. Minor gap in explaining layer_name precisely.

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 purpose: fetching a Polish administrative unit's boundary by TERYT code and adding it as a layer. It uses specific verb-resource pairs and distinguishes from sibling tools like teryt_lookup.

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?

Provides clear context on when to use, including level and code format, and suggests using teryt_lookup for code lookup. Explicitly explains target_layer_id behavior but does not discuss when not to use or alternative tools in detail.

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/piatkowski/qgis-mcp'

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