MCP Nfse Nacional MCP Server

MCP Server para consulta de NFSe no portal nacional (nfse.gov.br)

Local serverstdio

What is the MCP Nfse Nacional MCP server?

Most developer tooling work still happens through a UI a human drives. MCP Nfse Nacional MCP server moves it into the conversation instead. MCP Server para consulta de NFSe no portal nacional (nfse.gov.br).

The short version

MCP Server para consulta de Notas Fiscais de Serviço Eletrônicas (NFSe) no portal nacional (nfse.gov.br). Permite que agentes de IA autentiquem-se com certificado digital e-CNPJ/e-CPF e consultem, detalhem e baixem PDFs de NFSe emitidas.

Getting it running

mcp-nfse-nacional on npm is all you need. Most clients run it directly, so configuration is a few lines and a restart.

The tools it exposes

The server publishes 10 tools. What each one is for:

  • Ferramenta — Descrição
  • nfse_buscar — Busca NFSe emitidas em um período. Retorna lista com data, destinatário, valor, status e chave de cada nota
  • nfse_detalhes — Obtém os detalhes completos de uma NFSe a partir da sua chave. Retorna cabeçalho, emitente, valores, DPS e salva o XML localmente
  • nfse_pdf — Baixa o PDF (DANFSe) de uma NFSe a partir da sua chave. Retorna o caminho do arquivo PDF salvo localmente
  • CERT_FILESim
  • CERT_PASSWORDSim
  • MCP_TRANSPORT — Não
  • MCP_HOST — Não
  • MCP_PORT — Não
  • STORAGE_PATH — Não

What it needs from you

Configuration is passed through the environment: CERT_FILE, CERT_PASSWORD, STORAGE_PATH. Treat anything key-shaped as a real credential — scope it to the minimum the server needs, and rotate it if it ever lands in a shared config.

Things to watch

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • With 10 tools registered it takes up a noticeable share of the context window; turn it off in projects that never touch MCP Nfse Nacional.
  • Keep per-call confirmation enabled while you learn its behaviour; it is the cheapest safeguard you have.

How it compares

Plenty of developer tooling servers cover similar ground. The differences that matter in practice are scope of access and how much setup stands between you and a working tool call. MCP Nfse Nacional's toolset — Ferramenta, nfse_buscar, nfse_detalhes and 7 more — is a fair guide to whether it matches your workflow. It is maintained by samuelmoraesf; worth a glance at recent repository activity before you build anything load-bearing on it.

SyncDev reviews every entry in this directory against the project's own documentation before publishing, and revisits them as servers change.

Available tools

ToolWhat it does
FerramentaDescrição
nfse_buscarBusca NFSe emitidas em um período. Retorna lista com data, destinatário, valor, status e chave de cada nota.
nfse_detalhesObtém os detalhes completos de uma NFSe a partir da sua chave. Retorna cabeçalho, emitente, valores, DPS e salva o XML localmente.
nfse_pdfBaixa o PDF (DANFSe) de uma NFSe a partir da sua chave. Retorna o caminho do arquivo PDF salvo localmente.
CERT_FILE**Sim**
CERT_PASSWORD**Sim**
MCP_TRANSPORTNão
MCP_HOSTNão
MCP_PORTNão
STORAGE_PATHNão

How to install the MCP Nfse Nacional MCP server

{
  "mcpServers": {
    "nfse-nacional": {
      "command": "npx",
      "args": ["-y", "mcp-nfse-nacional"],
      "env": {
        "CERT_FILE": "your-value",
        "CERT_PASSWORD": "your-value",
        "STORAGE_PATH": "your-value"
      }
    }
  }
}

Add to claude_desktop_config.json, then restart Claude Desktop.

Configuration

VariableDescriptionRequired
CERT_FILEConfiguration value read at startup.Optional
CERT_PASSWORDConfiguration value read at startup.Optional
STORAGE_PATHFilesystem location the server is allowed to use.Optional

Example prompts to try

  • Use MCP Nfse Nacional to Ferramenta.
  • Use MCP Nfse Nacional to nfse buscar.
  • Use MCP Nfse Nacional to nfse detalhes.

Frequently asked questions

It connects MCP Nfse Nacional to MCP-compatible AI assistants such as Claude and Cursor, exposing 10 tools (Ferramenta, nfse_buscar, nfse_detalhes, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with MCP Nfse Nacional directly.