PHPackages                             hubleto/pay-by-square-encoder - 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. [Payment Processing](/categories/payments)
4. /
5. hubleto/pay-by-square-encoder

ActiveLibrary[Payment Processing](/categories/payments)

hubleto/pay-by-square-encoder
=============================

Encoder for Pay By Square

1.0(4mo ago)0167↓31.3%11MITPHP

Since Feb 11Pushed 4mo agoCompare

[ Source](https://github.com/hubleto/pay-by-square-encoder)[ Packagist](https://packagist.org/packages/hubleto/pay-by-square-encoder)[ Docs](https://www.hubleto.com)[ RSS](/packages/hubleto-pay-by-square-encoder/feed)WikiDiscussions main Synced today

READMEChangelog (1)DependenciesVersions (2)Used By (1)

pay-by-square-encoder
=====================

[](#pay-by-square-encoder)

Generator of QR codes for pay by square

Introduction
------------

[](#introduction)

PAY by square is a Slovak banking standard for encoding payment info into QR codes. It uses LZMA-compressed XML/XSD data, Base32 encoding, and CRC32 checksums, formatted as QR Code 2005. The code contains SEPA-compliant details, including up to 5 IBAN/BIC accounts, amounts, and, crucially, variable symbols.

For detailed specification visit [https://www.sbaonline.sk/wp-content/uploads/2020/03/pay-by-square-specifications-1\_1\_0.pdf](https://www.sbaonline.sk/wp-content/uploads/2020/03/pay-by-square-specifications-1_1_0.pdf)

About
-----

[](#about)

This library encodes payment information into a Pay-By-Square compliant string. It uses external LZMA compression utility (the 'xz').

Use the string generated by the encoder as the input to your favourite QR code generator library.

### Linux

[](#linux)

Linux by default contains a `xz` utility, typicaly located in `/usr/bin/xz`.

### Windows

[](#windows)

You will need the `xz.exe` utility which can be downloaded e.g. from [https://sourceforge.net/projects/xz-for-windows/files/XZ-5.2.1\_Win32%28static%29.zip/download](https://sourceforge.net/projects/xz-for-windows/files/XZ-5.2.1_Win32%28static%29.zip/download).

Install
-------

[](#install)

```
composer require hubleto/pay-by-square-qr-code

```

Usage
-----

[](#usage)

```
$pbsEnc = new \Hubleto\Utilities\PayBySquareEncoder();
$pbsEnc->setAmount(9.99);
$pbsEnc->setIban("SK99 0000 0012 3456 7890");
$pbsEnc->setBic("ABCDEFGH");
$pbsEnc->setBeneficiaryName("The Beneficiary Ltd.");
$pbsEnc->setVariableSymbol("2020123456");
$pbsEnc->setConstantSymbol("0308");
$pbsEnc->setSpecificSymbol("1000");
$pbsEnc->setNote("Payment for the services");

$pbsEnc->setXzPath("/usr/bin/xz"); // set the path to your XZ utility
$encoded = $pbsEnc->getEncodedString();

// Now, use here the `$encoded` in your favourite QR code generator library.
```

###  Health Score

36

—

LowBetter than 79% of packages

Maintenance76

Regular maintenance activity

Popularity15

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity34

Early-stage or recently created project

 Bus Factor1

Top contributor holds 85.7% 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

143d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/394c74eefe13d2cf99097d4f4a80c2c8dd1e69e311ffa43175164efbdcc77cd0?d=identicon)[wai-blue](/maintainers/wai-blue)

---

Top Contributors

[![wai-blue](https://avatars.githubusercontent.com/u/88132073?v=4)](https://github.com/wai-blue "wai-blue (6 commits)")[![hlsxx](https://avatars.githubusercontent.com/u/82389799?v=4)](https://github.com/hlsxx "hlsxx (1 commits)")

---

Tags

crmapplicationERPhubhubleto

### Embed Badge

![Health badge](/badges/hubleto-pay-by-square-encoder/health.svg)

```
[![Health](https://phpackages.com/badges/hubleto-pay-by-square-encoder/health.svg)](https://phpackages.com/packages/hubleto-pay-by-square-encoder)
```

###  Alternatives

[dolibarr/dolibarr

Dolibarr ERP &amp; CRM is a modern and easy to use web software to manage your business

7.4k5.2k](/packages/dolibarr-dolibarr)[lavalite/cms

Lavalite - The Laravel CMS.

2.9k56.4k](/packages/lavalite-cms)[hubleto/erp

Business Application Hub. Opensource ERP and CRM.

391.7k6](/packages/hubleto-erp)[andrewdwallo/filament-companies

A comprehensive Laravel authentication and authorization system designed for Filament, focusing on multi-tenant company management.

35156.4k2](/packages/andrewdwallo-filament-companies)

PHPackages © 2026

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