Skip to main content
Glama

List mapping rules

layerz_list_mappings
Read-only

Lists the import classification rules in scope for a model: sets (each with a scope: model = the model's own rules, system_template = the curated country catalogs (PCG, US GAAP, UK, SKR03/04), user_template = the caller's reusable catalogs), mappings (the effective rules: pattern → target item, sign, source scope) and templates (the catalogs importable through layerz_manage_mapping { op: "import_template" }). A model classifies with its own model rules only; a catalog applies once imported. A pattern is a case-insensitive glob where * matches anywhere. include_user_mappings: true adds the account-wide catalogs to sets / mappings; include_coverage: true adds per-rule match_count and a coverage block (auto-created count, ignored count, the top keys routing nowhere).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
model_idNoTarget model UUID. Required for user-scoped API keys; validated against the bound model for model-scoped keys.
include_coverageNoAlso compute `match_count` per rule and a `coverage` block (classifies every source: heavier read).
include_user_mappingsNoAlso list the account-wide user catalogs in `sets` / `mappings` (default: only what the model classifies with).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / properties / include_coverage / description
      Previous value: -"Also compute, per rule, `match_count` (staged rows it captures) and a `coverage` block (auto-created count + top unrouted keys). Off by default — it classifies every source, so it is a heavier read."New value: +"Also compute `match_count` per rule and a `coverage` block (classifies every source: heavier read)."
    • changedInput schema / properties / include_user_mappings / description
      Previous value: -"Also surface your account-wide (model-independent) user catalogs in `sets`/`mappings` for discovery. Default false: only what this model actually classifies with (system + this-model rules)."New value: +"Also list the account-wide user catalogs in `sets` / `mappings` (default: only what the model classifies with)."
    • changedInput schema / properties / model_id / description
      Previous value: -"Target model UUID. Required for user-scoped API keys; ignored (or validated against scope) for model-scoped keys."New value: +"Target model UUID. Required for user-scoped API keys; validated against the bound model for model-scoped keys."
  2. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, so the safety profile is covered; the description adds the behavioral cost disclosure that `include_coverage` is a heavier read. It also explains the semantics of the returned sets (which rules are actually effective) and glob matching, though it says nothing about ordering or result size limits.

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?

Purpose is front-loaded in the first clause, and the parenthetical breakdowns of `scope` values and flag effects are informative rather than filler. It is a single dense block, however, and the backtick-heavy detail makes it heavier than a list tool strictly needs.

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 no output schema, the description must carry the return-shape burden, and it does: it names the collections to expect and their contents, explains `scope` semantics, glob matching rules, and what the optional coverage block contains. Nothing essential for calling or interpreting this read tool is missing.

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?

Schema description coverage is 100%, and the tool has only 3 optional params, so the baseline is 3. The description's flag explanations largely restate the schema descriptions (account-wide catalogs, coverage match counts) rather than adding new syntax or constraints beyond them.

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 (lists) and resource (import classification rules in scope for a model), then enumerates the three returned collections (`sets`, `mappings`, `templates`) with what each contains. It also distinguishes itself from `layerz_manage_mapping` by naming the import_template op that acts on catalogs, so an agent can separate listing from mutation.

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?

Explains the conditions under which each flag matters (`include_user_mappings: true` widens to account-wide catalogs; `include_coverage: true` adds per-rule counts and a coverage block) and clarifies that a model classifies only with its own `model` rules until a catalog is imported. It doesn't explicitly state when-not-to-use or name a read alternative like `layerz_list_templates`, so it falls short of full routing guidance.

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