PHPackages                             dpsoft/zibal - 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. dpsoft/zibal

ActiveLibrary[Payment Processing](/categories/payments)

dpsoft/zibal
============

Zibal online payment - درگاه پرداخت آسان پرداخت به زبان PHP

v2.0(4y ago)31.4k—0%1MITPHPPHP ^7.1 || ^8.0CI failing

Since Jul 7Pushed 4y ago1 watchersCompare

[ Source](https://github.com/dpsoft-official/zibal)[ Packagist](https://packagist.org/packages/dpsoft/zibal)[ Docs](https://github.com/dpsoft/zibal)[ RSS](/packages/dpsoft-zibal/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (2)Dependencies (2)Versions (3)Used By (1)

Zibal online payment - درگاه پرداخت Zibal به زبان PHP
=====================================================

[](#zibal-online-payment---درگاه-پرداخت-zibal-به-زبان-php)

[![Latest Version on Packagist](https://camo.githubusercontent.com/25fe13246804b514a87db7847c035fcb646a417483617dd1df6b7bd2b92d0b56/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6470736f66742f7a6962616c2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/dpsoft/zibal)[![Total Downloads](https://camo.githubusercontent.com/e7064c92c99023690c0cbad92af003b50495dce543b48ad0f2928ba1f0b127b5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6470736f66742f7a6962616c2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/dpsoft/zibal)

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

[](#installation)

You can install the package via composer:

```
composer require dpsoft/zibal
```

Usage
-----

[](#usage)

copy `sample` directory to server. Open `request.php` in browser and bala balah ...

### Request

[](#request)

```
try {
    $zibal = new \Dpsoft\Zibal\Zibal($merchant);
    $result = $zibal->request($callbackUrl,$amount);
    //save amount and invoice id to forther use
    $_SESSION['amount']=$amount;
    $_SESSION['token']=$result['token'];

    $zibal->redirectToBank();
    exit();
}catch (Throwable $exception){
    echo $exception->getMessage();
}
```

### Response

[](#response)

```
try {
    $zibal = new \Dpsoft\Zibal\Zibal($merchant);
    $result = $zibal->verify($_SESSION['amount'],$_SESSION['token']);
    //save result. The keys are: card_number,transaction_id and token for example $result['token']
    echo "Successfull transaction.";
}catch (Throwable $exception){
    echo "Error in transaction: ";
}
```

### Testing

[](#testing)

```
composer test
```

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Dpsoft](https://github.com/dpsoft)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity61

Established project with proven stability

 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 ~515 days

Total

2

Last Release

1626d ago

Major Versions

v1.0 → v2.02021-12-05

PHP version history (2 changes)v1.0PHP ^7.1

v2.0PHP ^7.1 || ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/d8ce9db5e47c9f42b80ea1102230d26603ed743596b579011934e7b67b37811d?d=identicon)[dpsoft-ir](/maintainers/dpsoft-ir)

---

Top Contributors

[![SadeghPM](https://avatars.githubusercontent.com/u/9298600?v=4)](https://github.com/SadeghPM "SadeghPM (7 commits)")

---

Tags

zibaldpsoft

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/dpsoft-zibal/health.svg)

```
[![Health](https://phpackages.com/badges/dpsoft-zibal/health.svg)](https://phpackages.com/packages/dpsoft-zibal)
```

###  Alternatives

[2checkout/2checkout-php

2Checkout PHP Library

83740.3k2](/packages/2checkout-2checkout-php)[omalizadeh/laravel-multi-payment

A driver-based laravel package for online payments via multiple gateways

491.1k](/packages/omalizadeh-laravel-multi-payment)[parsisolution/gateway

A Laravel package for connecting to all Iraninan payment gateways

231.7k](/packages/parsisolution-gateway)

PHPackages © 2026

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