PHPackages                             oneawebmarketing/php-sepa - 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. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. oneawebmarketing/php-sepa

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

oneawebmarketing/php-sepa
=========================

PHP class to create German SEPA files (XML) for credit transfer and direct debit.

1.0.0(7mo ago)0408↓74%BSD-2-ClausePHPPHP ^7.0|^8.0|^8.1|^8.2|^8.3

Since Nov 8Pushed 7mo agoCompare

[ Source](https://github.com/1aWebmarketing/php-sepa)[ Packagist](https://packagist.org/packages/oneawebmarketing/php-sepa)[ Docs](https://github.com/ufozone/php-sepa/)[ RSS](/packages/oneawebmarketing-php-sepa/feed)WikiDiscussions main Synced 3w ago

READMEChangelogDependencies (2)Versions (2)Used By (0)

php-sepa
========

[](#php-sepa)

PHP class to creating SEPA files (XML) for credit transfers and direct debits in accordance with version 3.7 of the specification for remote data transmission between customer and bank according to the DFÜ agreement for the German banking industry.

The versions of the standard followed are:

- *pain.001.001.09\_GBIC\_4.xsd* for credit transfers
- *pain.008.001.08\_GBIC\_4.xsd* for direct debits

Always verify the generated files at your bank before using them in production!

License: BSD 2-Clause License

Example of using SEPA Credit Transfer
-------------------------------------

[](#example-of-using-sepa-credit-transfer)

```
$validatorFactory = new \ufozone\phpsepa\Sepa\Validator\Factory();

$sepa = new \ufozone\phpsepa\Sepa\CreditTransfer($validatorFactory);
$sepa->setInitiator('Max Mustermann'); // Einreicher
//$sepa->setId($msgId); // Nachrichtenreferenz

$payment = new \ufozone\phpsepa\Sepa\Payment($validatorFactory);
$payment->setPriority('HIGH'); // Prioritaet NORM oder HIGH
//$payment->setScope('INST'); // Echtzeitueberweisung
$payment->setAccount('Max Mustermann', 'DE02370501980001802057', 'COLSDE33'); // Auftraggaber
//$payment->setAccountCurrency($currency); // Kontowaehrung
//$payment->disableBatchBooking(); // deaktiviere Sammelbuchung
//$payment->setDate($date); // Faelligkeitsdatum

$transaction = new \ufozone\phpsepa\Sepa\Transaction($validatorFactory);
$transaction->setEndToEndId('R2017742-1')   // Transaktions-ID (End-to-End)
    ->setName('Karl Kümmel')                // Name des Zahlungspflichtigen
    ->setIban('DE02300209000106531065')     // IBAN des Zahlungspflichtigen
    ->setBic('CMCIDEDD')                    // BIC des Zahlungspflichtigen
    ->setAmount(123.45)                     // abzubuchender Betrag
    ->setPurpose('SALA')                    // (optional) Zahlungstyp
    ->setReference('Rechnung R2017742 vom 17.06.2017'); // Verwendungszweck (eine Zeile, max. 140 Zeichen))
$payment->addTransaction($transaction);

$transaction = new \ufozone\phpsepa\Sepa\Transaction($validatorFactory);
$transaction->setEndToEndId('R2017742-1')
    ->setName('Doris Dose')
    ->setIban('DE02500105170137075030')
    ->setAmount(234.56)
    ->setPurpose('SALA')
    ->setReference('Kinderfahrrad');
$payment->addTransaction($transaction);

$sepa->addPayment($payment);

$xml = new \ufozone\phpsepa\Sepa\Xml($sepa);
$xml->download('sepa.xml');
```

Example of using SEPA Direct Debit
----------------------------------

[](#example-of-using-sepa-direct-debit)

```
$validatorFactory = new \ufozone\phpsepa\Sepa\Validator\Factory();

$sepa = new \ufozone\phpsepa\Sepa\DirectDebit($validatorFactory);
$sepa->setInitiator('Max Mustermann'); // Einreicher
//$sepa->setId($msgId); // Nachrichtenreferenz

$payment = new \ufozone\phpsepa\Sepa\Payment($validatorFactory);
//$payment->setScope('CORE'); // Lastschriftart (CORE oder B2B)
$payment->setAccount('Max Mustermann', 'DE02370501980001802057', 'COLSDE33'); // Auftraggaber
//$payment->setAccountCurrency($currency); // Kontowaehrung
$payment->setCreditorId('DE98ZZZ09999999999'); // Glaeubigeridentifikationsnummer
//$payment->disableBatchBooking(); // deaktiviere Sammelbuchung
//$payment->setDate($date); // Gewuenschter Ausfuehrungstermin

$transaction = new \ufozone\phpsepa\Sepa\Transaction($validatorFactory);
$transaction->setEndToEndId('R2017742-1')   // Transaktions-ID (End-to-End)
    ->setName('Karl Kümmel')                // Name des Zahlungspflichtigen
    ->setIban('DE02300209000106531065')     // IBAN des Zahlungspflichtigen
    ->setBic('CMCIDEDD')                    // BIC des Zahlungspflichtigen
    ->setAmount(123.45)                     // abzubuchender Betrag
    ->setPurpose('SALA')                    // (optional) Zahlungstyp
    ->setMandateId('M20170704-200')         // Mandatsreferenz
    ->setMandateDate('2017-07-04')          // Mandatsdatum
    ->setReference('Rechnung R2017742 vom 17.06.2017'); // Verwendungszweck (eine Zeile, max. 140 Zeichen))
$payment->addTransaction($transaction);

$sepa->addPayment($payment);

$xml = new \ufozone\phpsepa\Sepa\Xml($sepa);
$xml->download('sepa.xml');
```

External Resources
------------------

[](#external-resources)

- [German specification for remote data transfer between customer and bank according to the DFÜ agreement "Specification of Data Formats"](https://www.ebics.de/de/datenformate)
- [ECB SEPA gateway page](https://www.ecb.europa.eu/paym/integration/retail/sepa/html/index.en.html)
- [ISO20022 Message Catalog](https://www.iso20022.org/full_catalogue.page)

###  Health Score

36

—

LowBetter than 79% of packages

Maintenance63

Regular maintenance activity

Popularity16

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity50

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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

227d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/72da5b2605871911fe98f985e4cf7b8967e48ffd6eb322e8c330baea8746257c?d=identicon)[1aWebmarketing](/maintainers/1aWebmarketing)

---

Top Contributors

[![mhomeister](https://avatars.githubusercontent.com/u/16844537?v=4)](https://github.com/mhomeister "mhomeister (1 commits)")

---

Tags

xmlsepaBanking

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/oneawebmarketing-php-sepa/health.svg)

```
[![Health](https://phpackages.com/badges/oneawebmarketing-php-sepa/health.svg)](https://phpackages.com/packages/oneawebmarketing-php-sepa)
```

###  Alternatives

[digitick/sepa-xml

Creates Single Euro Payments Area (SEPA) XML files for the Direct Debit and Credit Transfer operations.

2816.3M14](/packages/digitick-sepa-xml)[masterminds/html5

An HTML5 parser and serializer.

1.8k260.4M292](/packages/masterminds-html5)[abcaeffchen/sephpa

Generates SEPA files for credit transfers (pain.001.001.03, pain.001.002.03, pain.001.003.03, pain.001.001.09) and direct debit (pain.008.001.02, pain.008.002.02, pain.008.003.02, pain.008.001.08)

711.8M](/packages/abcaeffchen-sephpa)[dmitrirussu/php-sepa-xml-generator

Creates an XML file for a Single Euro Payments Area (SEPA) Direct Debit Payment.

5246.2k](/packages/dmitrirussu-php-sepa-xml-generator)[perryfaro/sepa

Creates an XML file for a Single Euro Payments Area (SEPA) Credit Transfer.

1149.7k](/packages/perryfaro-sepa)

PHPackages © 2026

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