PHPackages                             fromni-oy/notifications-sdk - 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. fromni-oy/notifications-sdk

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

fromni-oy/notifications-sdk
===========================

NOTIFICATIONS SDK

v1.0.0(7mo ago)00MITPHPPHP ^7.4 || ^8.0 || ^8.1

Since Sep 19Pushed 7mo agoCompare

[ Source](https://github.com/Fromni-oy/notifications-sdk)[ Packagist](https://packagist.org/packages/fromni-oy/notifications-sdk)[ Docs](https://github.com/fromni-oy/notifications-sdk)[ RSS](/packages/fromni-oy-notifications-sdk/feed)WikiDiscussions master Synced 1mo ago

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

NOTIFICATIONS SDK
=================

[](#notifications-sdk)

[![Latest Version on Packagist](https://camo.githubusercontent.com/26e262fd7fecc7b21fa5113f29131f2dfbda644da51d66ba6f6c158cbe6ba3db/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f66726f6d6e692d6f792f6e6f74696669636174696f6e732d73646b2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/fromni-oy/notifications-sdk)[![Tests](https://camo.githubusercontent.com/a651404de203c73d08add93c2bd8fa2167f9dbf49d1af57d7c34377c4b9d767e/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f66726f6d6e692d6f792f6e6f74696669636174696f6e732d73646b2f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/fromni-oy/notifications-sdk/actions/workflows/run-tests.yml)[![Total Downloads](https://camo.githubusercontent.com/f96374a751c3793dac450729317b9236b00848b70481e563f7d902384c4033af/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f66726f6d6e692d6f792f6e6f74696669636174696f6e732d73646b2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/fromni-oy/notifications-sdk)

Library for sending messages via services notifications.fromni.com

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

[](#installation)

You can install the package using composer:

```
composer require fromni-oy/notifications-sdk
```

Usage
-----

[](#usage)

The sandbox mode is activated with its own token before creating a client:

```
$sandboxApiKey = '...';
$sandbox = Nexus\Message\Sdk\Client::enableSandbox($sandboxApiKey);
```

Checking the sandbox activity:

```
$activated = $sandbox->active();
```

Disable the sandbox:

```
Nexus\Message\Sdk\Client::disableSandbox();
```

Creating a client with an access key:

```
use Nexus\Message\Sdk\Exceptions\CollectionException;
use Nexus\Message\Sdk\Exceptions\ConnectionException;
use Nexus\Message\Sdk\Exceptions\HttpInvalidArgumentException;
use Nexus\Message\Sdk\Exceptions\LowBalanceException;
use Nexus\Message\Sdk\Exceptions\TokenException;
use Nexus\Message\Sdk\Exceptions\ViolationIntegrityEntityException;

try {
    $apiKey = '...';
    $client = new Nexus\Message\Sdk\Client($apiKey);
    $login = $client->getLogin();
} catch (CollectionException $exception) {
    echo 'CollectionException: ' . $exception->getMessage();
} catch (ConnectionException $exception) {
    echo 'ConnectionException: ' . $exception->getMessage();
} catch (HttpInvalidArgumentException $exception) {
    echo 'HttpInvalidArgumentException: ' . $exception->getMessage();
} catch (TokenException $exception) {
    echo 'TokenException: ' . $exception->getMessage();
} catch (LowBalanceException $exception) {
    echo 'LowBalanceException: ' . $exception->getMessage();
} catch (ViolationIntegrityEntityException $exception) {
    echo 'ViolationIntegrityEntityException: ' . $exception->getMessage();
} catch (\InvalidArgumentException $exception) {
    echo 'InvalidArgumentException: ' . $exception->getMessage();
} catch (\Exception $exception) {
    echo 'Exception: ' . $exception->getMessage();
}
```

Balance:

```
$balance = $client->getBalance();
```

Checking phone numbers:

```
$collection = $client->checkPhones(['358451086128', '...']);

if ($collection->count() > 0) {
    foreach ($collection as $phone) {
        $checked = $phone->checked();
        $valid = $phone->valid();
        $phoneNumber = $phone->getNumber();
        $country = $phone->getCountry();
        $operator = $phone->getOperator();
        $regionId = $phone->getRegionId();
        $regionName = $phone->getRegionName();
        $timezone = $phone->getTimezone();
    }
}
```

List of senders names:

```
$collection = $client->getSenders();

if ($collection->count() > 0) {
    foreach ($collection as $sender) {
        $checked = $sender->checked();
        $senderName = $sender->getSender();
        $channel = $sender->getChannel();
    }
}
```

### Sending messages:

[](#sending-messages)

Before sending messages, you need to create metadata for working with statuses:

```
$reportUrl = 'https://example.com/report'; // Message statuses and sending errors will be sent to this URL.
$replyUrl = 'https://example.com/reply'; // Responses to messages will be sent to this URL if the channel supports this functionality.
$metadata = Nexus\Message\Sdk\ValueObject\MessageMetadata::create($reportUrl, $replyUrl, 600);
```

Sending confirmation codes to Telegram:

```
$client->sendTelegram(['358451086128', '...'], 'Message text', $metadata);
```

Sending via Viber channel:

```
$client->sendViber(['358451086128', '...'], 'Message text', $metadata);
```

Sending via SMS channel:

```
$client->sendSms(['358451086128', '...'], 'Message text', $metadata);
```

Sending by default channels:

```
$client->sendSimple(['358451086128', '...'], 'Message text', $metadata);
```

Omnichannel sending:

```
$channels = ['telegram', 'viber', 'sms']; // The order of channels to send
$client->sendHybrid(['358451086128', '...'], 'Message text', $channels, $metadata);
```

### Handling statuses, reply and errors:

[](#handling-statuses-reply-and-errors)

Handling statuses and errors:

```
$post = file_get_contents('php://input');
$handler = Nexus\Message\Sdk\Client::statusHandler($post);
$error = $handler->getError();
$messageId = $handler->getEntityId();
$status = $handler->getStatus();
$channel = $handler->getChannel();
```

Reply processing:

```
$post = file_get_contents('php://input');
$handler = Nexus\Message\Sdk\Client::replyHandler($post);
$messageId = $handler->getMessageId();
$customId = $handler->getCustomId();
$text = $handler->getText();
$date = $handler->getDate();
```

Testing
-------

[](#testing)

```
phpunit --coverage-text
```

History of changes
------------------

[](#history-of-changes)

See [CHANGELOG](CHANGELOG.md) for more information about what has changed recently.

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance66

Regular maintenance activity

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 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

Unknown

Total

1

Last Release

232d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/5876dbdf984e9295bda35627be976ce03a36ea3a694c4ef2bd48bbd89ec56987?d=identicon)[ronlx](/maintainers/ronlx)

---

Top Contributors

[![bot](https://avatars.githubusercontent.com/u/58210622?v=4)](https://github.com/bot "bot (3 commits)")

---

Tags

fromni-oynotifications-sdk

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/fromni-oy-notifications-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/fromni-oy-notifications-sdk/health.svg)](https://phpackages.com/packages/fromni-oy-notifications-sdk)
```

###  Alternatives

[s-ichikawa/laravel-sendgrid-driver

This library adds a 'sendgrid' mail driver to Laravel.

4139.3M1](/packages/s-ichikawa-laravel-sendgrid-driver)[laravel-notification-channels/microsoft-teams

A Laravel Notification Channel for Microsoft Teams

1603.0M7](/packages/laravel-notification-channels-microsoft-teams)[laravel-notification-channels/discord

Laravel notification driver for Discord.

2371.3M11](/packages/laravel-notification-channels-discord)[guanguans/notify

Push notification SDK(AnPush、Bark、Chanify、DingTalk、Discord、Gitter、GoogleChat、IGot、Lark、Mattermost、MicrosoftTeams、NowPush、Ntfy、Push、Pushback、PushBullet、PushDeer、PushMe、Pushover、PushPlus、QQ、RocketChat、ServerChan、ShowdocPush、SimplePush、Slack、Telegram、WeWork、WPush、XiZhi、YiFengChuanHua、ZohoCliq、ZohoCliqWebHook、Zulip).

682104.9k7](/packages/guanguans-notify)[tzsk/sms

A robust and unified SMS gateway integration package for Laravel, supporting multiple providers.

320244.3k6](/packages/tzsk-sms)[pusher/pusher-push-notifications

562.5M9](/packages/pusher-pusher-push-notifications)

PHPackages © 2026

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