[BR] Services Invoice (NFSe)

What is an NFSe?

An NFSe (Nota Fiscal de Serviço Eletrônica) is the electronic invoice for services in Brazil. It is authorized by the municipality (Prefeitura) where the supplier is established, or through the NFSe Nacional. Brinta sends it to the right authority automatically.

FieldValue
invoice_typedebit
document_typeservices invoice
e_invoicetrue
currencyBRL

When to issue an NFSe

SituationIssue?
Sale of services to a Brazilian business (CNPJ)✅ Yes
Sale of services to an individual (CPF)✅ Yes
Sale of services to a foreign buyer✅ Yes, it is issued as an export of services
Rental, lease or assignment of real estate✅ Yes, but follow Services Invoice for Rental
Sale of goods❌ No, use Goods Invoice (NFe)

Field by Field

Root Level

supplier_company_id

UUID of the issuing company in Brinta. The prestador (CNPJ, Inscrição Municipal, tax regime and address) is pulled from this record. The supplier's municipality must be supported.

invoice_date

Issuance date in YYYY-MM-DD. Also used as the data de competência.

additional_info

Free text appended to the service description (discriminação) on the NFSe. The full description is limited to 2000 characters.


buyer

The buyer is the tomador of the NFSe.

company.type

ValueWhen to useTax registration read
businessLegal entityCNPJ
personIndividual (pessoa física)CPF

company.legal_name

Razão social (business) or full name (person), as registered with Receita Federal.

tax_registrations[]

typeRequiredDescription
CNPJFor business14 digits. Dots, slash and dash are removed automatically.
CPFFor person11 digits.
IMOptionalInscrição Municipal of the tomador.

If no tax registration is sent, the NFSe is issued without a tomador.

company.address

FieldDescription
address_line_1Street with the number at the end ("Alameda Santos 2200"). Trailing digits are sent as the number. With no trailing digits, SN is sent.
address_line_2Complemento.
neighborhoodBairro.
cityMunicipality name ("São Paulo").
stateISO format (BR-SP).
postal_codeCEP.
countryBR. Any other country issues the NFSe as an export of services.

Most municipalities reject a tomador with an incomplete address, so send every field. Each one is limited to 40 characters.

Foreign buyers

Send the buyer's foreign tax ID in tax_registrations[].number and a non-BR address.country. The NFSe is issued with the foreign tomador fields and ISS exigibility set to export.


items[]

How items are combined

An NFSe carries one service. If you send several items:

  • amount of every item is summed into the service value.
  • discount of every item is summed into the deductions.
  • The description lists each item as name + description + amount.
  • Classification codes and taxes are read from the first item only (items[0]).

If items need different codes, issue one NFSe per item.

categories[]

listRequiredDescription
cityServiceCodeYesMunicipal service code (item of LC 116) from the Prefeitura. Max 5 characters.
nbs codeYesNBS code, 9 digits without dots (1.1801.22.00 → "118012200"). Code list
cClassTribRecommendedIBS/CBS tax classification. Default 000001. Code list
operation indicator brRecommendedIBS/CBS operation type (supply location). Default 100301. Code list
responsavel retencaoWhen ISS is withheld1 = withheld by the tomador (default), 2 = withheld by an intermediary.
pis cofins retidoOptionalPIS/COFINS/CSLL withholding code. When omitted, it is derived from the withheld taxes, and 0 (not withheld) is sent when none is withheld.
codigo tributacao municipalOptionalMunicipal taxation code, when the Prefeitura requires one.
Natureza operacaoOptionalNumeric nature-of-operation code, when the Prefeitura requires one.

cst

FieldDescription
ibs_cbs3-digit CST for IBS/CBS. Default 000 (Tributação integral).
pis_cofinsOptional CST for PIS/COFINS. Invalid codes are not sent.
📘

Defaults for IBS/CBS

When the IBS/CBS fields are not sent, Brinta applies CST 000, cClassTrib 000001 and operation indicator 100301. Only rely on these defaults when they really describe your operation.

taxes[]

taxes[].name

