Skip to main content
Glama

list_documents

Read-onlyIdempotent

Lists document metadata in a jurisdiction (title, dates, source, classification) with filters and pagination. It does not return the document body, a citation bundle, or a source-file URL.

When to use: When you need to find or browse documents before reading them. Example: 'which Belgian employment statutes mention night work?' Use the returned uuid with a body or citation tool. When not: Do not use this for the body or the file. For plain text, use list_full_text (example: 'quote the operative wording'). For structured Markdown, use list_markdown (example: 'keep the article headings'). For a complete citation bundle — metadata, permanent legal link, citation template, body, and a temporary source-file URL — use evidence_pull (example: 'show me the source'). For only a temporary URL to the original file, use document_presigned_url (example: 'download the PDF'). Do not call without an iso from list_jurisdictions. Skip if you already have this document list for the same iso and filters.

Parameters: iso (required) is a jurisdiction code from list_jurisdictions (e.g. BE, or US_CA for a state). version, section_title, date_of_decision, file_data_only, issuing_authority, type_of_authority, source_identifier, source_secondary_identifier, tag are optional, section_title is a case-insensitive substring of the section title, date_of_decision is a date, file_data_only is a boolean, issuing_authority is a case-insensitive substring of the issuing authority, type_of_authority is a case-insensitive substring of the type of authority, source_identifier is a case-insensitive substring of the source identifier, source_secondary_identifier is a case-insensitive substring of the source secondary identifier, tag is a case-insensitive substring of the tag. With limit, next_id parameters to paginate the results. Empty data means the iso is outside the subscription, or no document matched.

Behavior: Read-only SELECT; does not create, update, or delete records, files, or credentials. The only effect is a database read. Auth: tools/call requires OAuth 2.0 or a Bearer token (401 if missing, invalid, revoked, or no active subscription). Rate limits: none at the MCP layer; safe to retry. Not cached; each call reads current subscription and document data. Documents with total_links of 0 are omitted.

Returns: A list of documents matching the filters, with pagination information.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "iso": "<iso>"
    },
    "name": "list_documents"
  }
}

Input Schema

NameRequiredDescriptionDefault
isoYesFilter by Jurisdiction ISO code (e.g. 'US')
tagNoFilter by portal tag
urlNoFilter by document URL
langNoExact portal language name, for example English. Filters the portal, not the document language.
uuidNoFilter by UUID. Leave blank to apply no UUID filter.
limitNoPage size. Default 20, maximum 100.
titleNoFilter by title
portalNoFilter by portal name
statusNoFilter by document status
next_idNodocument id of the first row of the next page, from pagination.next_id. Omit on the first page.
versionNoFilter by version
portal_idNoFilter by portal ID
is_repealedNoFilter by repealed documents. default value is false
last_updatedNoYYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter.
crawling_dateNoYYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter.
include_totalNoInclude total count in response
section_titleNoFilter by section title
effective_dateNoYYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter.
file_data_onlyNo(default value is false) returns all documents with file metadata and without file metadata. true returns only the documents with file metadata.
last_amendmentNoYYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter.
expiration_dateNoYYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter.
date_of_decisionNoYYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter.
publication_dateNoYYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter.
date_of_enactmentNoYYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter.
issuing_authorityNoFilter by issuing authority
source_identifierNoFilter by source identifier
type_of_authorityNoFilter by type of authority
issuing_authority_tagsNoFilter by issuing authority tags
source_secondary_identifierNoFilter by secondary source identifier

Output Schema

