Skip to main content
Glama

datajud_search

Read-onlyIdempotent

Busca processos em um tribunal por classe, órgão julgador e/ou assunto (códigos das tabelas do CNJ), paginada e ordenada por data de ajuizamento. DataJud NÃO indexa nome de parte nem OAB — pra isso use o MCP djen/legal.

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": {
      "tribunal": "<tribunal>"
    },
    "name": "datajud_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
fromNo
sizeNo
tribunalYes
sort_descNo
classe_codigoNo
force_refreshNo
assunto_codigoNo
numero_processoNo
orgao_julgador_codigoNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / force_refresh
      Added value: +{
      +  "type": "boolean"
      +}
  2. First observed

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false and openWorldHint=false, so the safety profile is covered. The description adds that results are paginated and sorted by data de ajuizamento, which is useful conduct information beyond the annotations. It says nothing about what force_refresh triggers, default or maximum page size, or result caps, which are the behaviors an agent would most want disclosed here.

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?

Two sentences, both load-bearing: the first gives filters, pagination and ordering; the second gives the negative boundary and redirects to the right alternative. Nothing is repeated from the title or the schema, and the key scoping fact is front-loaded.

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?

With 9 parameters, no output schema and no schema descriptions, the definition should say more about how paging works and what force_refresh means before an agent calls it. The filter triad and the party-name exclusion are covered, so it is adequate to start a call, but an agent could easily mis-set size or force_refresh. Not a fatal gap, but incomplete for a tool of this surface area.

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

Parameters2/5

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

Schema description coverage is 0% across 9 parameters, so the description carries the full burden and only covers three of them (classe, órgão julgador, assunto codes) plus an oblique nod to pagination and sorting. It never explains from/size semantics or defaults, the direction implied by sort_desc, what force_refresh does to caching, or the expected format of numero_processo. The gap on the pagination and refresh parameters is the most consequential omission.

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 (busca), the resource (processos), the tribunal scope, and the exact filterable dimensions (classe, órgão julgador, assunto with CNJ table codes), plus pagination and ordering by filing date. It also draws a hard boundary against what DataJud does not index, which lets an agent distinguish it from party/OAB-oriented tools without opening the 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 declares the excluded case (no party name, no OAB) and names the alternative MCP (djen/legal) to use instead, which is stronger than most definitions. It does not, however, tell the agent when to pick this over the closely related datajud_localizar_processo or datajud_get_processo, leaving that routing to inference.

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.