PHPackages                             meshgroup/megafon-notification-channel - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. meshgroup/megafon-notification-channel

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

meshgroup/megafon-notification-channel
======================================

v1.0.8(3y ago)039MITPHPPHP &gt;=5.6.4

Since Apr 8Pushed 3y agoCompare

[ Source](https://github.com/Nolikzero/megafone-api)[ Packagist](https://packagist.org/packages/meshgroup/megafon-notification-channel)[ RSS](/packages/meshgroup-megafon-notification-channel/feed)WikiDiscussions main Synced today

READMEChangelog (1)Dependencies (4)Versions (9)Used By (0)

Megafon notifications channel for Laravel 5.3+
==============================================

[](#megafon-notifications-channel-for-laravel-53)

This package makes it easy to send notifications using megafon with Laravel 5.3+.

Contents
--------

[](#contents)

- [Installation](#installation)
    - [Setting up the Megafon service](#setting-up-the-megafon-service)
- [Usage](#usage)
    - [Available Message methods](#available-message-methods)
- [Changelog](#changelog)
- [Testing](#testing)
- [Security](#security)
- [Contributing](#contributing)
- [Credits](#credits)
- [License](#license)

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

[](#installation)

You can install the package via composer:

```
composer require meshgroup/megafon-notification-channel
```

Then you must install the service provider:

```
// config/app.php
'providers' => [
    ...
    Meshgroup\Megafon\MegafonServiceProvider::class,
],
```

### Setting up the Megafon service

[](#setting-up-the-megafon-service)

Add your Megafon login, password and default sender name (or phone number) to your `config/services.php`:

```
// config/services.php
...
'megafon' => [
    'login'  => env('MEGAFON_LOGIN'),
    'password' => env('MEGAFON_PASSWORD'),
    'sender' => 'John_Doe'
],
...
```

> If you want use other host than `https://a2p-api.megalabs.ru/`, you MUST set custom host WITH trailing slash.

```
// .env
...
MEGAFON_HOST=https://a2p-api.megalabs.ru/
...

```

```
// config/services.php
...
'megafon' => [
    ...
    'host' => env('MEGAFON_HOST'),
    ...
],
...
```

Usage
-----

[](#usage)

You can use the channel in your `via()` method inside the notification:

```
use Illuminate\Notifications\Notification;
use Meshgroup\Megafon\MegafonMessage;
use Meshgroup\Megafon\MegafonChannel;

class AccountApproved extends Notification
{
    public function via($notifiable)
    {
        return [MegafonChannel::class];
    }

    public function toMegafon($notifiable)
    {
        return MegafonMessage::create("Task #{$notifiable->id} is complete!");
    }
}
```

In your notifiable model, make sure to include a `routeNotificationForMegafon()` method, which returns a phone number or an array of phone numbers.

```
public function routeNotificationForMegafon()
{
    return $this->phone;
}
```

### Available methods

[](#available-methods)

`from()`: Sets the sender's name or phone number.

`content()`: Set a content of the notification message.

`sendAt()`: Set a time for scheduling the notification message.

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Testing
-------

[](#testing)

```
$ composer test
```

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 71.4% 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 ~16 days

Recently: every ~28 days

Total

8

Last Release

1435d ago

Major Versions

v0.0.1 → v1.0.02022-04-08

### Community

Maintainers

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

---

Top Contributors

[![dnbh](https://avatars.githubusercontent.com/u/47099983?v=4)](https://github.com/dnbh "dnbh (5 commits)")[![Nolikzero](https://avatars.githubusercontent.com/u/14997927?v=4)](https://github.com/Nolikzero "Nolikzero (2 commits)")

### Embed Badge

![Health badge](/badges/meshgroup-megafon-notification-channel/health.svg)

```
[![Health](https://phpackages.com/badges/meshgroup-megafon-notification-channel/health.svg)](https://phpackages.com/packages/meshgroup-megafon-notification-channel)
```

###  Alternatives

[craftcms/cms

Craft CMS

3.6k3.6M3.0k](/packages/craftcms-cms)[spatie/laravel-health

Monitor the health of a Laravel application

87512.0M161](/packages/spatie-laravel-health)[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9762.4M129](/packages/roots-acorn)[illuminate/notifications

The Illuminate Notifications package.

513.1M1.1k](/packages/illuminate-notifications)[laravel-notification-channels/discord

Laravel notification driver for Discord.

2401.4M16](/packages/laravel-notification-channels-discord)[laravel-notification-channels/expo

Expo Notifications Channel for Laravel

67628.6k1](/packages/laravel-notification-channels-expo)

PHPackages © 2026

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