Skip to main content
Glama

Describe sources

describe_sources
Read-only

Reads source metadata from a MapLibre style, lists available source layers and fields, and validates that every layer references existing ones. Use it before writing layers against unfamiliar data.

Instructions

Reads the metadata of every source in a MapLibre style (TileJSON, PMTiles headers and GeoJSON data) and lists the source layers and fields each one provides. Then checks that every layer uses a source, source layer and fields that exist. Use it before writing layers against data you do not know. inspect_tile shows the values the fields take, and debug_layers says what each layer draws at a place. Pass the style as an object, a URL or a file path.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNoURL of a style JSON document.
pathNoPath to a style JSON file, relative to the directory the server runs in.
styleNoThe style as a JSON object.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already indicate readOnlyHint=true, and the description consistently describes read-only actions ('Reads', 'checks'). It adds context beyond annotations by detailing the verification step and the input flexibility (object, URL, path). No contradiction with annotations.

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?

The description is about four sentences and contains no filler. It front-loads the core function, then usage guidance, alternatives, and input methods. It could be slightly tighter but each sentence contributes essential information.

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?

For a read-only inspection tool with no output schema, the description covers purpose, when to use, alternatives, and input methods. It implies the output (lists and checks) well enough for an agent to understand what to expect. No critical gaps.

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% with each parameter described, so baseline is 3. The description adds value by clarifying that the three parameters are alternative ways to pass the style ('as an object, a URL or a file path'), which is not explicitly stated 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 reads metadata of every source, lists source layers and fields, and checks layer-source consistency. It distinguishes itself from siblings by explicitly naming inspect_tile and debug_layers and explaining their different purposes.

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?

It explicitly says 'Use it before writing layers against data you do not know,' providing a clear when-to-use condition. It also mentions alternatives (inspect_tile, debug_layers) and what each does, enabling correct tool selection.

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