PHPackages                             idvlab/laravel-yookassa - 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. idvlab/laravel-yookassa

ActiveProject[Payment Processing](/categories/payments)

idvlab/laravel-yookassa
=======================

Yookassa for Laravel

1.1.9(2y ago)1351[1 PRs](https://github.com/idvlab/laravel-yookassa/pulls)MITPHPPHP &gt;=8.2

Since Jun 14Pushed 2y agoCompare

[ Source](https://github.com/idvlab/laravel-yookassa)[ Packagist](https://packagist.org/packages/idvlab/laravel-yookassa)[ RSS](/packages/idvlab-laravel-yookassa/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (5)Dependencies (4)Versions (6)Used By (0)

YooKassa Laravel
================

[](#yookassa-laravel)

Installing
----------

[](#installing)

```
composer require idvlab/laravel-yookassa
```

```
php artisan vendor:publish --tag=yookassa.migrations
php artisan migrate
```

```
php artisan vendor:publish --tag=yookassa.config
```

```
php artisan vendor:publish --provider=idvLab\LaravelYookassa\YooKassaServiceProvider
```

```
// Facade
use idvLab\LaravelYookassa\Facades\YooKassaFacade;
$yookassaPayment = YookassaFacade::createPayment(10000, 'test payment');

// Service
$service = app(idvLab\LaravelYookassa\Services\PaymentService::class);
$yookassaPayment = $service->createPayment(10000, 'test payment');
```

To receive the request you need to add a URL

[![./assets/img.jpg](./assets/img.jpg)](./assets/img.jpg)

And subscribe to the event idvLab\\LaravelYookassa\\Events\\YookassaPaymentNotification

```
namespace App\Providers;
class EventServiceProvider extends ServiceProvider
...
    protected $listen = [
        YookassaPaymentNotification::class => [
        YookassaPaymentStatus::class
    ]
];
...
```

```
namespace App\Listeners;
class YookassaPaymentStatus implements ShouldQueue
...
public function handle(YookassaPaymentNotification $event): void
{
    if ($event->payment->status === PaymentStatus::SUCCEEDED->value) {
    }
}
```

### If you use doctrine, the entity is located in the Entities folder

[](#if-you-use-doctrine-the-entity-is-located-in-the-entities-folder)

### .env

[](#env)

```
YOOKASSA_SHOP_ID=
YOOKASSA_SECRET_KEY=
YOOKASSA_REDIRECT=
```

### Use notifications

[](#use-notifications)

```
        $yooKassa = new YooKassa([]);
        $paymentRepository = new PaymentRepository();
        $paymentService = new PaymentService($yooKassa, $paymentRepository);

        $requestBody = $request->all();
        if (!isset($requestBody['event'])) {
            throw new \Exception('event not found');
        }

        if (($requestBody['event'] === NotificationEventType::PAYMENT_SUCCEEDED)) {
            $notification = new NotificationSucceeded($requestBody);
        } elseif ($requestBody['event'] === NotificationEventType::PAYMENT_WAITING_FOR_CAPTURE) {
            $notification = new NotificationWaitingForCapture($requestBody);
        } else {
            $notification = new NotificationCanceled($requestBody);
        }

        $payment = $notification->getObject();
        $status = PaymentStatus::tryFrom($payment->getStatus());
        $paymentService->setStatus($payment->getId(), $status);
        $yooKassaPayment = $paymentService->findByPaymentId($payment->getId());
        YookassaPaymentNotification::dispatch($yooKassaPayment);

        return response()->json();
```

MIT License
===========

[](#mit-license)

Copyright (c) 2024 Vitaliy Edifanov

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

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

Total

5

Last Release

736d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7e14534937913a9f0c4507367377ebaadfe97f8752756e943abac2e87d044afb?d=identicon)[idv](/maintainers/idv)

### Embed Badge

![Health badge](/badges/idvlab-laravel-yookassa/health.svg)

```
[![Health](https://phpackages.com/badges/idvlab-laravel-yookassa/health.svg)](https://phpackages.com/packages/idvlab-laravel-yookassa)
```

###  Alternatives

[craftcms/cms

Craft CMS

3.6k3.6M3.1k](/packages/craftcms-cms)[illuminate/http

The Illuminate Http package.

11937.9M7.0k](/packages/illuminate-http)[spatie/laravel-export

Create a static site bundle from a Laravel app

674146.0k6](/packages/spatie-laravel-export)[sebdesign/laravel-viva-payments

A Laravel package for integrating the Viva Payments gateway

4851.0k](/packages/sebdesign-laravel-viva-payments)[simplestats-io/laravel-client

Server-side analytics for Laravel that follows the full funnel from visit to registration to payment, attributed to the channel that drove it. Revenue, MRR, churn and ad-spend profit (ROAS/CAC) per channel. GDPR compliant, ad-blocker proof.

5022.0k](/packages/simplestats-io-laravel-client)[fleetbase/core-api

Core Framework and Resources for Fleetbase API

1235.9k20](/packages/fleetbase-core-api)

PHPackages © 2026

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