Skip to main content
Glama

Banco Central do Brasil (BCB) — SGS Time Series MCP Server

Documento para Deep Research

fetch
Read-onlyIdempotent

Returns the full document for an id obtained from search, as { id, title, text, url, metadata }: text is the readable content (Markdown) and url the canonical public page to cite.

Companion of search in the OpenAI Deep Research contract, over the Banco Central do Brasil time series (SGS: interest rates, inflation, exchange rates, credit, fiscal and external sector — the curated catalog plus the open data portal index) catalog. Only ids returned by search are valid; an unknown id returns an error. The bcb_* tools remain the tools for data queries.

Behavior: read-only and idempotent — a live GET against the public source when the document needs it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesIdentificador de um documento devolvido por `search`

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesIdentificador único do documento no servidor; é o que `fetch` recebe
urlYesURL pública canônica do documento — a citação do ChatGPT depende dela
textYesConteúdo integral do documento, legível (Markdown)
titleYesTítulo legível do documento
metadataNoPares chave/valor adicionais sobre o documento (tipo, fonte, período…)
provenanceYesUm bloco por procedência que contribuiu com esta resposta (contrato v1.1; licenças nunca se fundem)
attributionYesURLs canônicas das fontes desta resposta (lista de atribuição)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedOutput schema / properties / provenance / items / description
      Previous value: -"Bloco de proveniência (contrato v1.1): fonte, URL, competência, extração, diagnóstico de origem, citação e licença"New value: +"Bloco de proveniência (contrato v1.2): fonte, URL, competência, extração, diagnóstico de origem, citação e licença; e, só quando a resposta junta partes de origens ou momentos distintos, de onde veio cada parte"
    • addedOutput schema / properties / provenance / items / properties / field_sources
      Added value: +{
      +  "description": "Presente só quando a resposta junta partes de origens ou momentos distintos: para cada grupo de campos, a URL, a extração e se veio do cache. Ausente nas respostas de uma origem só",
      +  "items": {
      +    "additionalProperties": false,
      +    "description": "Proveniência de um grupo de campos da resposta: de onde veio e quando foi extraído",
      +    "properties": {
      +      "data_vintage": {
      +        "description": "Vintage/competência da sub-fonte",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "dataset_id": {
      +        "description": "Identificador do conjunto da sub-fonte",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "fields": {
      +        "description": "Campos do payload atribuídos a esta sub-fonte",
      +        "items": {
      +          "type": "string"
      +        },
      +        "minItems": 1,
      +        "type": "array"
      +      },
      +      "retrieved_at": {
      +        "description": "ISO-8601 da extração desta sub-fonte na origem",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "served_from_cache": {
      +        "description": "true se esta sub-fonte veio do cache do servidor (retrieved_at é o da extração original); false se foi buscada nesta chamada; null se o servidor não distingue",
      +        "type": [
      +          "boolean",
      +          "null"
      +        ]
      +      },
      +      "source_url": {
      +        "description": "URL canônica da sub-fonte que originou estes campos",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "fields",
      +      "source_url",
      +      "dataset_id",
      +      "data_vintage",
      +      "retrieved_at"
      +    ],
      +    "type": "object"
      +  },
      +  "minItems": 1,
      +  "type": "array"
      +}
    • changedOutput schema / properties / provenance / items / properties / retrieved_at / description
      Previous value: -"Instante REAL da extração na origem (ISO-8601, fuso do servidor). Resposta servida de cache mantém o instante do fetch original, que é a data de extração relevante"New value: +"Instante REAL da extração na origem (ISO-8601, fuso do servidor). Resposta servida de cache mantém o instante do fetch original, que é a data de extração relevante. Quando a resposta junta partes extraídas em momentos distintos, é o MAIS ANTIGO deles (field_sources diz cada um)"
  2. Changed9 schema fields changed
    • changedOutput schema / properties / provenance / description
      Previous value: -"Um bloco por procedência que contribuiu com esta resposta (contrato v1.0; licenças nunca se fundem)"New value: +"Um bloco por procedência que contribuiu com esta resposta (contrato v1.1; licenças nunca se fundem)"
    • changedOutput schema / properties / provenance / items / description
      Previous value: -"Bloco de proveniência (contrato v1.0): fonte, URL, competência, extração e licença"New value: +"Bloco de proveniência (contrato v1.1): fonte, URL, competência, extração, diagnóstico de origem, citação e licença"
    • changedOutput schema / properties / provenance / items / properties / citation / description
      Previous value: -"Citação pronta para uso"New value: +"Citação/atribuição pronta para uso"
    • changedOutput schema / properties / provenance / items / properties / data_vintage / description
      Previous value: -"Competência do dado segundo a fonte; null quando a fonte não expõe"New value: +"Competência/vintage do dado segundo a fonte; null quando a fonte não expõe"
    • changedOutput schema / properties / provenance / items / properties / license / description
      Previous value: -"Regime legal do dado"New value: +"Regime legal do dado (id SPDX quando há, senão o nome da licença)"
    • addedOutput schema / properties / provenance / items / properties / retrieval
      Added value: +{
      +  "description": "Diagnóstico de origem da chamada: como o dado foi obtido. Medição real do servidor; unstable=true pede ao agente que trate o dado como obtido com dificuldade; null quando o servidor não mede",
      +  "oneOf": [
      +    {
      +      "additionalProperties": false,
      +      "description": "Diagnóstico de origem da chamada: como o dado foi obtido. Medição real do servidor; unstable=true pede ao agente que trate o dado como obtido com dificuldade",
      +      "properties": {
      +        "anomalies": {
      +          "description": "Anomalias superadas até o sucesso, somadas por classe, em ordem fixa; [] se nenhuma",
      +          "items": {
      +            "additionalProperties": false,
      +            "properties": {
      +              "count": {
      +                "description": "Ocorrências desta classe na chamada",
      +                "minimum": 1,
      +                "type": "integer"
      +              },
      +              "kind": {
      +                "description": "Classe da anomalia (vocabulário fechado do contrato)",
      +                "enum": [
      +                  "timeout",
      +                  "network",
      +                  "http_4xx",
      +                  "http_5xx",
      +                  "rate_limited",
      +                  "malformed_body"
      +                ],
      +                "type": "string"
      +              }
      +            },
      +            "required": [
      +              "kind",
      +              "count"
      +            ],
      +            "type": "object"
      +          },
      +          "type": "array"
      +        },
      +        "attempts": {
      +          "description": "Tentativas somadas, incluindo as repetidas (>= requests)",
      +          "minimum": 1,
      +          "type": "integer"
      +        },
      +        "requests": {
      +          "description": "Idas distintas à origem que compõem esta resposta (fatias, páginas)",
      +          "minimum": 1,
      +          "type": "integer"
      +        },
      +        "unstable": {
      +          "description": "true se houve repetição (attempts > requests) ou alguma anomalia",
      +          "type": "boolean"
      +        }
      +      },
      +      "required": [
      +        "requests",
      +        "attempts",
      +        "anomalies",
      +        "unstable"
      +      ],
      +      "type": "object"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ]
      +}
    • changedOutput schema / properties / provenance / items / properties / retrieved_at / description
      Previous value: -"Instante REAL da extração na origem (ISO-8601, horário de Brasília). Resposta servida de cache mantém o instante do fetch ORIGINAL, que é a data de extração relevante."New value: +"Instante REAL da extração na origem (ISO-8601, fuso do servidor). Resposta servida de cache mantém o instante do fetch original, que é a data de extração relevante"
    • changedOutput schema / properties / provenance / items / properties / source_url / description
      Previous value: -"URL canônica que reproduz a consulta"New value: +"URL canônica que reproduz a consulta na fonte"
    • changedOutput schema / properties / provenance / items / required
      Previous value: -[
      -  "source",
      -  "source_url",
      -  "data_vintage",
      -  "retrieved_at",
      -  "citation",
      -  "license"
      -]New value: +[
      +  "source",
      +  "source_url",
      +  "data_vintage",
      +  "retrieved_at",
      +  "retrieval",
      +  "citation",
      +  "license"
      +]
  3. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint and destructiveHint=false, so the safety profile is covered. The description still adds value beyond them: it discloses that retrieval performs a live GET against the public source and that an unknown id returns an error, plus the Markdown/canonical-url return semantics.

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?

Front-loaded with the core action and return shape, then context. The parenthetical catalog enumeration (SGS: interest rates, inflation, exchange rates, credit, fiscal and external sector...) is the one stretch of text that is informative but could be trimmed for an agent that only needs to call the tool.

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 return contract need not be spelled out, yet the description covers the input constraint, the failure mode, and the relationship to sibling tools. Nothing required to invoke it correctly is missing.

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?

Schema coverage is 100% so the baseline would be 3, but the description adds meaning beyond the schema string: the id must originate from `search` and any other value fails. That constraint is not encoded in the schema's own description.

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 and resource ('Returns the full document for an id obtained from `search`') and names the exact return shape (id, title, text, url, metadata). It explicitly distinguishes itself from both `search` and the `bcb_*` family, so an agent can route without opening any schema.

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

Usage Guidelines5/5

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

Gives the precise precondition (only ids returned by `search` are valid, unknown ids error out) and an explicit exclusion ('The `bcb_*` tools remain the tools for data queries'). This is when-to-use, when-not-to-use, and the alternative in two sentences.

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.