PHPackages                             kagga/telco - 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. kagga/telco

ActiveLibrary

kagga/telco
===========

Wrapper around the AfricasTalking api

1.0.2(9y ago)31891MITPHP

Since Jan 17Pushed 9y ago1 watchersCompare

[ Source](https://github.com/jokamjohn/telco)[ Packagist](https://packagist.org/packages/kagga/telco)[ RSS](/packages/kagga-telco/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (4)Used By (0)

Telco
=====

[](#telco)

**Telco** is a package wrapper around the [AfricasTalking](http://africastalking.com/) api. This package has been developed for Laravel 5+.

The package makes it easy to send an **sms** from your application to a phone.

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

[](#installation)

As other laravel packages, Telco is installed via composer.

In your terminal at the project root run

```
composer require kagga/telco

```

After add the service provider to `config/app.php` in the providers section

```
'providers' => [
            Kagga\Telco\TelcoServiceProvider::class
    ],

```

Then also add the Facade aliases in `config/app.php` within the alias section.

```
'aliases' => [
        'Telco' => Kagga\Telco\facades\Telco::class,
    ],

```

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

[](#configuration)

Now we are going to config the AfricasTalking api. Head over to your account or sign up to get your api key and username and jey hold of them.

Publish the package config file to the `config` folder in your app by running this in your terminal.

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

```

The config file called telco.php will be moved to `config/telco.php`.

Then add your username and api key to the `.env` file using these keys

```
SMS_USERNAME=yourUsername
SMS_API_KEY=yourapi-key

```

Thats all with the configuration.

You are about to get done, just one for thing. You can test out whether its working by serving your app `php artisan serve`and checking `http://localhost/telco/send` The view at this url comes bundled in the package only for testing purposes.

A success message will be showed after you send the message or an error message if something goes wrong.

Usage
-----

[](#usage)

At the moment the package has two methods, one for sending `send` an sms and the other the `api` that exposes the AfricasTalking Gateway.

With the `api` method you can access all the public methods in the [AfricasTalkingGateway](http://docs.africastalking.com/sms/sending) .

### Example code

[](#example-code)

```
Illuminate\Support\Facades\Route::post('/telco/send', function (\Kagga\Telco\contracts\TelcoInterface $telco) {

  $phonenumber = request('tel'); //Used the request laravel helper to get the phone number from a phone

  $message = request('message'); //Getting the message from the form

  $results = $telco->send($phonenumber, $message);

  if ($results != null) {

      return "Message has been sent successful to " . $phonenumber;
  }
});

```

You can also use the `Telco` facade that comes with the package to send a message.

```
Telco::send($phonenumber, $message);

```

Do not forget to add the facade import statement `use Kagga\Telco\facades\Telco;`

*Thats it*.

Thanks for using this package.

Let me know what you develop with this package. By sending me an email ** or **@johnkagga**

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity65

Established project with proven stability

 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

Every ~0 days

Total

3

Last Release

3404d ago

### Community

---

Top Contributors

[![jokamjohn](https://avatars.githubusercontent.com/u/8848097?v=4)](https://github.com/jokamjohn "jokamjohn (6 commits)")

### Embed Badge

![Health badge](/badges/kagga-telco/health.svg)

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

PHPackages © 2026

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