Skip to main content
Glama

map_zoom_to_selection

Zoom the map canvas to the selected features of a vector layer. Fails if no features are selected.

Instructions

Zoom the map canvas to the selected features of a vector layer.

Fails with EmptySelection if the layer currently has no selected features.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
layer_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

No annotations are provided, so the description must disclose behavior. It mentions the failure case 'Fails with EmptySelection if the layer currently has no selected features', which is useful. However, it does not discuss other effects like map state changes or permissions, though zoom actions are generally harmless.

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 two sentences, front-loaded with the action, and contains no extraneous words. Every sentence earns its place.

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?

Given the tool's simplicity (1 parameter, output schema exists), the description is adequate. It covers the core action and the primary error case. Minor gap: no mention of what the output contains (e.g., success confirmation).

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?

With 0% schema description coverage, the description should explain parameter meaning. It mentions 'vector layer' but does not explicitly define layer_id. The context is somewhat implied, but the description adds minimal value beyond 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 verb 'zoom' and the resource 'map canvas to the selected features of a vector layer'. It distinguishes from sibling tools like map_zoom_to_layer or map_zoom_full by specifying the focus on selected features.

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?

The description implies usage when you have a vector layer with selected features and want to zoom to them. However, it does not explicitly contrast with alternatives (e.g., map_zoom_to_layer for full layer extent) or provide when-not guidance.

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