NameRequiredDescriptionDefault
dataYesDocuments in the requested jurisdiction that have crawled links; empty if none match.
messageYesResult message
paginationNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed30 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • changedInput schema / properties / crawling_date / description
      Previous value: -"Filter by crawling date"New value: +"YYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter."
    • changedInput schema / properties / date_of_decision / description
      Previous value: -"Filter by date of decision"New value: +"YYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter."
    • changedInput schema / properties / date_of_enactment / description
      Previous value: -"Filter by date of enactment"New value: +"YYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter."
    • removedInput schema / properties / document_id
      Removed value: -{
      -  "description": "Filter by document ID",
      -  "type": "string"
      -}
    • changedInput schema / properties / effective_date / description
      Previous value: -"Filter by effective date"New value: +"YYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter."
    • changedInput schema / properties / expiration_date / description
      Previous value: -"Filter by expiration date"New value: +"YYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter."
    • addedInput schema / properties / file_data_only / default
      Added value: +false
    • changedInput schema / properties / file_data_only / description
      Previous value: -"Return file data only"New value: +"(default value is false) returns all documents with file metadata and without file metadata. true returns only the documents with file metadata."
    • addedInput schema / properties / include_total
      Added value: +{
      +  "default": false,
      +  "description": "Include total count in response",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / is_repealed
      Added value: +{
      +  "default": false,
      +  "description": "Filter by repealed documents. default value is false",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / issuing_authority_tags
      Added value: +{
      +  "description": "Filter by issuing authority tags",
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • changedInput schema / properties / lang / description
      Previous value: -"Filter by language"New value: +"Exact portal language name, for example English. Filters the portal, not the document language."
    • changedInput schema / properties / last_amendment / description
      Previous value: -"Filter by last amendment date"New value: +"YYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter."
    • changedInput schema / properties / last_updated / description
      Previous value: -"Filter by last updated date"New value: +"YYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter."
    • changedInput schema / properties / limit / description
      Previous value: -"Number of results to return"New value: +"Page size. Default 20, maximum 100."
    • addedInput schema / properties / limit / maximum
      Added value: +100
    • addedInput schema / properties / limit / minimum
      Added value: +1
    • changedInput schema / properties / limit / type
      Previous value: -"number"New value: +"integer"
    • addedInput schema / properties / next_id
      Added value: +{
      +  "description": "document id of the first row of the next page, from pagination.next_id. Omit on the first page.",
      +  "type": "number"
      +}
    • removedInput schema / properties / offset
      Removed value: -{
      -  "description": "Number of results to skip",
      -  "type": "number"
      -}
    • addedInput schema / properties / portal_id
      Added value: +{
      +  "description": "Filter by portal ID",
      +  "type": "number"
      +}
    • changedInput schema / properties / publication_date / description
      Previous value: -"Filter by publication date"New value: +"YYYY-MM-DD, or a range YYYY-MM-DD-to-YYYY-MM-DD. Leave blank to apply no date filter."
    • removedInput schema / properties / repealed
      Removed value: -{
      -  "description": "Filter by repealed status",
      -  "type": "boolean"
      -}
    • changedInput schema / properties / status / description
      Previous value: -"Filter by status"New value: +"Filter by document status"
    • changedInput schema / properties / tag / description
      Previous value: -"Filter by tag"New value: +"Filter by portal tag"
    • changedInput schema / properties / url / description
      Previous value: -"Filter by URL"New value: +"Filter by document URL"
    • addedInput schema / properties / uuid
      Added value: +{
      +  "description": "Filter by UUID. Leave blank to apply no UUID filter.",
      +  "format": "uuid",
      +  "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
      +  "type": "string"
      +}
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "https://json-schema.org/draft/2020-12/schema",
      +  "additionalProperties": false,
      +  "properties": {
      +    "data": {
      +      "description": "Documents in the requested jurisdiction that have crawled links; empty if none match.",
      +      "items": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "classification": {
      +            "additionalProperties": false,
      +            "description": "Classification",
      +            "properties": {
      +              "authority_type": {
      +                "description": "Authority Type of the content",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "issuing_authority": {
      +                "description": "Issuing Authority of the content",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "issuing_authority_tags": {
      +                "anyOf": [
      +                  {
      +                    "items": {
      +                      "type": "string"
      +                    },
      +                    "type": "array"
      +                  },
      +                  {
      +                    "type": "null"
      +                  }
      +                ],
      +                "description": "Issuing Authority Tags of the content"
      +              },
      +              "keywords": {
      +                "description": "Keywords of the content",
      +                "items": {
      +                  "type": "string"
      +                },
      +                "type": "array"
      +              },
      +              "source_keywords": {
      +                "anyOf": [
      +                  {
      +                    "items": {
      +                      "type": "string"
      +                    },
      +                    "type": "array"
      +                  },
      +                  {
      +                    "type": "null"
      +                  }
      +                ],
      +                "description": "Source Keywords of the content"
      +              },
      +              "tags": {
      +                "anyOf": [
      +                  {
      +                    "items": {
      +                      "type": "string"
      +                    },
      +                    "type": "array"
      +                  },
      +                  {
      +                    "type": "null"
      +                  }
      +                ],
      +                "description": "Tags of the content"
      +              }
      +            },
      +            "required": [
      +              "authority_type",
      +              "issuing_authority",
      +              "issuing_authority_tags",
      +              "keywords",
      +              "tags",
      +              "source_keywords"
      +            ],
      +            "type": "object"
      +          },
      +          "content": {
      +            "additionalProperties": false,
      +            "description": "Content",
      +            "properties": {
      +              "file": {
      +                "anyOf": [
      +                  {
      +                    "additionalProperties": false,
      +                    "properties": {
      +                      "content_type": {
      +                        "description": "Content Type",
      +                        "type": [
      +                          "string",
      +                          "null"
      +                        ]
      +                      },
      +                      "size_bytes": {
      +                        "description": "Size in bytes",
      +                        "type": [
      +                          "number",
      +                          "null"
      +                        ]
      +                      },
      +                      "url": {
      +                        "description": "Source-file metadata, not a downloadable URL. Call document_presigned_url for a temporary source-file URL.",
      +                        "type": [
      +                          "string",
      +                          "null"
      +                        ]
      +                      }
      +                    },
      +                    "required": [
      +                      "content_type",
      +                      "size_bytes",
      +                      "url"
      +                    ],
      +                    "type": "object"
      +                  },
      +                  {
      +                    "type": "null"
      +                  }
      +                ],
      +                "description": "File metadata, or null when the document has no file. Not a citation bundle; call evidence_pull for that."
      +              },
      +              "markdown": {
      +                "description": "Path hint for the structured Markdown body. Call list_markdown to read it; this field is not the Markdown.",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "text": {
      +                "description": "Path hint for the plain-text body. Call list_full_text to read it; this field is not the text.",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              }
      +            },
      +            "required": [
      +              "text",
      +              "markdown",
      +              "file"
      +            ],
      +            "type": "object"
      +          },
      +          "dates": {
      +            "additionalProperties": false,
      +            "description": "Dates",
      +            "properties": {
      +              "decided": {
      +                "description": "Decision Date",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "effective": {
      +                "description": "Effective Date",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "enacted": {
      +                "description": "Date of Enactment",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "expired": {
      +                "description": "Expiration Date",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "last_amended": {
      +                "description": "Date of Last Amendment",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "published": {
      +                "description": "Publication Date",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "repealed": {
      +                "description": "Date of Repeal",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              }
      +            },
      +            "required": [
      +              "published",
      +              "enacted",
      +              "effective",
      +              "decided",
      +              "last_amended",
      +              "expired",
      +              "repealed"
      +            ],
      +            "type": "object"
      +          },
      +          "id": {
      +            "description": "ID",
      +            "type": [
      +              "number",
      +              "null"
      +            ]
      +          },
      +          "is_repealed": {
      +            "description": "Is Repealed",
      +            "type": [
      +              "boolean",
      +              "null"
      +            ]
      +          },
      +          "jurisdiction": {
      +            "additionalProperties": false,
      +            "description": "Jurisdiction",
      +            "properties": {
      +              "country": {
      +                "description": "Country",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "iso": {
      +                "description": "ISO code of the jurisdiction",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "state": {
      +                "description": "State",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              }
      +            },
      +            "required": [
      +              "iso",
      +              "country",
      +              "state"
      +            ],
      +            "type": "object"
      +          },
      +          "language": {
      +            "description": "Language",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "provenance": {
      +            "additionalProperties": false,
      +            "description": "Provenance",
      +            "properties": {
      +              "crawled_at": {
      +                "description": "Date and time the content was crawled",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "source_updated_at": {
      +                "description": "Date and time the source was updated",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              }
      +            },
      +            "required": [
      +              "crawled_at",
      +              "source_updated_at"
      +            ],
      +            "type": "object"
      +          },
      +          "section_title": {
      +            "description": "Section Title",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "source": {
      +            "additionalProperties": false,
      +            "description": "Source",
      +            "properties": {
      +              "domain": {
      +                "description": "Domain of the source",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "identifier": {
      +                "description": "Identifier of the source",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "portal_id": {
      +                "description": "Portal ID of the source",
      +                "type": [
      +                  "number",
      +                  "null"
      +                ]
      +              },
      +              "portal_name": {
      +                "description": "Portal Name of the source",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "portal_tags": {
      +                "anyOf": [
      +                  {
      +                    "items": {
      +                      "type": "string"
      +                    },
      +                    "type": "array"
      +                  },
      +                  {
      +                    "type": "null"
      +                  }
      +                ],
      +                "description": "Portal Tasks of the source"
      +              },
      +              "secondary_identifier": {
      +                "description": "Secondary Identifier of the source",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              },
      +              "url": {
      +                "description": "URL of the source",
      +                "type": [
      +                  "string",
      +                  "null"
      +                ]
      +              }
      +            },
      +            "required": [
      +              "portal_id",
      +              "portal_name",
      +              "portal_tags",
      +              "domain",
      +              "url",
      +              "identifier",
      +              "secondary_identifier"
      +            ],
      +            "type": "object"
      +          },
      +          "summary": {
      +            "description": "Summary",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "title": {
      +            "description": "Title",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "uuid": {
      +            "description": "UUID",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "version": {
      +            "description": "Version",
      +            "type": [
      +              "number",
      +              "null"
      +            ]
      +          }
      +        },
      +        "required": [
      +          "id",
      +          "uuid",
      +          "version",
      +          "title",
      +          "section_title",
      +          "language",
      +          "is_repealed",
      +          "summary",
      +          "jurisdiction",
      +          "source",
      +          "classification",
      +          "dates",
      +          "content",
      +          "provenance"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "message": {
      +      "description": "Result message",
      +      "type": "string"
      +    },
      +    "pagination": {
      +      "additionalProperties": false,
      +      "properties": {
      +        "limit": {
      +          "description": "Maximum number of documents returned",
      +          "type": "number"
      +        },
      +        "next_id": {
      +          "description": "Cursor ID for the next page, or null when there is no next page",
      +          "type": [
      +            "number",
      +            "null"
      +          ]
      +        },
      +        "total_count": {
      +          "description": "Total number of matching documents",
      +          "type": "number"
      +        }
      +      },
      +      "required": [
      +        "limit",
      +        "next_id"
      +      ],
      +      "type": "object"
      +    }
      +  },
      +  "required": [
      +    "message",
      +    "data"
      +  ],
      +  "type": "object"
      +}
  2. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and openWorldHint, so the safety profile is covered; the description nonetheless adds substantial context beyond that: auth requirements (OAuth 2.0 or Bearer token, 401 on missing/invalid/revoked/no subscription), no MCP-layer rate limits and safe retry, no caching, and the non-obvious filtering rule that documents with total_links of 0 are omitted. It also explains the ambiguous empty-result case (iso outside subscription vs. no match), which an agent cannot infer from 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?

Well front-loaded and organized with labeled sections (When to use / When not / Parameters / Behavior / Returns), so an agent can skim to the needed part. There is minor redundancy: the exclusion of body, citation bundle, and source-file URL is stated once in the opening sentence and again, at greater length, in the 'When not' block. The prose is dense but each labeled block carries distinct 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 29-parameter, read-only listing tool, the definition covers purpose, routing to siblings, prerequisites, auth, rate limits, caching, pagination via limit/next_id, the total_links=0 omission rule, and the meaning of an empty result. Return values need not be spelled out because an output schema exists, and the safety traits are carried by annotations, so nothing an agent needs in order to call this correctly is missing.

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%, so the baseline is 3; the description earns above that by adding matching semantics the schema does not state — that section_title, issuing_authority, type_of_authority, source_identifier, source_secondary_identifier, and tag are case-insensitive substring filters, that date_of_decision is a date, and that file_data_only is a boolean — plus the provenance constraint that iso must come from list_jurisdictions (e.g. BE, US_CA for a state). It stops short of 5 because it only covers a subset of the 29 parameters, leaving url, lang, uuid, portal, status, portal_id, include_total, and the date-range syntax undocumented in prose.

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 and resource ('Lists document metadata in a jurisdiction') and enumerates what the response contains (title, dates, source, classification). It immediately draws the boundary against siblings by declaring it does not return the body, a citation bundle, or a source-file URL, so an agent can separate it from list_full_text, list_markdown, evidence_pull, and document_presigned_url without opening a schema.

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?

Explicit 'When to use' with a concrete example query, an explicit 'When not' clause, and named alternatives each paired with an example intent ('quote the operative wording' → list_full_text, 'keep the article headings' → list_markdown, 'show me the source' → evidence_pull, 'download the PDF' → document_presigned_url). It also states a prerequisite (do not call without an iso from list_jurisdictions) and a skip condition (already have this list for the same iso and filters).

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.