PHPackages                             zerochip/zimcell - 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. [Validation &amp; Sanitization](/categories/validation)
4. /
5. zerochip/zimcell

ActiveLibrary[Validation &amp; Sanitization](/categories/validation)

zerochip/zimcell
================

A package for verifying providers for Zimbabwean phone numbers

1(8y ago)225MITPHP

Since Feb 28Pushed 6y agoCompare

[ Source](https://github.com/zerochip/zimcell)[ Packagist](https://packagist.org/packages/zerochip/zimcell)[ RSS](/packages/zerochip-zimcell/feed)WikiDiscussions master Synced 3d ago

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

ZimCell
=======

[](#zimcell)

Overview
--------

[](#overview)

A package for working with Zimbabwean phone numbers. You can verify if a phone number belongs to a network or get the provider it belongs to.

Demo
----

[](#demo)

You can see it in action here

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

[](#installation)

```
composer require zerochip/zimcell

```

Usage
-----

[](#usage)

First import the class into your file

```
use Zerochip\Zimcell
```

Methods
-------

[](#methods)

- [refine](#refine)
- [intlFormat](#intlformat)
- [valid](#valid)
- [is](#is)
- [getProvider](#getprovider)

---

### refine

[](#refine)

`refine($cellnumber)`

Cleans up the cell number of any legiblity helpers by removing the following:

- Spaces
- Country code (+263 or 263)
- The leading zero

```
Zimcell::refine('+263772 123 456');
Zimcell::refine('263772 123456');
Zimcell::refine('0772 123 456');
Zimcell::refine('0772123456');

// All the above return 772123456
```

### intlFormat

[](#intlformat)

`intlFormat($cellnumber)`

Internationalizes the phone number with a "+" prefix.

```
Zimcell::intlFormat('0772 123 456');
// return +263772123456
```

### valid

[](#valid)

`valid($cellnumber)`

Checks if the given cellnumber is a valid Zimbabwean number by:

- running the refine function
- checking if the refined number is 9 digits long
- checking if the refined number starts with a 7

```
ZimCell::valid('0772 123 456');
// returns true

ZimCell::valid('0872 12 34 56');
//returns false, refined number starts with an 8 i.e 872123456

Zimcell::valid('0772 12345');
// returns false, refined number will be 8 digits long i.e 77212345
```

### is

[](#is)

`is($provider,  $cellnumber)`

Verifies if a number belongs to a given provider or service. The case of the provider name does not matter since they are converted to lower case before verifying.

```
Zimcell::is('econet', '0772 123 456');
// returns true

Zimcell::is('teleCash', '0772 123 456');
// returns false, note use of camelCase for provider name

Zimcell::is('netcel', '0772 123 456');
// returns null, netcel is not a supported provider
```

Supported provider and service names are as follows:

- Econet
- EcoCash
- Telecel
- Telecash
- NetOne
- One Money

### getProvider

[](#getprovider)

`getProvider($cellnumber)`

returns the provider for a phone number.

```
Zimcell::getProvider('0712123456');
// returns netone

Zimcell::getProvider('0812123456');
// returns null
```

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 86.4% 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

2998d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/93e306914d61015c613d395a3272de1b97c14ddacdd964168ddc048dd231983f?d=identicon)[iamalexchip](/maintainers/iamalexchip)

---

Top Contributors

[![gausam](https://avatars.githubusercontent.com/u/958800?v=4)](https://github.com/gausam "gausam (19 commits)")[![iamalexchip](https://avatars.githubusercontent.com/u/18460495?v=4)](https://github.com/iamalexchip "iamalexchip (3 commits)")

### Embed Badge

![Health badge](/badges/zerochip-zimcell/health.svg)

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

###  Alternatives

[webmozart/assert

Assertions to validate method input/output with nice error messages.

7.6k894.0M1.2k](/packages/webmozart-assert)[bensampo/laravel-enum

Simple, extensible and powerful enumeration implementation for Laravel.

2.0k15.9M104](/packages/bensampo-laravel-enum)[swaggest/json-schema

High definition PHP structures with JSON-schema based validation

48612.5M73](/packages/swaggest-json-schema)[stevebauman/purify

An HTML Purifier / Sanitizer for Laravel

5325.6M19](/packages/stevebauman-purify)[ashallendesign/laravel-config-validator

A package for validating your Laravel app's config.

217905.3k5](/packages/ashallendesign-laravel-config-validator)[crazybooot/base64-validation

Laravel validators for base64 encoded files

1341.9M8](/packages/crazybooot-base64-validation)

PHPackages © 2026

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