Skip to main content
Glama

descargar_pdf

Downloads a CVE PDF or legacy Melilla portal URL to local cache and returns its path, size, SHA256, and page count. Reuses cached copies unless refresh is requested.

Instructions

Descarga el PDF de cualquier CVE (o, con url, uno del portal antiguo de melilla.es) a la caché local y devuelve su ruta, tamaño, sha256 y número de páginas.

Da exactamente uno: cve, o url (solo las URL https://www.melilla.es/mandar.php/... que devuelven buscar_bome_antiguo y ver_bome_antiguo). El nombre del fichero sale solo del CVE canónico o de la ruta de esa URL (melilla-9-4914-5302_73.pdf); el directorio lo fija BOME_NAVAJA_PDF_DIR (ver estado_servidor). Reutiliza la copia en caché salvo refrescar=true. Límite: 100 MB. Los PDF de 2014-2016 no existen en bomemelilla.es (404): búscalos en el portal antiguo.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cveNo
urlNo
refrescarNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.0.4

TDQS

A5/5.0
Behavior5/5

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

With no annotations, the description carries the full burden and covers the side effect (downloads to local cache), cache reuse unless refrescar=true, file naming from canonical CVE or URL path, directory from BOME_NAVAJA_PDF_DIR, the 100 MB limit, and the 404 behavior for 2014-2016. It even specifies the exact return tuple, so the agent knows what to expect.

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?

Every sentence carries load-bearing constraints: parameter exclusivity, URL allowlist, file naming, cache refresh, size limit, date gap, and return fields. The description is front-loaded with the main purpose and keeps details compact.

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?

Despite having no annotations and no output schema, the description supplies the return values explicitly and handles error-prone cases (2014-2016 404s, cache behavior, size limit). The only referenced external dependency, estado_servidor, is named so the agent can resolve it when needed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must add all meaning. It explains cve vs url, the exact URL restriction, the exactly-one requirement, and refrescar's effect on cache reuse. This fully compensates for the empty schema descriptions.

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?

Uses a specific verb ('Descarga') and resource ('PDF de cualquier CVE o, con url, uno del portal antiguo'), and states the return values (ruta, tamaño, sha256, número de páginas). This clearly distinguishes it from reading tools such as leer_pdf and from BOME listing tools.

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?

Explicitly says to provide exactly one of cve or url and restricts url to the melilla.es/mandar.php URLs emitted by buscar_bome_antiguo and ver_bome_antiguo. It also tells the agent that PDFs from 2014-2016 are 404 on bomemelilla.es and should be searched on the older portal, which is an explicit when-not/alternative.

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