Skip to main content
Skip table of contents

Inserir NF-e Recebida

POST /api/NFeRecepcao/recepcao 

Através da API é possível inserir na plataforma as notas fiscais recebidas externamente. 

O layout do string de “Conteudo” deve seguir o layout padrão conforme documentação fornecida pela Secretaria de Fazenda (Sefaz), através dos Schemas XSD distribuídos com os pacotes de liberação (PL).

A seguir, link para arquivo tipo XML NF-e: Portal da Nota Fiscal Eletrônica 

Após acessar o portal, clique no menu Documentos, e na opção Esquemas XML. 

Exemplo de Requisição: 

CODE
{ 

  "Header": { 

    "CNPJEmpresa": "99999999999999", 

    "TipoEnvio": 1 

  }, 

  "Body": { 

    "Conteudo": "{\"NFe\":{\"infNFe\":{\"ide\":{\"cUF\":\"41\",\"cNF\":\"9999999\",\"natOp\":\"VENDA\",\"mod\":\"55\",\"serie\":\"1\",\"nNF\":\"9999999\",\"dhEmi\":\"2022-08-02T14:58:47-03:00\",\"dhSaiEnt\":\"2022-08-02T14:58:47-03:00\",\"tpNF\":\"1\",\"idDest\":\"1\",\"cMunFG\":\"999999999\",\"tpImp\":\"1\",\"tpEmis\":\"1\",\"cDV\":\"7\",\"tpAmb\":\"1\",\"finNFe\":\"1\",\"indFinal\":\"0\",\"indPres\":\"2\",\"indIntermed\":\"0\",\"procEmi\":\"0\",\"verProc\":\"2021.5.1\"},\"emit\":{\"CNPJ\":\"99999999999\",\"xNome\":\"Razao Social\",\"xFant\":\"Nome Fantasia\",\"enderEmit\":{\"xLgr\":\"LOGRADOURO\",\"nro\":\"0\",\"xBairro\":\"ZONA SUBURBANA\",\"cMun\":\"9999999999999999\",\"xMun\":\"CIDADE\",\"UF\":\"UF\",\"CEP\":\"9999999\",\"cPais\":\"1058\",\"xPais\":\"BRASIL\",\"fone\":\"9999999999\"},\"IE\":\"99999999999999\",\"CRT\":\"3\"},\"dest\":{\"CNPJ\":\"9999999999999\",\"xNome\":\"DESTINATARIO\",\"enderDest\":{\"xLgr\":\"LOGRADOURO\",\"nro\":\"999\",\"xBairro\":\"BAIRRO\",\"cMun\":\"999999999\",\"xMun\":\"CIDADE\",\"UF\":\"UF\",\"CEP\":\"999999999\",\"cPais\":\"1058\",\"xPais\":\"BRASIL\",\"fone\":\"99999999999\"},\"indIEDest\":\"1\",\"IE\":\"999999999999\",\"email\":\"EMAIL@EMAIL.COM\"},\"det\":{\"prod\":{\"cProd\":\"1111-0\",\"cEAN\":\"999999999999999\",\"xProd\":\"PRODUTO\",\"NCM\":\"99999999999\",\"CEST\":\"99999999\",\"cBenef\":\"999999999\",\"CFOP\":\"99999\",\"uCom\":\"KG\",\"qCom\":\"43.9800\",\"vUnCom\":\"16.8000\",\"vProd\":\"738.86\",\"cEANTrib\":\"999999999999\",\"uTrib\":\"KG\",\"qTrib\":\"43.9800\",\"vUnTrib\":\"16.8000\",\"indTot\":\"1\"},\"imposto\":{\"ICMS\":{\"ICMS20\":{\"orig\":\"0\",\"CST\":\"20\",\"modBC\":\"3\",\"pRedBC\":\"41.67\",\"vBC\":\"430.98\",\"pICMS\":\"12.0000\",\"vICMS\":\"51.72\"}},\"IPI\":{\"cEnq\":\"999\",\"IPITrib\":{\"CST\":\"99\",\"vBC\":\"0.00\",\"pIPI\":\"0.0000\",\"vIPI\":\"0.00\"}},\"PIS\":{\"PISNT\":{\"CST\":\"06\"}},\"COFINS\":{\"COFINSNT\":{\"CST\":\"06\"}}},\"infAdProd\":\"[*DT_PRD*]Qtde_aux=2 [*DT_PRD_FIM*]\",\"_nItem\":\"1\"},\"total\":{\"ICMSTot\":{\"vBC\":\"857.73\",\"vICMS\":\"102.93\",\"vICMSDeson\":\"0\",\"vFCP\":\"0.00\",\"vBCST\":\"0.00\",\"vST\":\"0.00\",\"vFCPST\":\"0.00\",\"vFCPSTRet\":\"0.00\",\"vProd\":\"1470.48\",\"vFrete\":\"0.00\",\"vSeg\":\"0.00\",\"vDesc\":\"0.00\",\"vII\":\"0.00\",\"vIPI\":\"0.00\",\"vIPIDevol\":\"0\",\"vPIS\":\"0.00\",\"vCOFINS\":\"0.00\",\"vOutro\":\"0.00\",\"vNF\":\"1470.48\"}},\"transp\":{\"modFrete\":\"0\",\"transporta\":{\"CNPJ\":\"999999999999\",\"xNome\":\"NOME\",\"IE\":\"9023732685\",\"xEnder\":\"ENDEREÇO\",\"xMun\":\"Ivaipora\",\"UF\":\"UF\"},\"veicTransp\":{\"placa\":\"ABC9999\",\"UF\":\"UF\"},\"vol\":{\"qVol\":\"5\",\"pesoL\":\"90.580\",\"pesoB\":\"93.595\"}},\"cobr\":{\"fat\":{\"nFat\":\"100.NE.001.99997\",\"vOrig\":\"1470.48\",\"vDesc\":\"0\",\"vLiq\":\"1470.48\"},\"dup\":{\"nDup\":\"001\",\"dVenc\":\"2022-09-01\",\"vDup\":\"1470.48\"}},\"pag\":{\"detPag\":{\"indPag\":\"1\",\"tPag\":\"16\",\"vPag\":\"1470.48\"}},\"infAdic\":{\"infCpl\":\"COMPLEMENTO\"},\"infRespTec\":{\"CNPJ\":\"9999999999999\",\"xContato\":\"CONTATO\",\"email\":\"EMAI@EMAIL.COM\",\"fone\":\"999999999999999\"},\"_Id\":\"NFe99999999999999999999999999999999999999999999\",\"_versao\":\"4.00\"},\"Signature\":{\"SignedInfo\":{\"CanonicalizationMethod\":{\"_Algorithm\":\"http://www.w3.org/TR/2001/REC-xml-c14n-20010315\"},\"SignatureMethod\":{\"_Algorithm\":\"http://www.w3.org/2000/09/xmldsig#rsa-sha1\"},\"Reference\":{\"Transforms\":{\"Transform\":[{\"_Algorithm\":\"http://www.w3.org/2000/09/xmldsig#enveloped-signature\"},{\"_Algorithm\":\"http://www.w3.org/TR/2001/REC-xml-c14n-20010315\"}]},\"DigestMethod\":{\"_Algorithm\":\"http://www.w3.org/2000/09/xmldsig#sha1\"},\"DigestValue\":\"wVGemHrYMvgigcyoBnnXe5EVrWQ=\",\"_URI\":\"#NFe41220804308017000161550010000765471004664067\"}},\"SignatureValue\":\"Tr8ixXSOQD3M6ODzQchY5saG30nONfwxHXADRZIEKWpoeIowW6E683XMIO+HzcdH+ D5uvjnXGN7//mEExPFNBh/6IaD1ZteV0DrXkQA=\"}},\"_xmlns\":\"http://www.w3.org/2000/09/xmldsig#\"}},\"protNFe\":{\"infProt\":{\"tpAmb\":\"1\",\"verAplic\":\"9999\",\"chNFe\":\"99999999999999999\",\"dhRecbto\":\"2022-08-02T14:59:46-03:00\",\"nProt\":\"99999999999\",\"digVal\":\"wVGemHrYMvgigcyoBnnXaaDe5EVrWQ=\",\"cStat\":\"100\",\"xMotivo\":\"Autorizado o uso da NF-e\",\"_Id\":\"ID141220181172746\"},\"_versao\":\"4.00\"},\"_xmlns\":\"http://www.portalfiscal.inf.br/nfe\",\"_versao\":\"4.00\"}" 

  } 

}

Exemplo de Retorno: 

CODE
{ 

    "tipoRetorno": 11, 

    "processamento": { 

        "message": "Documento enviado para processamento", 

        "protocolo": "0c7d6849-e5c5-46c5-a051-ae7a07cda92a" 

    } 

}

{{component-feedback-article}}

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.