Skip to main content
Glama

Search Legislation

search_legislation

Searches Spain’s national legislation via official BOE sources, including statutes, acts, codes, regulations, and the official gazette; filter by keywords, title/number, year, or result limit.

Instructions

Search Spain (ES) national legislation (statutes, acts, codes, regulations, official gazette) via BOE Datos Abiertos REST API (boe.es/datosabiertos) and live national legal archives.

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": {
      "query": "<query>"
    },
    "name": "search_legislation"
  }
}

Input Schema

NameRequiredDescriptionDefault
yearNoOptional enactment year filter.
limitNoMaximum number of results to return.
queryYesKeywords or statute title/number to search in Spain legislation.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

A3.5/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the burden. It does add real behavioral context by naming the upstream data source and the fact that results come from live national archives, but it says nothing about result ranking, whether the two sources are merged or deduplicated, freshness/coverage limits, or error behavior.

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?

A single front-loaded sentence identifying the action, jurisdiction, content scope, and data source, with no redundant or filler wording.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists and all three parameters are documented, so the floor is met. For a multi-source live legal search, however, the definition leaves ranking, source-merging, and result-completeness behavior unexplained, which an agent would want before relying on results.

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%, so query, year, and limit are already fully documented with defaults and bounds. The description adds no syntax or semantics beyond that — no guidance on how keywords are matched or how year interacts with statute numbering.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Names a specific verb+resource: search Spain national legislation, with an enumeration of covered content types (statutes, acts, codes, regulations, official gazette) and the source (BOE Datos Abiertos). An agent can tell this is for legislation rather than case law, though it never explicitly contrasts itself with the sibling search_case_law.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied: the resource enumeration signals 'use this for statutes/codes, not court decisions,' but there is no explicit when-to-use/when-not guidance and no named alternative for the adjacent tasks (case law, citations, document retrieval).

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