PHPackages                             piatkowski/przelewy24-php - 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. piatkowski/przelewy24-php

ActiveLibrary[API Development](/categories/api)

piatkowski/przelewy24-php
=========================

Simple class to use P24 REST API

0.0.1(3y ago)61.7k↓50%[1 issues](https://github.com/piatkowski/przelewy24-php/issues)MITPHPPHP &gt;=7.4

Since Jan 18Pushed 3y ago1 watchersCompare

[ Source](https://github.com/piatkowski/przelewy24-php)[ Packagist](https://packagist.org/packages/piatkowski/przelewy24-php)[ RSS](/packages/piatkowski-przelewy24-php/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)DependenciesVersions (3)Used By (0)

PHP Class - Przelewy24 REST API
===============================

[](#php-class---przelewy24-rest-api)

Simple PHP class to implement Przelewy24 payments using new REST API.

Prerequisities
--------------

[](#prerequisities)

- PHP &gt;= 7.4
- cURL extension
- no other dependencies...

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

[](#installation)

```
composer require piatkowski/przelewy24-php
```

Example of usage
----------------

[](#example-of-usage)

### Create new instance of the P24 Client with authorization data

[](#create-new-instance-of-the-p24-client-with-authorization-data)

```
$client = new \Przelewy24\Przelewy24( [
	'merchantId' => '...',
	'posId'      => '...',
	'crc'        => '...',
	'reportKey'  => '...', // API KEY
	'sandbox'    => true,
] );
```

Register new transaction. This is minimum required options. You can use pass more parameters (from P24 Docs)

```
$transaction = $client->transaction( [
	'sessionId'   => '...',
	'amount'      => '...',
	'currency'    => 'PLN',
	'description' => '...',
	'email'       => '...',
	'urlReturn'   => '...',
	'urlStatus'   => '...'
] );
```

Get Payment URL

```
$transaction->getRedirectUrl();
```

### Create endpoint to receive notification from P24 API

[](#create-endpoint-to-receive-notification-from-p24-api)

```
// get incoming data from php://input
$notification = $client->receiveNotification();
```

or

```
// create Notification object from raw data
$notification = $client->createNotification([
    'sessionId'     => '...',
    'amount'        => '...',
    'orderId'       => '...',
    'currency'      => '...', // optional, default: PLN
]);
```

You can now verify transaction passing Notification object and get API response data

```
$response   = $client->verify( $notification );
$status     = $response->getStatus();   //HTTP Status Code
$data       = $response->getData();     //Response data object
```

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance17

Infrequent updates — may be unmaintained

Popularity25

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 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

Every ~0 days

Total

2

Last Release

1207d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/2012651?v=4)[Krzysztof Piątkowski](/maintainers/piatkowski)[@piatkowski](https://github.com/piatkowski)

---

Top Contributors

[![piatkowski](https://avatars.githubusercontent.com/u/2012651?v=4)](https://github.com/piatkowski "piatkowski (6 commits)")

### Embed Badge

![Health badge](/badges/piatkowski-przelewy24-php/health.svg)

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

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M478](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M271](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M454](/packages/google-gax)

PHPackages © 2026

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