PHPackages                             pay-now/paynow-php-sdk - 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. [API Development](/categories/api)
4. /
5. pay-now/paynow-php-sdk

ActiveLibrary[API Development](/categories/api)

pay-now/paynow-php-sdk
======================

PHP client library for accessing Paynow API

3.0.0(12mo ago)18193.9k↓12.1%12[7 issues](https://github.com/pay-now/paynow-php-sdk/issues)[1 PRs](https://github.com/pay-now/paynow-php-sdk/pulls)2MITPHPPHP &gt;=7.2

Since Sep 5Pushed 12mo ago2 watchersCompare

[ Source](https://github.com/pay-now/paynow-php-sdk)[ Packagist](https://packagist.org/packages/pay-now/paynow-php-sdk)[ Docs](https://www.paynow.pl)[ RSS](/packages/pay-now-paynow-php-sdk/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (14)Versions (38)Used By (2)

Paynow PHP SDK
==============

[](#paynow-php-sdk)

[![Build Status](https://camo.githubusercontent.com/9b290bc4807aceb14528fbb5f6c2d30199c320ed2ff29ab5b08730e09322d54f/68747470733a2f2f6170702e7472617669732d63692e636f6d2f7061792d6e6f772f7061796e6f772d7068702d73646b2e7376673f6272616e63683d6d6173746572)](https://travis-ci.com/pay-now/paynow-php-sdk)[![Latest Version](https://camo.githubusercontent.com/bc47fa28686420f4d7ac23d84a55e8642086c02fe379106d8e0e9cff690853d8/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f7061792d6e6f772f7061796e6f772d7068702d73646b2e737667)](https://github.com/pay-now/paynow-php-sdk/releases)[![Software License](https://camo.githubusercontent.com/074b89bca64d3edc93a1db6c7e3b1636b874540ba91d66367c0e5e354c56d0ea/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e737667)](LICENSE)[![Total Downloads](https://camo.githubusercontent.com/b2b90f33347e9ebf646e395c1c67bf494b5975a24bfe3629ef628d78e188647d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7061792d6e6f772f7061796e6f772d7068702d73646b)](https://packagist.org/packages/pay-now/paynow-php-sdk)

Paynow PHP Library provides access to Paynow API from Applications written in PHP language.

Requirements
------------

[](#requirements)

- PHP 7.2 or higher
- HTTP client implements `php-http/client-implementation`. For more information see the [packages list](https://packagist.org/providers/php-http/client-implementation).

Installation
------------

[](#installation)

### Composer

[](#composer)

Install the library using [Composer](https://getcomposer.org)

```
$ composer require pay-now/paynow-php-sdk
```

If you don't have HTTP client that implements PSR-18 you can use:

```
$ composer require pay-now/paynow-php-sdk nyholm/psr7 php-http/curl-client
```

Use autoloader

```
require_once('vendor/autoload.php');
```

Usage
-----

[](#usage)

Making a payment

```
use Paynow\Client;
use Paynow\Environment;
use Paynow\Exception\PaynowException;
use Paynow\Service\Payment;

$client = new Client('TestApiKey', 'TestSignatureKey', Environment::SANDBOX);
$orderReference = "success_1234567";
$idempotencyKey = uniqid($orderReference . '_');

$paymentData = [
    'amount' => '100',
    'currency' => 'PLN',
    'externalId' => $orderReference,
    'description' => 'Payment description',
    'buyer' => [
        'email' => 'customer@domain.com'
    ]
];

try {
    $payment = new Payment($client);
    $result = $payment->authorize($paymentData, $idempotencyKey);
} catch (PaynowException $exception) {
    // catch errors
}
```

Handling notification with current payment status

```
use Paynow\Notification;

$payload = trim(file_get_contents('php://input'));
$headers = getallheaders();
$notificationData = json_decode($payload, true);

try {
    new Notification('TestSignatureKey', $payload, $headers);
    // process notification with $notificationData
} catch (Exception $exception) {
    header('HTTP/1.1 400 Bad Request', true, 400);
}

header('HTTP/1.1 202 Accepted', true, 202);
```

Making a payment's refund

```
use Paynow\Client;
use Paynow\Environment;
use Paynow\Exception\PaynowException;
use Paynow\Service\Refund;

$client = new Client('TestApiKey', 'TestSignatureKey', Environment::SANDBOX);

try {
    $refund = new Refund($client);
    $result = $refund->create('YXZA-123-ABC-A01', uniqid(), 100);
} catch (PaynowException $exception) {
    // catch errors
}
```

Retrieving available payment methods

```
use Paynow\Client;
use Paynow\Environment;
use Paynow\Exception\PaynowException;
use Paynow\Service\Payment;

$client = new Client('TestApiKey', 'TestSignatureKey', Environment::SANDBOX);

try {
    $payment = new Payment($client);
    $paymentMethods = $payment->getPaymentMethods('PLN', 100);
    $availablePaymentMethods = $paymentMethods->getAll();
} catch (PaynowException $exception) {
    // catch errors
}
```

Documentation
-------------

[](#documentation)

See the [Paynow API documentation](https://docs.paynow.pl)

Support
-------

[](#support)

If you have any questions or issues, please contact our support at .

License
-------

[](#license)

MIT license. For more information see the [LICENSE file](LICENSE)

###  Health Score

47

—

FairBetter than 94% of packages

Maintenance42

Moderate activity, may be stable

Popularity45

Moderate usage in the ecosystem

Community22

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

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

Every ~80 days

Recently: every ~71 days

Total

27

Last Release

361d ago

Major Versions

1.0.6 → 2.0.02020-05-20

1.1.0 → 2.1.02021-02-25

2.4.4 → 3.0.02025-05-22

PHP version history (5 changes)v1.0.0PHP &gt;=5.4

1.0.3PHP ^5.6 || ~7.0

2.0.0PHP ^7.1

2.0.1PHP &gt;=7.1

2.4.0PHP &gt;=7.2

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/50012399?v=4)[melements](/maintainers/melements)[@melements](https://github.com/melements)

---

Top Contributors

[![mateusztwardowski](https://avatars.githubusercontent.com/u/78550177?v=4)](https://github.com/mateusztwardowski "mateusztwardowski (51 commits)")[![emilleszczak2](https://avatars.githubusercontent.com/u/2837751?v=4)](https://github.com/emilleszczak2 "emilleszczak2 (40 commits)")[![DeveloperMovecloser](https://avatars.githubusercontent.com/u/111508111?v=4)](https://github.com/DeveloperMovecloser "DeveloperMovecloser (8 commits)")[![Mateusz0lejnik](https://avatars.githubusercontent.com/u/54986535?v=4)](https://github.com/Mateusz0lejnik "Mateusz0lejnik (2 commits)")[![michalskladanowski](https://avatars.githubusercontent.com/u/59174285?v=4)](https://github.com/michalskladanowski "michalskladanowski (2 commits)")[![pperzyna](https://avatars.githubusercontent.com/u/25820587?v=4)](https://github.com/pperzyna "pperzyna (1 commits)")

---

Tags

paymentspaynowpaynow-apiapipayment processingmbankpaynow

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/pay-now-paynow-php-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/pay-now-paynow-php-sdk/health.svg)](https://phpackages.com/packages/pay-now-paynow-php-sdk)
```

###  Alternatives

[wordpress/php-ai-client

A provider agnostic PHP AI client SDK to communicate with any generative AI models of various capabilities using a uniform API.

26236.6k14](/packages/wordpress-php-ai-client)[getbrevo/brevo-php

Official Brevo provided RESTFul API V3 php library

963.1M35](/packages/getbrevo-brevo-php)[theodo-group/llphant

LLPhant is a library to help you build Generative AI applications.

1.5k311.5k5](/packages/theodo-group-llphant)[phpro/http-tools

HTTP tools for developing more consistent HTTP implementations.

28137.8k](/packages/phpro-http-tools)[dhope0000/lxd

PHP-based API wrapper for LXD REST API.

136.2k](/packages/dhope0000-lxd)[mozex/anthropic-php

Anthropic PHP is a supercharged community-maintained PHP API client that allows you to interact with Anthropic API.

46365.1k13](/packages/mozex-anthropic-php)

PHPackages © 2026

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