PHPackages                             kheme/php-supertext-nigeria - 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. kheme/php-supertext-nigeria

ActivePackage

kheme/php-supertext-nigeria
===========================

A simple PHP wrapper for SuperText Nigeria's SMS gateway API

1.0.0(5y ago)08MITPHPPHP &gt;=5.3.0

Since Sep 20Pushed 5y ago1 watchersCompare

[ Source](https://github.com/kheme/php-supertext-nigeria)[ Packagist](https://packagist.org/packages/kheme/php-supertext-nigeria)[ Docs](https://github.com/kheme/php-supertext-nigeria)[ RSS](/packages/kheme-php-supertext-nigeria/feed)WikiDiscussions master Synced today

READMEChangelog (1)DependenciesVersions (3)Used By (0)

 PHP Wrapper for SuperText Nigeria SMS Gateway
-----------------------------------------------

[](#----php-wrapper-for-supertext-nigeria-sms-gateway)

 [ ![Latest Stable Version](https://camo.githubusercontent.com/a7b49b8bd7cbd6499e2a1b8658661f715dfebac99cba36299838d2f4f616e8b7/68747470733a2f2f706f7365722e707567782e6f72672f6b68656d652f7068702d7375706572746578742d6e6967657269612f762f737461626c65) ](https://packagist.org/packages/kheme/php-supertext-nigeria) [ ![Latest Unstable Version](https://camo.githubusercontent.com/884bf699f0abde4a010ebcde2cdd0539c5ba71c6b3767e11f7f1fb70f3a6ac53/68747470733a2f2f706f7365722e707567782e6f72672f6b68656d652f7068702d7375706572746578742d6e6967657269612f762f756e737461626c65) ](https://packagist.org/packages/kheme/php-supertext-nigeria) [ ![Total Downloads](https://camo.githubusercontent.com/86d7d3380b91bea8ae3a2426c82b7621879c29fb96bb0e71acf2b8952d666ef5/68747470733a2f2f706f7365722e707567782e6f72672f6b68656d652f7068702d7375706572746578742d6e6967657269612f646f776e6c6f616473) ](https://packagist.org/packages/kheme/php-supertext-nigeria) [ ![License](https://camo.githubusercontent.com/f971e76f9a0ccda0df5495ef259bc2975d92be76dec7360ef53961c11e2c176b/68747470733a2f2f706f7365722e707567782e6f72672f6b68656d652f7068702d7375706572746578742d6e6967657269612f6c6963656e7365) ](https://packagist.org/packages/kheme/php-supertext-nigeria)

Introduction
------------

[](#introduction)

This is a simple PHP wrapper for [SuperText Nigeria](https://www.supertextng.com/)'s SMS API gateway.

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

[](#installation)

Using Composer:

```
composer require kheme/php-supertext-nigeria
```

### Usage

[](#usage)

Import the class before making your calls.

```
require_once 'vendor/autoload.php';
use Kheme\SuperTextNg\SMS;
```

Sending to a single recipient
-----------------------------

[](#sending-to-a-single-recipient)

```
$sms = new SMS('SUPERTEXTNG_USERNAME', 'SUPERTEXTNG_PASSWORD');
$sms->from('Kheme');
$sms->to('2348153332428')
$sms->message('Using the facade to send a message.')
$sms->send();   // returns true
```

If sending wasn't successful, an exception will be thrown.

Sending to multiple recipients
------------------------------

[](#sending-to-multiple-recipients)

You can send an SMS to multiple recipients by including multiple `to()` in your call:

```
$sms = new SMS('SUPERTEXTNG_USERNAME', 'SUPERTEXTNG_PASSWORD');
$sms->from('Kheme');
$sms->to('2348153332428');
$sms->to('2348056511193');
$sms->message('Using the facade to send a message.');
$sms->send();   // returns true
```

Or, by supplying an array of phone numbers to a single `to()`:

```
$sms = new SMS('SUPERTEXTNG_USERNAME', 'SUPERTEXTNG_PASSWORD');
$sms->from('Kheme');
$sms->to([
    '2348153332428',
    '2348056512393',
]);
$sms->message('Using the facade to send a message.');
$sms->send();   // returns true
```

Send to DND enabled numbers
---------------------------

[](#send-to-dnd-enabled-numbers)

To send SMS to numbers that have Do Not Disturb (DND) enabled, include `ignoreDND()` to your call:

```
$sms = new SMS('SUPERTEXTNG_USERNAME', 'SUPERTEXTNG_PASSWORD');
$sms->from('Kheme');
$sms->to('2348153332428');
$sms->message('Using the facade to send a message.');
$sms->ignoreDND();
$sms->send();   // returns true
```

Return unit balance after sending
---------------------------------

[](#return-unit-balance-after-sending)

If you would like to return your account balance after sending, include `returnBalance()` to your call:

```
$sms = new SMS('SUPERTEXTNG_USERNAME', 'SUPERTEXTNG_PASSWORD');
$sms->from('Kheme');
$sms->to('2348153332428');
$sms->message('Using the facade to send a message.');
$sms->returnBalance();
$sms->send();   // returns true
```

Return amount of units used for sending
---------------------------------------

[](#return-amount-of-units-used-for-sending)

If you would like to return the total amount of units used after sending, include `returnUnitsUsed()` to your call:

```
$sms = new SMS('SUPERTEXTNG_USERNAME', 'SUPERTEXTNG_PASSWORD');
$sms->from('Kheme');
$sms->to('2348153332428');
$sms->message('Using the facade to send a message.');
$sms->returnUnitsUsed();
$sms->send();   // returns true
```

Combining options
-----------------

[](#combining-options)

The above method options, exluding the `balance()` below, can be combined like in the following example:

```
$sms = new SMS('SUPERTEXTNG_USERNAME', 'SUPERTEXTNG_PASSWORD');
$sms->from('Kheme');;
$sms->to('2348153332428');
$sms->message('Using the facade to send a message.');
$sms->returnBalance();
$sms->returnUnitsUsed();
$sms->ignoreDND();
$sms->send();   // returns true
```

Checking account balance
------------------------

[](#checking-account-balance)

To check your SuperText Nigeria credit balance, simply call `balance()`:

```
$sms = new SMS('SUPERTEXTNG_USERNAME', 'SUPERTEXTNG_PASSWORD');
return $sms->balance();
```

### Errors

[](#errors)

In the case of an error, a call will return an error as follows:

*The numbers on the left are the corresponding error code from SuperText Nigeria, but will not be included in the error response*

- **100**: *One or more required url parameter is missing or misspelt*
- **101**: *Username is blank*
- **102**: *Password is blank*
- **103**: *Destination is blank*
- **104**: *Message is blank*
- **105**: *Sender is blank*
- **200**: *Wrong username or password*
- **201**: *Account has not been activated*
- **202**: *Inactive account*
- **300**: *Insufficient credit*
- **400**: *Failed delivery (no credit deducted)*

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity50

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

2058d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/68ea4a1552f2217337119312b998af0f50b9c50a23a73eaa6bcab33a30891195?d=identicon)[kheme](/maintainers/kheme)

---

Top Contributors

[![kheme](https://avatars.githubusercontent.com/u/895416?v=4)](https://github.com/kheme "kheme (16 commits)")

---

Tags

phpsmssms-gatewaysupertext-nigeriaphpsmssms-gatewaykhemesupertextngPHP SMS Gatewayphp sms packagephp sms sender

### Embed Badge

![Health badge](/badges/kheme-php-supertext-nigeria/health.svg)

```
[![Health](https://phpackages.com/badges/kheme-php-supertext-nigeria/health.svg)](https://phpackages.com/packages/kheme-php-supertext-nigeria)
```

###  Alternatives

[djunehor/laravel-sms

Send SMS from your laravel application

385.3k1](/packages/djunehor-laravel-sms)[amirbagh75/smsir-php

Unofficial sms.ir PHP Package

181.2k](/packages/amirbagh75-smsir-php)

PHPackages © 2026

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