PHPackages                             mrprompt/silex-nfe - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. mrprompt/silex-nfe

ActiveLibrary

mrprompt/silex-nfe
==================

Geração de NF-e

3381PHP

Since Oct 22Pushed 9y agoCompare

[ Source](https://github.com/mrprompt/Silex-NFe)[ Packagist](https://packagist.org/packages/mrprompt/silex-nfe)[ RSS](/packages/mrprompt-silex-nfe/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Silex NFe.io Service Provider
=============================

[](#silex-nfeio-service-provider)

[![Build Status](https://camo.githubusercontent.com/58cc69960e1a22135932b8dc527fdab876b301aecf42b1fbb8b093896ef1b786/68747470733a2f2f7472617669732d63692e6f72672f53696c6578467269656e64732f4e46652e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/SilexFriends/NFe)[![Code Climate](https://camo.githubusercontent.com/346cc36286185125d9fb0b674accb02959a820dcde3607c67b8cd9fc444e5000/68747470733a2f2f636f6465636c696d6174652e636f6d2f6769746875622f53696c6578467269656e64732f4e46652f6261646765732f6770612e737667)](https://codeclimate.com/github/SilexFriends/NFe)[![Test Coverage](https://camo.githubusercontent.com/cff6a5fbc6ae2919a15dd29e2462a24a387588aa801131202300c52106755f5f/68747470733a2f2f636f6465636c696d6174652e636f6d2f6769746875622f53696c6578467269656e64732f4e46652f6261646765732f636f7665726167652e737667)](https://codeclimate.com/github/SilexFriends/NFe/coverage)[![Issue Count](https://camo.githubusercontent.com/8aa7e094f55ffffba81e08d24bd06f43523c30a0c96a663cb1146dad425d48d2/68747470733a2f2f636f6465636c696d6174652e636f6d2f6769746875622f53696c6578467269656e64732f4e46652f6261646765732f69737375655f636f756e742e737667)](https://codeclimate.com/github/SilexFriends/NFe)

NFe.io Client for Silex

\[x\] Generate NFe \[x\] Generate PDF \[x\] Generate XML

Install
-------

[](#install)

```
composer install mrprompt/silex-nfe

```

Use
---

[](#use)

```
use Silex\Application;
use SilexFriends\Nfe\Service;

$token   = getenv('NFE_TOKEN');
$company = getenv('NFE_COMPANY');

$app = new Application;
$app->register(new Service($token, $company));

// Create
$this->app['nfe.create']([
     // Código do serviço de acordo com o a cidade
     'cityServiceCode' => '2690',
     // Descrição dos serviços prestados
     'description' => 'TESTE EMISSAO',
     // Valor total do serviços
     'servicesAmount' => 0.01,
     // Dados do Tomador dos Serviços
     'borrower' => [
         // CNPJ ou CPF (opcional para tomadores no exterior)
         'federalTaxNumber' => 191,
         // Nome da pessoa física ou Razão Social da Empresa
         'name' => 'BANCO DO BRASIL SA',
         // Email para onde deverá ser enviado a nota fiscal
         'email' => 'seu@email.da.nota',
         // Endereço do tomador
         'address' => [
             // Código do pais com três letras
             'country' => 'BRA',
             // CEP do endereço (opcional para tomadores no exterior)
             'postalCode' => '70073901',
             // Logradouro
             'street' => 'Outros Quadra 1 Bloco G Lote 32',
             // Número (opcional)
             'number' => 'S/N',
             // Complemento (opcional)
             'additionalInformation' => 'QUADRA 01 BLOCO G',
             // Bairro
             'district' => 'Asa Sul',
             // Cidade é opcional para tomadores no exterior
             'city' => [
                 // Código do IBGE para a Cidade
                 'code' => '5300108',
                 // Nome da Cidade
                 'name' => 'Brasilia'
             ],
             // Sigla do estado (opcional para tomadores no exterior)
             'state' => 'DF'
         ]
     ]
 ]);

// Generate PDF from Existent NFe
$app['nfe.pdf']('570ea6a4dfd7bc0af4cb55b3');

// Generate XML from Existent NFe
$app['nfe.xml']('570ea6a4dfd7bc0af4cb55b3');

```

Test
----

[](#test)

Set environment variables:

- NFE\_TOKEN
- NFE\_COMPANY
- NFE\_ID

Run tests

```
./vendor/bin/phpunit

```

License
-------

[](#license)

MIT

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/9d08744966e0d5783569605da853ef945dadac0be0f613f2eba6a052861d937a?d=identicon)[mrprompt](/maintainers/mrprompt)

---

Top Contributors

[![mrprompt](https://avatars.githubusercontent.com/u/166088?v=4)](https://github.com/mrprompt "mrprompt (10 commits)")

### Embed Badge

![Health badge](/badges/mrprompt-silex-nfe/health.svg)

```
[![Health](https://phpackages.com/badges/mrprompt-silex-nfe/health.svg)](https://phpackages.com/packages/mrprompt-silex-nfe)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
