Skip to main content
Glama
opedrosoares

MCP Compras.gov.br

by opedrosoares

compras_healthcheck

Read-onlyIdempotent

Probe upstream routes of the MCP server to verify each functional module, detecting silent failures like missing contract fields, and report ok, degraded, or down status before demos.

Instructions

Diz, em ~30 segundos, o que está de pé neste servidor agora.

Estende compras_versao: além de versão e configuração, dispara um probe paralelo (timeout curto) contra as rotas upstream reais e devolve a situação por módulo funcional.

Por que existe: em 04/08/2026 a tool de pesquisa de preço de material estava quebrada havia semanas e ninguém sabia — a SEGES trocou a assinatura da rota sem versionar. A descoberta veio de um analista tentando usar a ferramenta. Antes de uma demonstração ou de instruir processo, rode isto: o objetivo é que a descoberta aconteça aqui, não no palco.

Args: profundidade: basico responde só versão/config (instantâneo); rotas (padrão) executa o probe upstream. modulo: restringe o probe a um módulo (ex.: pesquisa_preco, atas, pncp). Sem isso, testa todos.

Situação por módulo: - ok: todas as rotas responderam com os campos esperados. - degradado: alguma rota caiu, ou respondeu 200 sem os campos do contrato (ex.: rota de preço sem precoUnitario) — o modo de falha silencioso que só o contrato de campos pega. - fora: todas as rotas testáveis do módulo falharam. - pulado: faltou credencial (ex.: TRANSPARENCIA_API_KEY).

Rota que estoura o relógio é reexecutada em série antes de virar fora: com dezenas de rotas em paralelo, uma rota apenas lenta seria reportada como quebrada. Quando passa na segunda tentativa, o campo problemas do módulo registra "lenta sob carga" em vez de escondê-lo.

O campo pronto_para_uso é o resumo honesto: False quando existe qualquer módulo fora ou degradado.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
moduloNoRestringe o probe a um módulo funcional: 'pesquisa_preco', 'catalogo', 'organizacoes', 'atas', 'contratacoes', 'contratos', 'fornecedores', 'indicadores', 'legado', 'planejamento', 'pncp', 'sancoes', 'comprasnet', 'enriquecimento'. Sem valor, testa todos.
profundidadeNo'rotas' (padrão) testa as rotas upstream reais em paralelo e devolve situação por módulo (ok/degradado/fora) em ~30s. 'basico' devolve só versão e configuração, sem tocar a rede.rotas

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.3.14

TDQS

A4.4/5.0
Behavior5/5

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

The description richly discloses behavior beyond the annotations: it performs parallel probes against real upstream routes with short timeouts, retries timed-out routes serially before marking them 'fora', distinguishes silent contract-field failures from route failures, and explains credential-dependent 'pulado' status. The `pronto_para_uso` field is also defined as the honest summary, which gives agents a clear expectation of the tool's semantics. No contradiction with the read-only/idempotent annotations exists.

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?

The description is longer than average and includes a historical anecdote, but the main purpose is front-loaded in the first line and the rest is organized into clear sections: why it exists, arguments, status values, and retry behavior. The story about the 2026 outage earns its place by motivating the tool's existence, though some trimming would tighten it.

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 tool of this complexity—parallel probing, multiple statuses, retries, credential skips, and a derived readiness flag—the description covers essentially everything an agent needs to call it correctly. The presence of an output schema means return-value details are already structured, so the description's focus on semantics, edge cases, and timing is complete.

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 coverage is 100%, so the schema already documents both parameters in detail. The description reinforces `profundidade` with 'instantâneo' vs. probe behavior and gives examples for `modulo` (e.g., `pesquisa_preco`, `atas`, `pncp`), but adds little meaning beyond what the schema entries already state. Baseline 3 is appropriate.

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?

The description opens with a concrete statement of what the tool does: reports, in ~30 seconds, what is up on the server right now. It explicitly positions itself as an extension of the sibling `compras_versao` (version/config plus upstream probes), and frames this as a health check with per-module status, clearly distinguishing it from the many query-focused siblings.

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?

The description gives explicit guidance: run this before a demo or before instructing a process, so outages are discovered here rather than on stage. It also explains the `profundidade` choice and mentions that `compras_versao` is the more basic alternative, though it stops short of an explicit 'use compras_versao instead when only version/config is needed' exclusion.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/opedrosoares/MCP_Compras'

If you have feedback or need assistance with the MCP directory API, please join our Discord server