PHPackages                             joemags-apps/zim-phone-utils - 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. joemags-apps/zim-phone-utils

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

joemags-apps/zim-phone-utils
============================

A Laravel package for working with phone numbers in the Zimbabwean context.

1.0.1(1y ago)142MITPHPPHP ^8.1

Since May 7Pushed 1y agoCompare

[ Source](https://github.com/joemunapo/zim-phone-utils)[ Packagist](https://packagist.org/packages/joemags-apps/zim-phone-utils)[ Docs](https://github.com/joemags-apps/zim-phone-utils)[ GitHub Sponsors]()[ RSS](/packages/joemags-apps-zim-phone-utils/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)Dependencies (9)Versions (3)Used By (0)

A Laravel package for working with phone numbers in the Zimbabwean context
==========================================================================

[](#a-laravel-package-for-working-with-phone-numbers-in-the-zimbabwean-context)

[![Latest Version on Packagist](https://camo.githubusercontent.com/225fba123fdc65f32289b6d6c9bcabf8045be85eaf50f077f2e5a605b1baf295/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6a6f656d6167732d617070732f7a696d2d70686f6e652d7574696c732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/joemags-apps/zim-phone-utils)[![GitHub Tests Action Status](https://camo.githubusercontent.com/4b7e422e234e56226983520512c8727055db9c3058f3c987c865de1a638090be/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6a6f656d6167732d617070732f7a696d2d70686f6e652d7574696c732f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/joemags-apps/zim-phone-utils/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/bcb019229d7f635f02e73e01c2d75593d0296f36eb008de19a89eccfd2078312/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6a6f656d6167732d617070732f7a696d2d70686f6e652d7574696c732f6669782d7068702d636f64652d7374796c652d6973737565732e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/joemags-apps/zim-phone-utils/actions?query=workflow%3A%22Fix+PHP+code+style+issues%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/cee818344627380a19b9a7c6bd3935d3e2d08296baa8962fadf9d0f100df06de/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6a6f656d6167732d617070732f7a696d2d70686f6e652d7574696c732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/joemags-apps/zim-phone-utils)

Zim Phone Utils is a Laravel package that provides a set of utility functions and custom validation rules for working with phone numbers in the Zimbabwean context. It simplifies tasks such as formatting phone numbers, extracting country codes, determining mobile carriers, and validating phone numbers against specific criteria.

Features
--------

[](#features)

- Format phone numbers in national or international format
- Extract country ISO codes and country codes from phone numbers
- Determine the mobile carrier for a given phone number
- Custom validation rules for phone numbers and mobile carriers
- Seamless integration with Laravel's validation system

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

[](#installation)

You can install the package via composer:

```
composer require joemags-apps/zim-phone-utils
```

Usage
-----

[](#usage)

```
use JoemagsApps\ZimPhoneUtils\Utils;

// Format a phone number
$formattedNumber = Utils::formatPhoneNumber('+263771234567');

// Get the country ISO code
$countryIso = Utils::getCountryIso('+263771234567');

// Get the mobile carrier
$carrier = Utils::getPhoneCarrier('+263771234567');

// Validate a phone number
$request->validate([
    'phone' => 'required|phone:ZW',
]);

// Validate a mobile carrier
$request->validate([
    'carrier' => 'required|carrier:Econet,NetOne,Telecel',
]);
```

Testing
-------

[](#testing)

```
composer test # Run tests
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Joe Munapo](https://github.com/joemags-apps)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance31

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 60.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

Every ~18 days

Total

2

Last Release

717d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/bf6078d337bcd706bf69e75b5f7b3f9beeca3a7bf33f01bfbc834fb2d12f9d12?d=identicon)[joemunapo](/maintainers/joemunapo)

---

Top Contributors

[![freekmurze](https://avatars.githubusercontent.com/u/483853?v=4)](https://github.com/freekmurze "freekmurze (353 commits)")[![mvdnbrk](https://avatars.githubusercontent.com/u/802681?v=4)](https://github.com/mvdnbrk "mvdnbrk (46 commits)")[![Nielsvanpach](https://avatars.githubusercontent.com/u/10651054?v=4)](https://github.com/Nielsvanpach "Nielsvanpach (21 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (20 commits)")[![pforret](https://avatars.githubusercontent.com/u/474312?v=4)](https://github.com/pforret "pforret (16 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (14 commits)")[![sebastiandedeyne](https://avatars.githubusercontent.com/u/1561079?v=4)](https://github.com/sebastiandedeyne "sebastiandedeyne (14 commits)")[![joemunapo](https://avatars.githubusercontent.com/u/63977646?v=4)](https://github.com/joemunapo "joemunapo (10 commits)")[![patinthehat](https://avatars.githubusercontent.com/u/5508707?v=4)](https://github.com/patinthehat "patinthehat (10 commits)")[![riasvdv](https://avatars.githubusercontent.com/u/3626559?v=4)](https://github.com/riasvdv "riasvdv (8 commits)")[![AdrianMrn](https://avatars.githubusercontent.com/u/12762044?v=4)](https://github.com/AdrianMrn "AdrianMrn (8 commits)")[![crynobone](https://avatars.githubusercontent.com/u/172966?v=4)](https://github.com/crynobone "crynobone (7 commits)")[![AlexVanderbist](https://avatars.githubusercontent.com/u/6287961?v=4)](https://github.com/AlexVanderbist "AlexVanderbist (7 commits)")[![thecaliskan](https://avatars.githubusercontent.com/u/13554944?v=4)](https://github.com/thecaliskan "thecaliskan (5 commits)")[![irfanm96](https://avatars.githubusercontent.com/u/42065936?v=4)](https://github.com/irfanm96 "irfanm96 (5 commits)")[![IGedeon](https://avatars.githubusercontent.com/u/694313?v=4)](https://github.com/IGedeon "IGedeon (4 commits)")[![yaroslawww](https://avatars.githubusercontent.com/u/23663794?v=4)](https://github.com/yaroslawww "yaroslawww (3 commits)")[![jessarcher](https://avatars.githubusercontent.com/u/4977161?v=4)](https://github.com/jessarcher "jessarcher (3 commits)")[![koossaayy](https://avatars.githubusercontent.com/u/6431084?v=4)](https://github.com/koossaayy "koossaayy (3 commits)")[![lloricode](https://avatars.githubusercontent.com/u/8251344?v=4)](https://github.com/lloricode "lloricode (3 commits)")

---

Tags

laravelvalidationphonemobileutilitiescountry codecarrierzimbabwe

###  Code Quality

TestsPest

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/joemags-apps-zim-phone-utils/health.svg)

```
[![Health](https://phpackages.com/badges/joemags-apps-zim-phone-utils/health.svg)](https://phpackages.com/packages/joemags-apps-zim-phone-utils)
```

###  Alternatives

[propaganistas/laravel-phone

Adds phone number functionality to Laravel based on Google's libphonenumber API.

3.0k35.7M107](/packages/propaganistas-laravel-phone)[proengsoft/laravel-jsvalidation

Validate forms transparently with Javascript reusing your Laravel Validation Rules, Messages, and FormRequest

1.1k2.3M49](/packages/proengsoft-laravel-jsvalidation)[axlon/laravel-postal-code-validation

Worldwide postal code validation for Laravel and Lumen

3853.3M1](/packages/axlon-laravel-postal-code-validation)[toplan/laravel-sms

A mobile phone number validation solution based on laravel

83678.5k1](/packages/toplan-laravel-sms)[laravel-validation-rules/phone

Validate that a phone number is in the correct format

69355.5k](/packages/laravel-validation-rules-phone)[galahad/laravel-addressing

Laravel package providing addressing functionality

70316.6k](/packages/galahad-laravel-addressing)

PHPackages © 2026

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