PHPackages                             aristech/nimbasms - 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. [API Development](/categories/api)
4. /
5. aristech/nimbasms

ActiveLibrary[API Development](/categories/api)

aristech/nimbasms
=================

Laravel package for Nimba SMS API

1.1.0(1y ago)05MITPHPPHP ^8.1

Since Feb 15Pushed 1y ago1 watchersCompare

[ Source](https://github.com/AristechGn/NimbaSms-Laravel)[ Packagist](https://packagist.org/packages/aristech/nimbasms)[ RSS](/packages/aristech-nimbasms/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (6)Versions (4)Used By (0)

Nimba SMS Package for Laravel
=============================

[](#nimba-sms-package-for-laravel)

```
Signature:
·························································································································································
:$$$$$$$$$$$$$$$AAA$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$iiii$$$$$$$$$$$$$$$$TTTTTTTTTTTTTTTTTTTTTTT$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$hhhhhhh$$$$$$$$$$$$$:
:$$$$$$$$$$$$$$A:::A$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$i::::i$$$$$$$$$$$$$$$T:::::::::::::::::::::T$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$h:::::h$$$$$$$$$$$$$:
:$$$$$$$$$$$$$A:::::A$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$iiii$$$$$$$$$$$$$$$$T:::::::::::::::::::::T$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$h:::::h$$$$$$$$$$$$$:
:$$$$$$$$$$$$A:::::::A$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$T:::::TT:::::::TT:::::T$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$h:::::h$$$$$$$$$$$$$:
:$$$$$$$$$$$A:::::::::A$$$$$$$$$$rrrrr$$$rrrrrrrrr$$iiiiiii$$$$$ssssssssssTTTTTT$$T:::::T$$TTTTTTeeeeeeeeeeee$$$$$$$$cccccccccccccccch::::h$hhhhh$$$$$$$:
:$$$$$$$$$$A:::::A:::::A$$$$$$$$$r::::rrr:::::::::r$i:::::i$$$ss::::::::::s$$$$$$$T:::::T$$$$$$ee::::::::::::ee$$$$cc:::::::::::::::ch::::hh:::::hhh$$$$:
:$$$$$$$$$A:::::A$A:::::A$$$$$$$$r:::::::::::::::::r$i::::i$ss:::::::::::::s$$$$$$T:::::T$$$$$e::::::eeeee:::::ee$c:::::::::::::::::ch::::::::::::::hh$$:
:$$$$$$$$A:::::A$$$A:::::A$$$$$$$rr::::::rrrrr::::::ri::::i$s::::::ssss:::::s$$$$$T:::::T$$$$e::::::e$$$$$e:::::ec:::::::cccccc:::::ch:::::::hhh::::::h$:
:$$$$$$$A:::::A$$$$$A:::::A$$$$$$$r:::::r$$$$$r:::::ri::::i$$s:::::s$$ssssss$$$$$$T:::::T$$$$e:::::::eeeee::::::ec::::::c$$$$$ccccccch::::::h$$$h::::::h:
:$$$$$$A:::::AAAAAAAAA:::::A$$$$$$r:::::r$$$$$rrrrrrri::::i$$$$s::::::s$$$$$$$$$$$T:::::T$$$$e:::::::::::::::::e$c:::::c$$$$$$$$$$$$$h:::::h$$$$$h:::::h:
:$$$$$A:::::::::::::::::::::A$$$$$r:::::r$$$$$$$$$$$$i::::i$$$$$$$s::::::s$$$$$$$$T:::::T$$$$e::::::eeeeeeeeeee$$c:::::c$$$$$$$$$$$$$h:::::h$$$$$h:::::h:
:$$$$A:::::AAAAAAAAAAAAA:::::A$$$$r:::::r$$$$$$$$$$$$i::::i$ssssss$$$s:::::s$$$$$$T:::::T$$$$e:::::::e$$$$$$$$$$$c::::::c$$$$$ccccccch:::::h$$$$$h:::::h:
:$$$A:::::A$$$$$$$$$$$$$A:::::A$$$r:::::r$$$$$$$$$$$i::::::is:::::ssss::::::s$$$TT:::::::TT$$e::::::::e$$$$$$$$$$c:::::::cccccc:::::ch:::::h$$$$$h:::::h:
:$$A:::::A$$$$$$$$$$$$$$$A:::::A$$r:::::r$$$$$$$$$$$i::::::is::::::::::::::s$$$$T:::::::::T$$$e::::::::eeeeeeee$$$c:::::::::::::::::ch:::::h$$$$$h:::::h:
:$A:::::A$$$$$$$$$$$$$$$$$A:::::A$r:::::r$$$$$$$$$$$i::::::i$s:::::::::::ss$$$$$T:::::::::T$$$$ee:::::::::::::e$$$$cc:::::::::::::::ch:::::h$$$$$h:::::h:
:AAAAAAA$$$$$$$$$$$$$$$$$$$AAAAAAArrrrrrr$$$$$$$$$$$iiiiiiii$$sssssssssss$$$$$$$TTTTTTTTTTT$$$$$$eeeeeeeeeeeeee$$$$$$cccccccccccccccchhhhhhh$$$$$hhhhhhh:
:$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$:
:$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$:
:$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$:
:$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$:
·························································································································································
 _______   _______   ________   ______   __       __  ________  _______
/       \ /       \ /        | /      \ /  \     /  |/        |/       \
$$$$$$$  |$$$$$$$  |$$$$$$$$/ /$$$$$$  |$$  \   /$$ |$$$$$$$$/ $$$$$$$  |
$$ |  $$ |$$ |__$$ |$$ |__    $$ |__$$ |$$$  \ /$$$ |$$ |__    $$ |__$$ |
$$ |  $$ |$$    $$< $$    |   $$    $$ |$$$$  /$$$$ |$$    |   $$    $$<
$$ |  $$ |$$$$$$$  |$$$$$/    $$$$$$$$ |$$ $$ $$/$$ |$$$$$/    $$$$$$$  |
$$ |__$$ |$$ |  $$ |$$ |_____ $$ |  $$ |$$ |$$$/ $$ |$$ |_____ $$ |  $$ |
$$    $$/ $$ |  $$ |$$       |$$ |  $$ |$$ | $/  $$ |$$       |$$ |  $$ |
$$$$$$$/  $$/   $$/ $$$$$$$$/ $$/   $$/ $$/      $$/ $$$$$$$$/ $$/   $$/

```

---

[![Latest Version on Packagist](https://camo.githubusercontent.com/75e526deda88686ba38865600f9605c5a01b6bde4539a41147229fd1cbb1920e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f61726973746563682f6e696d6261736d732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/aristech/nimbasms)[![Total Downloads](https://camo.githubusercontent.com/7f2774f11d46e479f66c3480a32b918732c4297d5212b7bef38e5c077f5efaee/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f61726973746563682f6e696d6261736d732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/aristech/nimbasms)[![License](https://camo.githubusercontent.com/6c75121535123a1bb676a63f888eb9380ac904015ba04a41c0003d7ce92a0730/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f61726973746563682f6e696d6261736d732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/aristech/nimbasms)

Un package Laravel élégant pour intégrer l'API Nimba SMS, permettant l'envoi de SMS, la gestion des contacts et des groupes, les vérifications par code, et bien plus encore.

Fonctionnalités
---------------

[](#fonctionnalités)

- 📱 Envoi de SMS simple et programmé
- 👥 Gestion complète des contacts et des groupes
- ✅ Système de vérification par code
- 📊 Rapports de livraison et statistiques
- 🔄 Gestion robuste des erreurs via des exceptions spécialisées
- 🛡️ Gestion configurable de la vérification SSL (désactivation en développement)
- 🔄 Compatible avec Laravel 10.x et 11.x

Prérequis
---------

[](#prérequis)

- PHP 8.x
- Laravel 10.x ou 11.x
- Compte Nimba SMS avec identifiants API

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

[](#installation)

1. Installez le package via Composer :

```
composer require aristech/nimbasms
```

2. Publiez le fichier de configuration :

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

Configuration
-------------

[](#configuration)

1. Ajoutez vos identifiants Nimba SMS dans votre fichier `.env` :

```
NIMBA_SMS_SERVICE_ID=votre_service_id
NIMBA_SMS_SECRET=votre_secret
NIMBA_SMS_BASE_URL=https://api.nimbasms.com/
# Désactivez la vérification SSL en développement (à activer en production)
NIMBA_SMS_SSL_VERIFY=false
```

2. Le fichier de configuration `config/nimbasms.php` est disponible pour personnalisation :

```
return [
    'serviceId' => env('NIMBA_SMS_SERVICE_ID', ''),
    'secret'    => env('NIMBA_SMS_SECRET', ''),
    'baseUrl'   => env('NIMBA_SMS_BASE_URL', 'https://api.nimbasms.com/'),
    // Contrôle de la vérification SSL (important en production)
    'ssl_verify'=> filter_var(env('NIMBA_SMS_SSL_VERIFY', true), FILTER_VALIDATE_BOOLEAN),
];
```

Utilisation
-----------

[](#utilisation)

### Injection de Dépendance

[](#injection-de-dépendance)

Le package utilise l'injection de dépendance de Laravel. Vous pouvez injecter le client SMS via l'interface :

```
use Aristech\NimbaSms\Contracts\SmsClientInterface;

class SmsController extends Controller
{
    protected SmsClientInterface $smsClient;

    public function __construct(SmsClientInterface $smsClient)
    {
        $this->smsClient = $smsClient;
    }
}
```

### Envoi de SMS

[](#envoi-de-sms)

```
try {
    $response = $this->smsClient->send(
        'MonEntreprise',           // Nom de l'expéditeur
        ['+22457123456'],          // Liste des destinataires
        'Votre message ici'        // Contenu du message
    );

    // Traitement de la réponse
    return response()->json($response);

} catch (NimbaSmsException $e) {
    // Gestion des erreurs
    return response()->json([
        'error' => $e->getMessage(),
        'details' => $e->getErrorDetails()
    ], 400);
}
```

### Gestion des Contacts

[](#gestion-des-contacts)

```
// Création d'un contact
$response = $smsClient->createContact(
    'John Doe',                   // Nom
    ['Clients', 'VIP'],           // Groupes
    '+22457123456'                // Numéro
);

// Mise à jour d'un contact
$response = $smsClient->updateContact(
    'contact_id',
    'John Doe Updated',
    ['Clients'],
    '+22457123456'
);

// Suppression d'un contact
$response = $smsClient->deleteContact('contact_id');

// Liste des contacts
$contacts = $smsClient->getContacts();
```

### Gestion des Groupes

[](#gestion-des-groupes)

```
// Création d'un groupe
$response = $smsClient->createGroup('Nouveau Groupe');

// Mise à jour d'un groupe
$response = $smsClient->updateGroup('group_id', 'Nouveau Nom');

// Suppression d'un groupe
$response = $smsClient->deleteGroup('group_id');

// Liste des groupes
$groups = $smsClient->getGroups();
```

### Vérification par Code

[](#vérification-par-code)

```
// Envoi d'un code de vérification
$response = $smsClient->createVerification('+22457123456');

// Validation du code
$response = $smsClient->validateVerification(
    '+22457123456',              // Numéro
    '123456'                     // Code reçu
);
```

### SMS Programmés

[](#sms-programmés)

```
$response = $smsClient->scheduleSms(
    'MonEntreprise',             // Expéditeur
    ['+22457123456'],            // Destinataires
    'Message programmé',         // Contenu
    '2024-12-31 23:59:59'         // Date d'envoi
);
```

### Rapports

[](#rapports)

```
// Récupération d'un message spécifique
$message = $smsClient->getMessageById('message_id');

// Rapport de livraison d'un message
$report = $smsClient->getDeliveryReport('message_id');

// Liste des messages envoyés
$messages = $smsClient->getMessages();
```

Gestion des Erreurs
-------------------

[](#gestion-des-erreurs)

Le package gère les erreurs de manière robuste via l'exception `NimbaSmsException` :

```
try {
    $response = $smsClient->send($sender, $recipients, $message);
} catch (NimbaSmsException $e) {
    // Code d'erreur spécifique
    $errorCode = $e->getErrorCode();

    // Détails supplémentaires de l'erreur
    $details = $e->getErrorDetails();

    // Message d'erreur
    $message = $e->getMessage();

    // Log de l'erreur
    Log::error('Erreur Nimba SMS', [
        'message' => $message,
        'code' => $errorCode,
        'details' => $details
    ]);
}
```

Tests
-----

[](#tests)

Pour exécuter les tests du package :

```
composer test
```

Le package utilise [Orchestra Testbench](https://github.com/orchestral/testbench) pour la configuration du testing.

Changelog
---------

[](#changelog)

Consultez [CHANGELOG.md](CHANGELOG.md) pour les détails des modifications récentes.

Contribution
------------

[](#contribution)

Les contributions sont les bienvenues ! Pour plus de détails, consultez [CONTRIBUTING.md](CONTRIBUTING.md).

Sécurité
--------

[](#sécurité)

Si vous découvrez une faille de sécurité, merci d'envoyer un email à .

Crédits
-------

[](#crédits)

- [ArisTech](https://github.com/aristech)
- [Tous les contributeurs](../../contributors)

Licence
-------

[](#licence)

Le package Nimba SMS est distribué sous licence [MIT](LICENSE.md).

Support
-------

[](#support)

Pour toute question ou assistance :

- 📧 Email:
- 📚 [Documentation officielle Nimba SMS](https://developers.nimbasms.com/)

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance40

Moderate activity, may be stable

Popularity4

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 88.9% 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 ~0 days

Total

3

Last Release

503d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/75383139?v=4)[Aristide](/maintainers/Aristide-Dev)[@Aristide-Dev](https://github.com/Aristide-Dev)

---

Top Contributors

[![AristechGn](https://avatars.githubusercontent.com/u/189133421?v=4)](https://github.com/AristechGn "AristechGn (8 commits)")[![Aristide-Dev](https://avatars.githubusercontent.com/u/75383139?v=4)](https://github.com/Aristide-Dev "Aristide-Dev (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/aristech-nimbasms/health.svg)

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

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[defstudio/telegraph

A laravel facade to interact with Telegram Bots

816333.6k3](/packages/defstudio-telegraph)[api-platform/laravel

API Platform support for Laravel

58171.4k14](/packages/api-platform-laravel)[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.

5021.9k](/packages/simplestats-io-laravel-client)[jasara/php-amzn-selling-partner-api

A fluent interface for Amazon's Selling Partner API in PHP

1348.7k1](/packages/jasara-php-amzn-selling-partner-api)

PHPackages © 2026

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