fiscal — Claude Code MCP server: Brazilian tax documents
Wires your agent into Brazil's fiscal infrastructure, so NF-e, NFC-e, NFS-e, CT-e, MDF-e and DC-e go to SEFAZ from the chat.
claude mcp add --transport http fiscal https://api.brasilnfe.com.br/services/McpWhat fiscal does
The server exposes more than 30 tools across eight groups. Product and retail invoices, service notes, transport and cargo documents, energy invoices, fiscal events such as cancellation or correction letters, SEFAZ lookups, and CRUD for customers, products and tax rules. Five resources under the brasilnfe:// scheme serve authorised XML, DANFE and received documents for a period, and five ready prompts cover guided issuance, cancellation and pre-flight checks. The agent picks the right tool on its own, builds the payload from the schema and turns SEFAZ errors into plain language.
Transport is Streamable HTTP against MCP 2025-06-18, with the endpoint at https://api.brasilnfe.com.br/services/Mcp. Auth is a Bearer token, and the default ceiling is 60 requests per minute per token. You get the token from the panel after signing up; homologação mode is free and keeps test documents out of production SEFAZ.
Cancellation and number voiding cannot be undone, so run the flow in homologação (tipoAmbiente: 2) first. Call the *_consultar tools before creating a customer or product, or you will end up with duplicates. Close idle sessions with DELETE /services/Mcp to free quota sooner.
What it helps with
- issue an NFC-e for a buyer's CPF without leaving the chat
- check SEFAZ service status for a given state
- cancel an authorised NF-e with a justification
- pull XML and DANFE for a document key
- estimate taxes and pick a taxation rule before issuing
Example prompts for the agent
- List the SEFAZ status for SP.
- Look up CNPJ 39.658.743/0001-99.
- Issue an NFC-e for R$ 89,90 to the consumer with CPF 123.456.789-00.
How to install fiscal
Platform CLI: remote server
claude mcp add --transport http fiscal https://api.brasilnfe.com.br/services/McpPlatform CLI: remote server
codex mcp add fiscal --url https://api.brasilnfe.com.br/services/McpConfig file
{
"mcpServers": {
"fiscal": {
"url": "https://api.brasilnfe.com.br/services/Mcp"
}
}
}Config file
{
"servers": {
"fiscal": {
"type": "http",
"url": "https://api.brasilnfe.com.br/services/Mcp"
}
}
}Platform CLI: remote server
gemini mcp add -t http fiscal https://api.brasilnfe.com.br/services/McpStep by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about fiscal
How do I install fiscal in Claude Code?
Run claude mcp add --transport http fiscal https://api.brasilnfe.com.br/services/Mcp. Then drop in your Bearer token and restart the client.
What does fiscal do?
It hands the agent tools for Brazil's fiscal system: issuing NF-e, NFC-e, NFS-e, CT-e, MDF-e and DC-e, fiscal events, SEFAZ queries, customer and product records, and XML or PDF downloads.
What do I need before it works?
A Bearer token from the Brasil NFe panel and an MCP-capable client. Homologação mode is free, so test documents never reach production SEFAZ.