PHPackages                             nandwabee/africastalking - 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. nandwabee/africastalking

ActiveLibrary

nandwabee/africastalking
========================

A composer package for the Africa's talking mobile API's

0.2.0(9y ago)17471[1 issues](https://github.com/nandwabee/africastalking/issues)MITPHP

Since Apr 4Pushed 9y ago1 watchersCompare

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

READMEChangelog (5)DependenciesVersions (6)Used By (0)

Africas Talking API
===================

[](#africas-talking-api)

This is another look at the AfricasTalking API for PHP.

I wrote it to meet a personal project need and it should suffice for many other use cases.

Requirements
------------

[](#requirements)

The main difference between this code and the official wrapper is that I opted to go for guzzle instead of hard dependency on Curl.

- [Guzzle](http://guzzle.readthedocs.org/en/5.3/overview.html)
- PHP 5.5.0 or newer. PHP 7 is currently not tested.

Be sure to checkout Guzzle's own dependencies.

Documentation
-------------

[](#documentation)

Install using composer.

`composer require nandwabee/africastalking`

### Sending Messages

[](#sending-messages)

An sms can be sent out by calling the `send()` method.

The send method returns an array when a message is sent successfully.

Example code below ;

```
//Instantiate the object.

$obj = new AfricasTalking('my_username','my_key');

$response = $obj->send($to,$message,$options);

//Do something with the array
```

**Parameters**

`$to` : *array* This is an array of the numbers to send the messages to.

`$message` : *string* The message to be sent.

`$options` : *array* An array of optional parameters.

The options parameter allows the following parameters;

`from,bulkSMSMode,enqueue,keyword,linkId,retryDurationInHours`

The expected values for either of those parameters can be found on the [AfricasTalking API Docs](http://docs.africastalking.com/sms/sending/url#documentation)

**Todo**

Exception handling

### Fetching User Details

[](#fetching-user-details)

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

[](#contribution)

This is an open source project so all ideas to help make this a better tool for other developers are highly welcome.

Try as much as possible to stick to the PSR-4 standards.

Waiting for the pull requests :-)

\##TODO

- Send SMS
- Support phone calls
- Receive SMS messages
- Support to Premium rate SMS services
- Create a sample Laravel 5 package
- Update the documentation with sample code
- Support for USSD
- Write tests
- Support for airtime transactions
- Fetch User data
- Improve exception handling.

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity57

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

Every ~26 days

Total

5

Last Release

3584d ago

### Community

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/nandwabee-africastalking/health.svg)

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

PHPackages © 2026

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