- Getting started
- Introduction
Getting started
Introduction
Issue your companies' fiscal documents from a single Treeunfe integration.
The Enterprise API is for anyone who issues fiscal documents on behalf of multiple companies from a single system. With an Enterprise account, you register each issuing company and issue invoices for all of them through the API, with a single key. With the Payload Inteligente (calculateTaxes: true), Treeunfe calculates the taxes from the company’s fiscal configuration.
What you can do with the API
- Register, edit, and deactivate issuing companies.
- Send the company a link to fill in its own fiscal configuration. If it prefers, the company can use the default rules of the Treeunfe tax engine.
- Issue NF-e, with or without automatic tax calculation.
- Cancel invoices and issue correction letters.
- Maintain each company’s customers, products, carriers, and digital certificate.
How the API is organized
The API uses a single key, your Enterprise account’s. Each call says which issuing company it acts on:
| Level | What it represents | Header | What it does |
|---|---|---|---|
| Enterprise | Your account, which groups the issuing companies | x-enterprise-key | Authenticates every call, with the key’s permissions and environment |
| Organization | Each issuing company | x-organization-id | Says which company the call issues NF-e, registers events, or maintains records and the certificate for |
Each organization has its own records and digital certificate. One organization’s invoices never mix with another’s.
Quickstart
From the organization to the first NF-e in the sandbox.
Authentication
The key, its permissions, and environment.
Issuing NF-e
With or without automatic tax calculation.
API Reference
Every endpoint, with a playground.
Want to issue NF-e from Claude or another AI agent? See the Treeunfe MCP.
Base URL
https://api.treeunfe.com.br/api/v1
All requests and responses use JSON (Content-Type: application/json), except the certificate upload, which uses multipart/form-data.