Skip to main content
Glama
opedrosoares

MCP Compras.gov.br

by opedrosoares

compras_montar_dossie_arp

Read-onlyIdempotent

Assembles a complete ARP dossier in one call, returning header and, when an item is specified, balance, adherences, and participating units, while flagging invalid purchase IDs before querying upstream.

Instructions

Dossiê completo de uma ARP em uma chamada.

Composição: cabeçalho via /modulo-arp/1.1 (id PNCP) e — se numero_item informado — saldo (4), adesões (5) e unidades participantes (3) em paralelo. Os 3 últimos endpoints usam a chave composta numeroAta + unidadeGerenciadora.

Os 3 IDs vêm naturalmente do retorno de compras_arp_listar ou compras_arp_itens_listar (campos: numeroControlePncpAta, numeroAta, unidadeGerenciadora, numeroItem). Cache 10 min.

Quando numero_controle_pncp_ata vem no formato de compra (sem sufixo -NNNNNN), devolvemos diagnóstico explícito antes de bater no upstream — caminho que retornava cabecalho: null silencioso.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
numero_ataYesNúmero simples da ata (ex.: '00001/2024'). Usado nos endpoints de saldo, adesões e unidades participantes.
numero_itemNoNúmero do item dentro da ata. Se informado, traz também saldo, adesões e unidades participantes daquele item. Se omitido, apenas o cabeçalho é consultado.
unidade_gerenciadoraYesCódigo UASG da unidade gerenciadora da ata.
numero_controle_pncp_ataYesIdentificador PNCP completo da **ata** (formato `cnpj14-1-sequencial/ano-NNNNNN`, com sufixo numerando a ata SRP dentro da compra). Ex.: `00394452000103-1-004729/2024-000006`. NÃO confundir com ID de compra (sem o sufixo). Retornado em `compras_arp_por_fim_vigencia` como `numeroControlePncpAta`.

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.7/5.0
Behavior5/5

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

Beyond the readOnly/idempotent annotations, the description discloses concrete runtime behavior: parallel fetching of the three secondary endpoints, a 10-minute cache, and an explicit diagnostic when the PNCP identifier is in 'compra' format instead of 'ata' format, avoiding the previously silent cabecalho: null failure. This is substantial added transparency.

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?

The description is compact and well organized: purpose first, then composition, then data-source prerequisites, then caching and failure behavior. Each sentence contributes unique information and there is no filler or repetition of schema content.

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 with four parameters, a true output schema, and readOnly/idempotent annotations, the description supplies the missing context: what endpoints are composed, how the parameters map to them, where prerequisite IDs come from, cache behavior, and a known edge-case failure mode. Nothing essential for invoking it correctly is absent.

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

Parameters4/5

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

The schema already covers all parameters at 100%, so the bar is a baseline of 3. The description adds meaningful relational semantics: numero_item gates the extra endpoints, numero_ata + unidade_gerenciadora form the compound key for those endpoints, and numero_controle_pncp_ata has a format warning. This goes beyond the schema without being exhaustive.

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 'Dossiê completo de uma ARP em uma chamada', naming a specific verb, resource, and scope. It then enumerates the composition (header, saldo, adesões, unidades participantes), which clearly distinguishes this aggregation tool from the granular sibling endpoints like compras_arp_consultar and compras_arp_saldo_item.

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 clear context: it is a composite single-call dossier, conditional on numero_item, and it states that the required IDs come from compras_arp_listar or compras_arp_itens_listar. It does not explicitly name alternatives for when only a header or a single component is needed, so it stops short of full when-not guidance.

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