Skip to main content
Glama

cnae_ncm_lookup

Look up Brazilian CNAE economic activity codes and NCM product classifications by code or search term, with paginated results for compliance checks and business verification.

Instructions

Look up Brazilian economic activity classifications (CNAE via IBGE v2) and Mercosur goods nomenclature (NCM via BrasilAPI). For CNAE, pass codigo (2, 3, 4-5, or 7 digits) or termo for paginated class search. For NCM, pass codigo (e.g. '2710.12.59') or termo for paginated description search. No API key required.

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": {
      "tipo": "<tipo>"
    },
    "name": "cnae_ncm_lookup"
  }
}

Input Schema

NameRequiredDescriptionDefault
pageNo1-indexed page number for paginated search results (default: 1)
tipoYesClassification table: 'cnae' (IBGE v2) or 'ncm' (BrasilAPI)
limitNoResults per page (default: 25, max: 50)
termoNoSearch term for CNAE classes or NCM descriptions
codigoNoCNAE code (2, 3, 4-5, or 7 digits) or NCM code

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.7.0

TDQS

B3.3/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden. It does disclose two useful traits -- paginated results and 'no API key required' -- but omits what a codigo exact-match returns versus a termo search, what happens if both are supplied, error behavior for invalid codes, or result shape. That is thin for a tool with zero annotation coverage.

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?

Three sentences, front-loaded with the overall purpose and organized one-line-per-mode for CNAE and NCM. Efficient, with only mild redundancy between the sentence-level mode notes and the schema's own parameter descriptions.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a read-only classification lookup with a fully described 5-parameter schema and no output schema, the definition covers both modes and the required discriminator. The remaining gaps -- return shape and codigo/termo precedence -- are minor for such a simple lookup.

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 description coverage is 100%, so the schema already documents page, limit, tipo, termo and codigo, and the description largely restates the codigo length rules. It adds no meaning beyond the schema on precedence between codigo and termo, or on how limit/page interact with codigo lookups; baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: lookup of Brazilian CNAE economic activity classifications (IBGE v2) and NCM Mercosur goods nomenclature (BrasilAPI). Naming the data sources and code systems gives an agent enough to distinguish it from generic CNPJ/company lookup siblings, though it never explicitly contrasts with them.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains how to invoke each mode (pass codigo or termo per tipo) but never says when to choose this tool over a sibling, or when each mode is appropriate beyond the implied 'look up a classification code'. Usage is inferable from the tool name and required tipo parameter rather than stated.

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