# Focus NFe MCP for AI Agents AI Agent Connect

> Focus NFe lets you manage Brazilian fiscal documents through your AI agent. You can issue product and service invoices, check their status, cancel them, and grab the XML files for your records. It connects directly to the Focus NFe API to handle your tax compliance tasks without you having to jump between different tabs or portals.

## Overview
- **Category:** erp-operations
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_Vu8VDwORqN3itzXZWHiiXsz3NsjwF5EQKPSPFqWU/ai-agent-connect
- **Tags:** fiscal-invoicing, tax-compliance, brazil-tax, electronic-documents, accounting-automation

## Description

Focus NFe handles the heavy lifting of Brazilian fiscal documentation. Instead of logging into a separate portal to manage every single invoice, you can just tell your AI agent what needs to happen. If you need to issue a product invoice, you give the details and it handles the rest. The same goes for service invoices. You can also check if a document went through, cancel a mistake, or grab the XML file for your accounting team. It's a way to turn a multi-step manual process into a quick conversation. Because Vinkius hosts this Connector, you can plug it into your existing workflow and let your agent handle the repetitive data entry and status checking that usually bogs down your day. You get to focus on the actual business while the technical side of tax compliance stays updated in the background.

## Tools

### cancel_document
Void an authorized invoice and provide a reason for the cancellation. This is useful for fixing errors.

### download_xml
Grab the authorized XML document for your records. You need these files for proper tax reporting.

### emit_nfe
Issue a Product Invoice (NF-e) including all required item details. This is the standard for physical goods.

### emit_nfse
Create a new Service Invoice (NFS-e) for your business. Use this for all service-based billing.

### consult_document
Check the current status and details of a specific invoice. This helps you see if a payment document is authorized.

## Prompt Examples

**Prompt:** 
```
Emit a service invoice for R$500 for 'Consulting Services'.
```

**Response:** 
```
### Service Invoice Details

| Description | Amount | Status |
| :--- | :--- | :--- |
| Consulting Services | R$500.00 | **Authorized** |

**Reference:** SERV-001
**Notes:** Invoice has been successfully issued via the Focus NFe system.
```

**Prompt:** 
```
Cancel invoice REF-123 with reason 'Client requested cancellation'.
```

**Response:** 
```
### Cancellation Confirmed

*   **Invoice Reference:** REF-123
*   **Status:** Cancelled
*   **Reason:** Client requested cancellation

The document has been voided in the fiscal system.
```

**Prompt:** 
```
Get the XML for invoice REF-123.
```

**Response:** 
```
### XML Retrieval

I have successfully downloaded the authorized XML for invoice **REF-123**. 

*   **File Status:** Ready for download
*   **Next Step:** You can now provide this to your accounting team for tax filing.
```

## Capabilities

### Issue product invoices
Create NF-e documents with full item details.

### Create service invoices
Generate NFS-e documents instantly.

### Check invoice status
See if a document is authorized or still processing.

### Cancel issued invoices
Void a previously authorized document with a reason.

### Get XML files
Retrieve the official XML for your accounting records.

## Use Cases

### Billing a new project
A consultant needs to bill a client for a project. They ask the agent to emit a service invoice for R$500.

### Correcting a billing mistake
A shop owner needs to cancel a wrong order. They tell the agent to cancel invoice REF-123 because the client requested it.

### Gathering tax documents
An accountant needs to gather files for tax season. They ask the agent to download the XML for a list of invoices.

### Verifying payment status
A SaaS owner wants to check if a customer's invoice was successful. They ask the agent to consult the status of a specific document.

## Benefits

- Stop manual data entry by using emit_nfe to create product invoices with full details in one go.
- Save time on service billing by using emit_nfse to generate NFS-e documents instantly.
- Keep your records organized by using download_xml to pull files for your accounting software.
- Reduce errors by using cancel_document to quickly void mistakes with a specific reason.
- Get real-time updates on your billing by using consult_document to see if invoices are authorized.

## How It Works

The bottom line is you get to manage your entire Brazilian invoicing cycle through a single chat interface.

1. Subscribe to the Connector and grab your Focus NFe API Token and Base URL.
2. Add these credentials to your AI client's configuration.
3. Ask your agent to issue, cancel, or check invoices in plain English.

## Frequently Asked Questions

**What can Focus NFe do for my business?**
Focus NFe lets you issue product and service invoices, check their current status, cancel mistakes, and download the XML files you need for accounting.

**Can I use Focus NFe to issue product invoices?**
Yes, you can use it to issue NF-e documents, which are the standard for selling physical products in Brazil.

**How do I get my XML files for accounting?**
You can simply ask your AI agent to grab the XML for a specific invoice, and it will retrieve the authorized document for you.

**Can I cancel a mistake with Focus NFe?**
Yes, you can cancel authorized invoices directly through the chat by providing the reference number and a reason for the cancellation.

**Is Focus NFe for Brazilian taxes?**
Yes, it is specifically designed for Brazilian fiscal documentation, including both NFS-e and NF-e invoice types.

**How does Focus NFe connect to my AI?**
You connect it by providing your Focus NFe API Token and Base URL to your AI client, allowing your agent to act on your behalf.

**Does it support both NFS-e and NF-e?**
Yes! The tools allow emitting and managing both Service Invoices (nfse) and Product Invoices (nfe) seamlessly.

**How do I get my API Token?**
Log in to the Focus NFe portal and navigate to the API section to generate your token.

**Can I download the authorized XML?**
Yes, use the `download_xml` tool with the document reference to retrieve the full XML content.

**Is it homologated for all Brazilian cities?**
Focus NFe covers thousands of cities for NFS-e emission. You can check their API documentation for the complete list of supported IBGE city codes.