spij-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@spij-mcpbusca normas sobre protección de datos personales en Perú"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
spij-mcp

Servidor MCP local para buscar y leer el SPIJ — Sistema Peruano de Información Jurídica (normas legales, resoluciones, jurisprudencia del Tribunal Constitucional y más) — desde tu harness MCP.
Herramienta no oficial: sin afiliación con MINJUS ni con el SPIJ.
Aspecto | Detalle |
Fuente de datos | spij.minjus.gob.pe (público) |
Autenticación | Implícita: usa la misma sesión pública del sitio web y se renueva sola (JWT de 24 h) |
Almacenamiento | Ninguno — el servidor nunca guarda archivos; devuelve contenido limpio |
Transporte | stdio (Claude Desktop, Claude Code, agentes compatibles con MCP) |
Instalación
Opción A — Un click (sin terminal)
Descarga
spij-mcp-0.6.1.mcpbdesde Releases.Abre Claude Desktop → Ajustes → Extensiones → Instalar desde archivo.
Selecciona el
.mcpby listo.
Requisito: Python 3.10+ instalado en el sistema (el
.mcpbtrae el código; las dependencias se instalan la primera vez que arranca).
Opción B — Manual (CLI y otros agentes)
Primero instala uv si no lo tienes:
# Windows (PowerShell)
irm https://astral.sh/uv/install.ps1 | iex# macOS / Linux
curl -LsSf https://astral.sh/uv/install.sh | sh(o pip install uv si prefieres).
Luego, en la carpeta del proyecto:
uv syncY añade a la configuración de servidores MCP de tu agente:
{
"mcpServers": {
"spij": {
"command": "uv",
"args": ["--directory", "RUTA/spij-mcp-OSS", "run", "spij-mcp", "serve"]
}
}
}El servidor envía sus instrucciones de uso por el handshake MCP: el agente sabe cómo buscar y leer sin prompts adicionales.
Related MCP server: mcp-abogadoenquilmes
Tools
Tool | Qué hace |
| Búsqueda full-text con filtros (dispositivo, sector, agrupación, número, fechas) y paginación |
| Igual, para jurisprudencia; |
| Índice de encabezados de una norma (TÍTULO, CAPÍTULO, Artículo N.) con offsets navegables |
| Salta a las ocurrencias de una palabra o frase dentro de una norma |
| Metadatos + texto plano de una norma por |
| Texto completo garantizado, incluido el acervo de suscriptores |
| Valores exactos para los filtros (dispositivos, sectores, tomos, materias, agrupaciones) |
Cómo se lee (4 niveles)
Descubrir —
buscar_normas/buscar_jurisprudencia: cada resultado traeid,url_webysumilla.Mapear —
estructura_norma(id): índice de encabezados con offsets.Saltar —
buscar_en_norma(id, texto): ocurrencias con offsets.Leer —
texto_completo(id, offset, max_chars): lectura por rangos;desde_final=Truelee la decisión de una sentencia directo.
Los offsets son consistentes entre tools: se puede empezar a leer justo donde interesa sin traer textos completos de más.
Notas de uso
El buscador del SPIJ hace AND implícito con todas las palabras y no acepta comillas ni operadores OR/NOT. Acepta comodines de Lucene (
presupuest*).Si una búsqueda da 0 resultados, la respuesta incluye
sugerenciascon conteos de consultas más cortas; si un número de norma no está indexado, la respuesta trae los documentos que lo mencionan.Los textos legales pueden ser extensos: la lectura progresiva (offsets) evita llenar el contexto con lo que no se necesita.
Pruebas de concepto del servicio
El SPIJ es un servicio público de MINJUS. Este cliente lo consulta como lo hace su propia interfaz web, sin abuso: cache local, concurrencia limitada y re-autenticación automática.
Aviso legal
Proyecto independiente, no oficial, sin relación con MINJUS, el SPIJ ni ninguna entidad del Estado peruano.
Sin garantía de disponibilidad del servicio upstream ni de exactitud de los textos; para uso jurídico serio, verifica siempre en la fuente oficial.
La autoría normativa pertenece al Estado Peruano.
Licencia
Available Tools
7 toolsbuscar_en_normaA
Busca una palabra o frase DENTRO del texto completo de una norma del SPIJ, y devuelve cada ocurrencia con su offset (para leer alrededor con texto_completo(id, offset=X, max_chars=N)). Ideal para saltar a secciones concretas (ej 'RATIFICAN', 'Artículo 8', 'DISPOSICIONES FINALES') sin leer todo el texto. La busqueda ignora acentos y mayusculas.
Args: id: identificador del SPIJ, ej 'H1385488'. texto: palabra o frase a buscar dentro de la norma (1-8 palabras). contexto: caracteres de contexto alrededor de cada ocurrencia (50-500, default 200). max_matches: maximo de ocurrencias a devolver (1-25, default 10).
Devuelve: ok, id, url_web, total_caracteres, matches: lista de {offset, extracto}, hay_mas (si quedan ocurrencias).
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| texto | Yes | ||
| contexto | No | ||
| max_matches | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden and discloses useful behavior: search ignores accents and capitalization, returns offsets and extracts, enforces context and match limits, and indicates hay_mas when more occurrences remain. It does not mention authentication, rate limits, or error behavior, but those are less critical for this read-only search tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Front-loads the core behavior before the argument and return details, and the Args/Devuelve structure makes scanning easy. The examples and range details earn their place by removing ambiguity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Covers what the tool does, all parameters, and the return shape even though there is no output schema. It also supplies the offset-to-texto_completo workflow, which is the key operational context for using the results.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate, and it does: it documents all four parameters with meaning, examples, and constraints, including id format, texto length, contexto range and default, and max_matches range and default.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource: searching a word or phrase inside the full text of a specific SPIJ norm. It also distinguishes itself from reading the whole text by explaining the offset-based occurrence result and referencing texto_completo for surrounding context.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Makes the intended use clear: ideal for jumping to specific sections without reading all text. It names texto_completo as the follow-up tool for reading around a match, but it does not explicitly say when to prefer buscar_normas or other siblings instead.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
buscar_jurisprudenciaA
Busca jurisprudencia en el SPIJ (TC, cortes, precedentes, sentencias).
Args: consulta: texto libre (AND implicito, sin comillas ni OR; comodin * ok). Empieza con 1-2 palabras. tomo: tomo de jurisprudencia, ej 'TRIBUNAL CONSTITUCIONAL'. OJO: se envia al SPIJ pero el indice NO lo aplica (verificado: los totales son identicos con y sin tomo) - filtra con la consulta y/o fechas. materia: especialidad dentro del tomo, ej 'JURISPRUDENCIA ADMINISTRATIVA' del tomo del TC. Ver listar_filtros(categoria='materias'). organismo: filtra LOCALMENTE por organismo emisor, ej 'TC', 'CORTE SUPREMA', 'OSIPTEL', 'CGD' (coincide contra codigo/sector/dispositivo, sin acentos). El servidor escanea hasta 5 paginas del SPIJ y devuelve solo los coincidentes (con 'filtrados' y 'escaneadas'). Es la via correcta: el indice no filtra por tomo. numero: numero de expediente o codigo, ej '03209-2024-PA/TC' (expediente completo del TC funciona). fecha_ini / fecha_fin: rango de publicacion AAAA-MM-DD. orden: '1' = fecha (default), '2'/'3'/'4' = relevancia. start / paginas: igual que buscar_normas (por cada pagina devuelta el servidor puede escanear varias internamente). sumilla_chars: maximo de caracteres de la sumilla por documento (0 = sin limite).
Devuelve: ok, total (del indice), organismo, escaneadas (paginas escaneadas), filtrados (coincidencias encontradas), normas, siguiente_start (si quedan paginas por escanear). Si la consulta base arroja 0 resultados incluye 'sugerencias'; si el indice arroja resultados pero ninguno del organismo pedido, incluye 'organismos_disponibles' (los organismos presentes en lo escaneado). El texto se obtiene con detalle_norma(id) o texto_completo(id).
| Name | Required | Description | Default |
|---|---|---|---|
| tomo | No | ||
| orden | No | 1 | |
| start | No | ||
| numero | No | ||
| materia | No | ||
| paginas | No | ||
| consulta | No | ||
| fecha_fin | No | ||
| fecha_ini | No | ||
| organismo | No | ||
| sumilla_chars | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden and does so: it discloses that tomo is ignored by the index, that organismo filters locally by scanning up to 5 SPIJ pages, and it documents practical failure modes ('sugerencias' on zero results, 'organismos_disponibles' when no match under the requested organismo). This is unusually thorough behavioral context beyond a bare verb+resource statement.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Front-loaded purpose followed by well-separated Args and Devuelve blocks make it easy to scan. It is long, but the length is justified by the 11 undocumented parameters and absent output schema; only minor redundancy between the tomo/organismo notes.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no output schema, the description supplies the return contract itself (ok, total, organismo, escaneadas, filtrados, normas, siguiente_start, plus conditional sugerencias / organismos_disponibles). Combined with per-parameter guidance, an agent has everything needed to invoke and interpret the call.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0% and there are 11 parameters, so the description must compensate fully. It documents essentially every parameter with format hints and quirks: consulta syntax rules (implicit AND, no quotes/OR, wildcard *, start with 1-2 words), expediente formats like '03209-2024-PA/TC', AAAA-MM-DD dates, orden codes, and sumilla_chars=0 meaning unlimited.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb (Busca) and resource (jurisprudencia en el SPIJ), and scopes it with concrete content types (TC, cortes, precedentes, sentencias). An agent can distinguish it from the sibling buscar_normas without opening either schema.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly routes usage: warns that 'tomo' is not applied by the index and that organismo is the correct filter path, and points to listar_filtros(categoria='materias') for enumerating values. It also names detalle_norma / texto_completo as the follow-up tools for retrieving full text, giving clear when-to-use and next-step guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
buscar_normasA
Busca normas legales en el SPIJ (normas generales, administrativas, etc).
Args: consulta: texto libre en el contenido. El buscador hace AND implicito con TODAS las palabras (ej 'transferencia partidas'). OJO: NO acepta comillas ni OR. Si acepta comodin al final de una raiz, ej 'presupuest*'. Empieza con 1-2 palabras. sumilla: texto a buscar solo en la sumilla (resumen) de la norma. dispositivo: tipo de dispositivo legal, ej 'DECRETO SUPREMO'. Acepta parcial ('decreto sup') y se resuelve solo; si es ambiguo devuelve candidatos. Ver listar_filtros. sector: entidad emisora, ej 'ECONOMIA Y FINANZAS'. Acepta parcial. agrupacion: grupo del acervo, ej 'LEGISLACION SUPRANACIONAL'. numero: numero del dispositivo, ej '200-2026-EF' o '31068' (sin prefijo 'Nº'). OJO: algunas leyes no estan indexadas como registro propio; en ese caso la respuesta trae los documentos que lo mencionan (con una nota que lo explica). fecha_ini / fecha_fin: rango de publicacion, formato AAAA-MM-DD. orden: '1' = fecha (recientes primero, default), '2'/'3'/'4' = relevancia. start: desplazamiento (multiplo de 10). Pagina N -> start = (N-1)*10. paginas: paginas consecutivas a traer en una sola llamada (cada pagina = 10 resultados, max 10 paginas). sumilla_chars: maximo de caracteres de la sumilla por documento (0 = sin limite). Para leer la sumilla completa usa detalle_norma(id).
Devuelve: ok, total, desde, hasta, siguiente_start (si hay mas paginas), normas: lista de {id, url_web, codigoNorma, dispositivoLegal, sector, fechaPublicacion, sumilla} (con 'sumilla_total' si se acoto). Ante 0 resultados devuelve 'nota' y 'sugerencias' ({param, consulta, total} de versiones mas cortas de la consulta o de la sumilla, sin filtros categoricos).
| Name | Required | Description | Default |
|---|---|---|---|
| orden | No | 1 | |
| start | No | ||
| numero | No | ||
| sector | No | ||
| paginas | No | ||
| sumilla | No | ||
| consulta | No | ||
| fecha_fin | No | ||
| fecha_ini | No | ||
| agrupacion | No | ||
| dispositivo | No | ||
| sumilla_chars | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations exist, so the description carries the full burden, and it does: ordering defaults, pagination semantics (start multiples of 10, paginas up to 10), the exact shape of the zero-result response (nota + sugerencias with shortened queries), and the ambiguity/candidate behavior for partial dispositivo values.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Front-loaded one-line purpose followed by clearly separated Args and Devuelve sections; nearly every sentence adds an example or a warning. It is dense and long, but the length is justified by 12 undocumented parameters and no output schema.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no annotations, no output schema, and 0% schema coverage across 12 parameters, the description supplies everything an agent needs: input semantics, return fields, pagination, ordering, and error/empty-result behavior.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, yet every one of the 12 parameters is documented with format, examples, and pitfalls ('200-2026-EF', 'sin prefijo Nº', AAAA-MM-DD, sumilla_chars=0 means no limit, start=(N-1)*10). This fully compensates for the empty schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource ('Busca normas legales en el SPIJ') with the scope of the corpus (normas generales, administrativas). The resource distinction from buscar_jurisprudencia is implicit in the terminology, and it explicitly points to detalle_norma and listar_filtros for adjacent needs.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Gives concrete query-construction rules (AND semantics, no quotes/OR, trailing wildcard, start with 1-2 words) and routes the agent to siblings: listar_filtros for ambiguous dispositivo, detalle_norma for the full sumilla. It also explains fallback behavior when a numeric law is not indexed as its own record.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
detalle_normaA
Devuelve los METADATOS y el TEXTO de una norma del SPIJ por su id.
Args: id: identificador del SPIJ, ej 'H1453062' (lo devuelve buscar_normas). offset: desde que caracter del texto empezar (0 = inicio). max_chars: maximo de caracteres de texto a devolver en esta llamada (0 = usa el limite por defecto). Si el texto es mas largo, 'siguiente_offset' indica por donde continuar. desde_final: si es True, devuelve los ULTIMOS max_chars caracteres (en sentencias judiciales la decision 'RESUELVE' esta al final).
Devuelve: ok, id, url_web (para abrir la norma en el sitio SPIJ), codigoNorma, dispositivoLegal, sector, fechaPublicacion, ruta, titulo, sumilla, texto (texto plano, sin HTML), total_caracteres, texto_truncado, siguiente_offset (si hay mas texto).
Nota: si el texto es muy largo para tu contexto, lee por rangos con offset (ej offset=20000) o la cola con desde_final=True.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| offset | No | ||
| max_chars | No | ||
| desde_final | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full behavioral burden and does well: it discloses the return shape (texto sans HTML, total_caracteres, texto_truncado, siguiente_offset) and the truncation/continuation behavior. It stops short of stating permissions or rate limits, but for a read tool that is minor.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Structured as Args/Devuelve/Nota with the core action front-loaded. Each section earns its place, though the closing 'Nota' partly repeats the offset/desde_final guidance already given in Args, adding mild redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema and no annotations, yet the description documents parameters, return fields, and pagination. It is self-sufficient for correct invocation; only the lack of differentiation from the texto_completo sibling leaves a small gap.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate, and it does fully: id format example 'H1453062' plus its source, offset as character index with 0=start, max_chars with 0=default limit and truncation behavior, and desde_final semantics with a rationale for judicial sentences.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource ('Devuelve los METADATOS y el TEXTO de una norma del SPIJ por su id') and clarifies where the id comes from (buscar_normas). It is clear what the tool does, though it does not explicitly differentiate itself from the similar sibling texto_completo.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Gives strong operational guidance: how to page long texts via offset/desde_final, that desde_final targets the trailing 'RESUELVE' of judicial sentences, and a closing note to read in ranges when the text exceeds context. No explicit when-not-to-use versus siblings, but the pagination context is clear.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
estructura_normaA
Devuelve el INDICE de encabezados de una norma del SPIJ, con el offset de cada uno para leer secciones concretas con texto_completo(id, offset=X, max_chars=N).
Args: id: identificador del SPIJ, ej 'H1453062' (lo dan buscar_*).
Devuelve: ok, id, url_web, fuente, total_caracteres, total_encabezados, encabezados: lista de {tipo: 'seccion'|'articulo', titulo, offset} (hasta 150; con 'siguiente_encabezado' si hay mas). Los offsets apuntan al mismo texto canonico que sirve texto_completo. Si la norma no tiene encabezados (sentencias del TC son prosa), 'encabezados' viene vacia: usa buscar_en_norma o lectura por rangos.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden and does well: it discloses the 150-heading cap, the 'siguiente_encabezado' pagination key, that offsets index the same canonical text as texto_completo, and the empty-result case for prose (TC sentencias). It omits auth/rate-limit or cost context, keeping it below a 5.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Front-loaded purpose, then Args and Devuelve sections. The return listing is somewhat verbose but earns its place given there is no output schema. Little waste overall.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema exists, so the description correctly documents the return shape (ok, id, url_web, fuente, totals, encabezados list) and the truncated/empty cases. Combined with the sibling routing hint, an agent has everything needed to call and interpret it.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0% and the single required param is undocumented in the schema, but the description compensates: 'id' is defined as the SPIJ identifier with an example ('H1453062') and it notes the id comes from buscar_* tools. That is enough to call the tool correctly.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource: returns the index of headings of a SPIJ norm, including each heading's offset. It is clearly distinguishable from siblings like texto_completo (full text) and buscar_en_norma (search), so an agent can route correctly.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explains the intended workflow — use the returned offsets to read specific sections via texto_completo(id, offset=X, max_chars=N) — and names fallbacks (buscar_en_norma or range reading) for prose norms with no headings. It does not explicitly contrast with detalle_norma or say when not to use it, so it stops short of a 5.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
listar_filtrosA
Lista los valores validos para los filtros del SPIJ.
Args: categoria: una de 'dispositivos', 'agrupaciones', 'tomos', 'materias', 'sectores'. Si se omite, devuelve un resumen con conteos y ejemplos de cada categoria. tomo: solo para categoria='materias': el tomo de jurisprudencia del que se quieren las especialidades, ej 'TRIBUNAL CONSTITUCIONAL'.
'dispositivos': tipos de dispositivo legal (ej DECRETO SUPREMO). 'agrupaciones': grupos del acervo (ej LEGISLACION SUPRANACIONAL). 'tomos': tomos de jurisprudencia (ej TRIBUNAL CONSTITUCIONAL). 'materias': especialidades de un tomo de jurisprudencia (requiere 'tomo'). 'sectores': entidades emisoras (hay cientos; si el tuyo no esta en la lista puedes escribir parte del nombre en buscar_normas y se resuelve automaticamente).
Devuelve: dict con 'ok' y la lista 'valores': son los strings EXACTOS que aceptan buscar_normas y buscar_jurisprudencia.
| Name | Required | Description | Default |
|---|---|---|---|
| tomo | No | ||
| categoria | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the burden and does well: it discloses the return shape ('ok' plus 'valores'), conditional behavior for omitted categoria and required tomo, and the exact-string nature of results. It does not explicitly state that the operation is read-only or mention error behavior, but the listed behavior is clear.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is front-loaded with its purpose and then structured into Args, category explanations, and return values. It is appropriately detailed for a discovery tool, though the tomo requirement is repeated slightly between the Args section and the categoria breakdown.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given 0% schema description coverage, no output schema, and a two-param tool with conditional behavior, the description is complete. It documents both parameters, the return structure, valid category values, and how the output connects to sibling search tools.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate for both parameters. It fully enumerates valid categoria values, explains the dependency of tomo on categoria='materias', gives an example tomo value, and describes the special summary behavior when categoria is omitted.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource: listing valid filter values for SPIJ. It also clarifies that returned strings are exactly the values accepted by buscar_normas and buscar_jurisprudencia, so an agent can distinguish this discovery tool from the sibling search tools.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explains when each categoria is relevant, that tomo is only used with categoria='materias', and that omitting categoria returns a summary. It also gives an alternative path for sectores when a value is missing. However, it does not explicitly frame the overall when-to-use versus when-not-to-use relationship with all siblings.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
texto_completoA
Devuelve el TEXTO COMPLETO de una norma o jurisprudencia del SPIJ.
Ruta robusta: obtiene el documento word del SPIJ (ruta que incluye el acervo completo de jurisprudencia) y devuelve texto plano. Si esa ruta falla, usa el texto del detalle.
Args: id: identificador del SPIJ, ej 'H1352213' (lo dan buscar_*). offset: desde que caracter del texto empezar (0 = inicio). max_chars: maximo de caracteres a devolver en esta llamada (0 = usa el limite por defecto). Si hay mas texto, 'siguiente_offset' indica por donde continuar. desde_final: si es True, devuelve los ULTIMOS max_chars caracteres (en sentencias judiciales la decision 'RESUELVE' esta al final; combinado con max_chars=3000 la lees directo).
Devuelve: ok, id, url_web, codigoNorma, fechaPublicacion, dispositivoLegal, texto (texto plano), total_caracteres, texto_truncado, siguiente_offset (si hay mas; None con desde_final).
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| offset | No | ||
| max_chars | No | ||
| desde_final | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden and does well: it discloses the primary route (documento word), the fallback route (texto del detalle), truncation behavior with siguiente_offset, and that desde_final returns the tail. It omits any note on permissions, rate limits, or failure modes beyond the word/detalle fallback.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Front-loaded with the core purpose, then structured Args/Devuelve sections that each earn their place. Slightly verbose in the route explanation, but no sentence is pure filler.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no output schema and no annotations, the description enumerates every return field (ok, id, url_web, codigoNorma, fechaPublicacion, dispositivoLegal, texto, total_caracteres, texto_truncado, siguiente_offset) and explains pagination end-to-end. An agent has everything needed to call and consume this reliably.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0%, so the description must fully document the four parameters — and it does: id format with an example, offset as start character, max_chars with 0 = default and its link to siguiente_offset, and desde_final with the reviewing-decision rationale. 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.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb+resource: returns the FULL TEXT of a norm or jurisprudence from SPIJ, which is clearly more than a summary. It distinguishes itself from the search siblings by noting the 'id' comes from buscar_*, but it never contrasts itself with closer siblings like detalle_norma or estructura_norma, leaving that boundary implicit.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Clear context: use it after buscar_* to fetch an id and retrieve the whole document. It also gives a concrete usage tip (combinar desde_final=True con max_chars=3000 para leer el RESUELVE de una sentencia). No explicit when-not guidance or statement about when detalle_norma would be preferable.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
7 tool updates
v0.6.1- First observed
buscar_en_norma - First observed
buscar_jurisprudencia - First observed
buscar_normas - First observed
detalle_norma - First observed
estructura_norma - First observed
listar_filtros - First observed
texto_completo
TDQS
Scored across 7 tools
Buscar_normas and buscar_jurisprudencia are clearly split by domain, and estructura_norma versus buscar_en_norma serve distinct navigation purposes. However, detalle_norma and texto_completo heavily overlap: both retrieve text by id with offset/max_chars/desde_final, and the agent may hesitate which to use for a given document.
All names use consistent snake_case and Spanish, which is readable. But the pattern mixes verb-first (listar_filtros, buscar_normas, buscar_jurisprudencia) with noun-first (estructura_norma, detalle_norma, texto_completo) and a prepositional form (buscar_en_norma), so there is no single predictable convention.
Seven tools is well within the ideal 3–15 range for a read-only legal search server. Each tool has a distinct role (filter discovery, two search domains, outline, within-document search, retrieval), and none appears superfluous.
The read-only lifecycle is largely covered: filter discovery, norm and jurisprudence search, document structure, within-document search, and text retrieval via metadata or full-text routes. Minor gaps include no explicit batch retrieval or dedicated jurisprudence metadata tool, but the existing tools offer workarounds.
Maintenance
Related MCP Connectors
- LegalizeOAuthdev.legalize
Official MCP connector for Legalize: read and search its whole open corpus, at any point in time.
Brazilian legal stack in one MCP: lawsuits, court publications, case law, tenders, certificates.
Public Indian legal search MCP for Roop judgments, statutes, and corpus grounding.
Search and retrieve published Alkemata articles, pages, and guidance through a read-only MCP server.
41
Related MCP Servers
- AlicenseAqualityDmaintenanceMCP server for accessing Uruguay's IMPO open data API with SQLite caching. Provides tools to retrieve legal norms, search regulations, and access schema documentation from Uruguay's official legal database.4MIT
- FlicenseNot gradedqualityDmaintenanceRemote MCP server that provides access to over 285K Argentine court rulings and user's own case files via Streamable HTTP transport.-
- AlicenseAqualityCmaintenanceMCP server that connects AI to the Chilean legislation system (Ley Chile) for retrieving legal norms, citations, and intertemporal analysis.282MIT
- FlicenseAqualityBmaintenanceMCP server that provides access to Argentine legal documents (legislation, CSJN jurisprudence, international treaties) with verifiable provenance including SHA256 hashes and source URLs, enabling legal professionals to search and verify citations.13-