Skip to main content
Glama

IBGE MCP by Kyrodata

Look up a CNAE activity code

ibge_lookup_cnae
Read-onlyIdempotent

Looks up Brazil's official activity classification (CNAE 2.0, kept by IBGE). With code it returns that node (section, division, group, class or subclass), its full hierarchy and IBGE's notes on what it includes and excludes. With query it finds the classes whose description matches. Useful to tag a company activity or to read SIDRA tables broken down by CNAE. Read-only; reads IBGE's public API live through Kyrodata (cached up to an hour). An identical call within 10 minutes is served from memo at 0 credits. Result status is ok, denied or error, with the reason in text. Credit class: free (0 credits).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "ibge_lookup_cnae"
  }
}

Input Schema

NameRequiredDescriptionDefault
codeNoA CNAE 2.0 code: section letter (A), division (01), group (011), class (01113) or subclass (0111301).
limitNoHow many items to return (1–30, default 10).
queryNoWords describing the activity (e.g. 'cultivo de soja'). Returns matching classes. Ignored when code is given.
response_formatNoHow much of the answer to return. `concise` (the default) carries the headline figures; `detailed` adds the row-level series behind them and counts against the export quota.

Output Schema

NameRequiredDescriptionDefault
dataYesRaw numbers behind the text.
memoYestrue = identical call in the last 10 min, served again: 0 credits.
rowsNoTable rows; detailed only, capped per tool.
errorNoFailure message when status = error.
linksYesscreen = product page with these numbers.
deniedNoWhen status = denied: reason, feature, upgradeUrl.
statusYesok = data; denied = plan; error = failure or timeout.
windowNoLike-for-like window: from, to (YYYY-MM), label, months, crossesSeason.
caveatsYesReading caveats.
creditsYescharged, balance (null = unlimited), resetAt, session {charged, endsAt} of the 60-s billing session.
sourcesYesPer source: label, nameable, asOf.
dataVersionYesIdentity of the data that answered.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior5/5

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

Beyond the annotations (readOnly, idempotent, openWorld), the description discloses that data is fetched live from IBGE's public API via Kyrodata, cached up to an hour, and that an identical call within 10 minutes is served from memo at zero credits. It also states the result status values (ok/denied/error) with the reason in text and the credit class, which is exactly the operational context annotations cannot convey.

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 definition is front-loaded with the core action, then mode behavior, then operational facts, and nearly every clause carries information (hierarchy levels, caching, credit cost, status values). It is dense single-paragraph prose rather than structured, which slightly slows scanning of the credit/caching details.

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?

With an output schema present, the description needn't document return shapes, and it still covers status values and the code-vs-query branching. Combined with full schema coverage and annotations, an agent has everything needed to choose a parameter set and interpret the outcome.

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 code format, query semantics, limit bounds and the response_format enum. The description reinforces what each mode returns (node with hierarchy and notes vs. matching classes) but adds no format, precedence, or edge-case detail beyond the schema — a baseline 3.

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?

The description names a specific verb and resource (looks up CNAE 2.0, IBGE's official activity classification) and separates the two modes clearly: `code` returns a node plus its hierarchy and IBGE inclusion/exclusion notes, `query` returns matching classes. It does not explicitly contrast itself with siblings like ibge_search_tables or ibge_get_table_data, so the agent must infer the boundary, but the purpose itself is unambiguous.

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?

Concrete use contexts are given: tagging a company activity, or reading SIDRA tables broken down by CNAE. That tells an agent when this tool is relevant. There are no explicit exclusions or named alternatives for cases like 'I already have a code' or 'I want table data rather than the classification', which keeps it out of the top band.

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.

Resources