PHPackages                             yarcode/yii2-free-kassa - 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. yarcode/yii2-free-kassa

ActiveYii2-extension[Payment Processing](/categories/payments)

yarcode/yii2-free-kassa
=======================

FreeKassa component for Yii2

0.13.1(7y ago)5512↓100%6[1 PRs](https://github.com/yarcode/yii2-free-kassa/pulls)MITPHPPHP &gt;=5.4.0

Since Feb 18Pushed 6y ago2 watchersCompare

[ Source](https://github.com/yarcode/yii2-free-kassa)[ Packagist](https://packagist.org/packages/yarcode/yii2-free-kassa)[ Docs](http://yiidreamteam.com/yii2/free-kassa)[ RSS](/packages/yarcode-yii2-free-kassa/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (7)Dependencies (2)Versions (8)Used By (0)

Free Kassa component for Yii2
=============================

[](#free-kassa-component-for-yii2)

Payment gateway and api client for [Free Kassa](http://www.free-kassa.ru) service.

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

[](#installation)

The preferred way to install this extension is through [composer](http://getcomposer.org/download/).

Either run

```
php composer.phar require --prefer-dist yarcode/yii2-free-kassa "~1.0"

```

or add

```
"yarcode/yii2-free-kassa": "~1.0"

```

to the `require` section of your composer.json.

Usage
-----

[](#usage)

### Component configuration

[](#component-configuration)

Configure `freeKassa` component in the `components` section of your application.

```
'freeKassa' => [
    'class' => '\yarcode\freekassa\Merchant',
    'merchantId' => 'YOUR_MERCHANT_ID',
    'merchantFormSecret' => 'SECRET_1',
    'checkDataSecret' => 'SECRET_2',
    'defaultCurrency' => 'DEFAULT_CURRENCY_ID',
    'defaultLanguage' => 'ru' // or 'en'
],

```

### Redirecting to the payment system

[](#redirecting-to-the-payment-system)

To redirect user to PerfectMoney site you need to create the page with RedirectForm widget. User will redirected right after page load.

```

```

### Gateway controller

[](#gateway-controller)

You will need to create controller that will handle result requests from PerfectMoney service. Sample controller code:

```
