Skip to main content
Glama

List example corpus files

list_corpus_files
Read-onlyIdempotent

Browse validated ISO 20022 example files, including market scenarios by country and rail plus coverage sets, to find a suitable file before fetching its contents or provenance.

Instructions

List the example files pain001 ships: market scenarios and coverage sets.

Use this to discover what ready-made, validated ISO 20022 files exist
before calling ``get_corpus_file`` or ``get_corpus_provenance``. Market
files are realistic payments per country and rail (``scenario_id``
like ``gb.chaps.property-purchase``); a ``variant`` names the bank
overlay a file was built with. Coverage files exercise every element
and choice branch of one message type and carry no scenario.

Delegates to :func:`pain001.corpus.list_files`.

Args:
    kind: ``market``, ``coverage`` or ``None`` for both.
    country: Optional two-letter country filter for market files.
    version: Optional message-type filter.

Returns:
    ``{"count", "files": [{"kind", "scenario_id", "version", "country",
    "family", "variant", "file"}, ...]}``, or ``{"error": ...}`` when
    the installed pain001 has no corpus.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
kindNo'market' for the realistic per-country scenarios, 'coverage' for the schema coverage sets, or omit for both.
countryNoTwo-letter country code to keep one market pack only, e.g. 'GB' or 'CH'. Ignored for coverage files.
versionNoKeep only files of this message type, e.g. 'pain.001.001.09'.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.0.67

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive/openWorld=false, so the safety profile is covered. The description goes beyond them by disclosing the empty-corpus failure mode ('{"error": ...} when the installed pain001 has no corpus') and by explaining the structural meaning of scenario_id and variant, which annotations cannot convey.

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?

Front-loaded with the purpose and the use-before rule, then organized into Args/Returns blocks. Some material (the scenario_id example, the variant explanation) is dense, but every part maps to a decision the caller makes; nothing is filler.

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?

There is no output schema, so the description carries the return-value burden and does so by spelling out the exact JSON shape including the flat file records and the error case. Combined with the file-family semantics and argument guidance, an agent has everything needed to call and interpret this tool.

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 description coverage is 100%, so the parameter dictionary is already documented, making 3 the baseline. The description adds genuine semantic texture on top: what 'variant' means (bank overlay a file was built with), how coverage files differ from market files, and a concrete scenario_id example, which helps interpret the returned values.

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+resource ('List the example files pain001 ships') and immediately scopes it to two file families, market scenarios and coverage sets. It also names the sibling tools it precedes (get_corpus_file, get_corpus_provenance), so an agent can position it in the workflow without opening another schema.

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?

Explicitly says when to use it ('to discover what ready-made, validated ISO 20022 files exist before calling get_corpus_file or get_corpus_provenance'), which is a clear use-before condition. It differentiates market vs coverage files so the caller knows which result it wants, but it does not state when the tool is unnecessary (e.g. if you already have a scenario_id).

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