ValueDescription
ISSImposto Sobre Serviços. Without withholding_type, ISS is due by the supplier. With withholding_type: "withholding", it is ISS retido.
PISPrograma de Integração Social
COFINSContribuição para o Financiamento da Seguridade Social
CSLLContribuição Social sobre o Lucro Líquido
IRRF (or IR)Imposto de Renda Retido na Fonte
INSSContribuição previdenciária
CPContribuição previdenciária (CP)

taxes[].rate

Decimal, never a percentage: 0.02 = 2%.

taxes[].withholding_type

Use withholding on every tax the tomador withholds. Omit it for taxes paid by the supplier.

taxes[].adds_to_final_amount

false for all NFSe taxes.


Full Example Payload

{
  "supplier_company_id": "{{company_id}}",
  "invoice_type": "debit",
  "document_type": "services invoice",
  "invoice_date": "2026-10-01",
  "invoice_due_date": "2026-10-31",
  "currency": "BRL",
  "e_invoice": true,
  "invoice_external_id": "NFSE-100001",
  "additional_info": "Contrato 2026/015",
  "buyer": {
    "company": {
      "name": "CLIENT TECNOLOGIA LTDA.",
      "legal_name": "CLIENT TECNOLOGIA LTDA.",
      "type": "business",
      "email": "[email protected]",
      "tax_registrations": [
        { "number": "71175537000130", "type": "CNPJ", "level": "country", "location": "BR" },
        { "number": "12345678", "type": "IM", "level": "municipality", "location": "BR-SP" }
        // IM is optional
      ],
      "address": {
        "country": "BR",
        "address_line_1": "Alameda Santos 2200",
        // Street number at the end
        "address_line_2": "Conjunto 51",
        "neighborhood": "Cerqueira César",
        "city": "São Paulo",
        "state": "BR-SP",
        "postal_code": "01418200"
      }
    }
  },
  "items": [
    {
      "item_external_id": "SRV-001",
      "name": "Digital Services",
      "description": "Licença de software - outubro/2026",
      "amount": 2500,
      "categories": [
        { "code": "6491", "list": "cityServiceCode" },
        // Municipal service code from the Prefeitura
        { "code": "118012200", "list": "nbs code" },
        // NBS, 9 digits without dots
        { "code": "000001", "list": "cClassTrib" },
        { "code": "100301", "list": "operation indicator br" }
      ],
      "cst": {
        "ibs_cbs": "000"
      },
      "taxes": [
        { "name": "ISS", "rate": 0.02, "rate_type": "percentage", "amount": 50, "adds_to_final_amount": false },
        // ISS due by the supplier: no withholding_type
        { "name": "IRRF", "rate": 0.015, "rate_type": "percentage", "amount": 37.5, "adds_to_final_amount": false, "withholding_type": "withholding" },
        { "name": "PIS", "rate": 0.0065, "rate_type": "percentage", "amount": 16.25, "adds_to_final_amount": false, "withholding_type": "withholding" },
        { "name": "COFINS", "rate": 0.03, "rate_type": "percentage", "amount": 75, "adds_to_final_amount": false, "withholding_type": "withholding" },
        { "name": "CSLL", "rate": 0.01, "rate_type": "percentage", "amount": 25, "adds_to_final_amount": false, "withholding_type": "withholding" }
        // Taxes withheld by the tomador
      ]
    }
  ]
}

Common Mistakes

MistakeWhat happensFix
Codes sent on the second or later itemThey are ignored, and the defaults or the first item's codes are usedPut all classification codes on items[0], or issue one NFSe per service
NBS sent with dots (1.1801.22.00)The authority rejects the codeSend the 9 digits without dots: "118012200"
Street number in address_line_2 or in the middle of address_line_1The number is sent as SNEnd address_line_1 with the number
Rate sent as a percentage (2)Tax is calculated as 200%Send decimals: 0.02
Withheld tax without withholding_typeTax is treated as due by the supplierAdd "withholding_type": "withholding"
Supplier municipality not supportedThe NFSe cannot be issuedCheck the Prefeituras list
Real-estate rental issued as a regular NFSeRejected for missing property dataFollow Services Invoice for Rental

Did this page help you?