PHPackages                             roomies/phonable - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. roomies/phonable

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

roomies/phonable
================

Gather insights and verify phone numbers from multiple third-party providers.

0.11.3(3w ago)124.6k↑1053.3%MITPHPPHP ^8.3CI passing

Since Jan 24Pushed 3w ago1 watchersCompare

[ Source](https://github.com/roomies-com/phonable)[ Packagist](https://packagist.org/packages/roomies/phonable)[ Docs](https://github.com/roomies-com/phonable)[ RSS](/packages/roomies-phonable/feed)WikiDiscussions main Synced 3d ago

READMEChangelogDependencies (24)Versions (22)Used By (0)

Roomies Phonable
================

[](#roomies-phonable)

[![Latest Version on Packagist](https://camo.githubusercontent.com/c87e61c5e7d67d0874d98cbb44c59258017d4ded11d1697e6c0f955f3c4496d0/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f726f6f6d6965732f70686f6e61626c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/roomies/phonable)[![GitHub Tests Action Status](https://camo.githubusercontent.com/5cf60e64382726975f3df05ec10da3f9edd158aa9f248b91d96802f55c9c3a3d/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f726f6f6d6965732d636f6d2f70686f6e61626c652f746573742e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/roomies-com/phonable/actions?query=workflow%3Atest+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/9bb28ade41c90569c717b2032cecd8e6b64b666a6882f2b40a4dab66c1b54b89/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f726f6f6d6965732f70686f6e61626c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/roomies/phonable)

Roomies Phonable provides an abstraction layer to identify and verify phone numbers in your Laravel app. Phone verification can be used to help identify legitimate users of your app and also serve as a way to handle 2-factor authentication. Phonable provides implementations for a number of phone services including [Prelude](https://prelude.so), [Twilio](https://www.twilio.com), and [Vonage](https://vonage.com).

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

[](#installation)

You can install the package via Composer:

```
composer require roomies/phonable
```

You can publish the config file with:

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

Read through the config file to understand the supported services and provide the correct configuration for your preferred services.

Identification
--------------

[](#identification)

Identification is a way to gather more information about a phone number including the country of origin, phone number type and more. This feature is supported by Prelude and Vonage.

```
// Return an instance of \Roomies\Phonable\Identification\IdentificationResult
$result = Identification::get('+12125550000');
```

Alternatively you can pass an object that implements `Roomies\Phonable\Contracts\PhoneIdentifiable` - `getIdentifiablePhoneNumber()` should return the phone number in E.164 format.

```
use Roomies\Phonable\Facades\Identification;
use Roomies\Phonable\Contracts\PhoneIdentifiable;

class User implements PhoneIdentifiable
{
    /**
     * The identifiable phone number in E.164 format.
     */
    public function getIdentifiablePhoneNumber(): ?string
    {
        return '+12125550000';
    }
}

// Return an instance of \Roomies\Phonable\Identification\IdentificationResult
$result = Identification::get($user);
```

You can swap the driver out on the fly as necessary.

```
use Roomies\Phonable\Facades\Identification;

Identification::driver('prelude')->get($user);
```

Verification
------------

[](#verification)

Verification is a two-step process in sending a generated code to a phone number that then needs to be entered back into your app to complete the process. This ensures your user has timely access to the phone number provided. This feature is supported by Prelude, Twilio, and Vonage.

```
// Return an instance of \Roomies\Phonable\Verification\VerificationRequest
$request = Verification::send('+12125550000');

// Return an instance of \Roomies\Phonable\Verification\VerificationResult
$result = Verification::verify($request->id, 'code');
```

Alternatively you can pass an object that implements `Roomies\Phonable\Contracts\PhoneVerifiable` - `getVerifiablePhoneNumber()` should return the phone number in E.164 format and `getVerifiableSession()` should return the previously stored verification request ID.

```
use Roomies\Phonable\Facades\Verification;
use Roomies\Phonable\Contracts\PhoneIdentifiable;

class User implements PhoneVerifiable
{
    /**
     * The verifiable phone number in E.164 format.
     */
    public function getVerifiablePhoneNumber(): ?string
    {
        return '+12125550000';
    }

    /**
     * The current verification session identifier.
     */
    public function getVerifiableSession(): ?string
    {
        return $this->phone_verification_session;
    }
}

// Return an instance of \Roomies\Phonable\Verification\VerificationRequest
$request = Verification::send($user);

$user->update([
    'phone_verification_session' => $request->id,
]);
```

You will need to store the verification session ID as it will be used to complete the process.

When you receive the code from the user you can then call the `verify` method with the provided code. `Roomies\Phonable\Verification\VerificationResult` is a simple enum of the result.

```
use Roomies\Phonable\Verification\VerificationResult;

// Return an instance of \Roomies\Phonable\Verification\VerificationResult
$result = Verification::verify($user, 1234);

if ($result === VerificationResult::Successful) {
    $user->update([
        'phone_verified_at' => now(),
        'phone_verification_session' => null,
    ]);
}
```

You can swap the driver out on the fly as necessary.

```
use Roomies\Phonable\Facades\Verification;

Verification::driver('prelude')->send($user);
```

License
-------

[](#license)

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

###  Health Score

51

—

FairBetter than 95% of packages

Maintenance95

Actively maintained with recent releases

Popularity29

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 98.6% 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 ~51 days

Recently: every ~21 days

Total

18

Last Release

25d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1100408?v=4)[Dwight Watson](/maintainers/dwightwatson)[@dwightwatson](https://github.com/dwightwatson)

---

Top Contributors

[![dwightwatson](https://avatars.githubusercontent.com/u/1100408?v=4)](https://github.com/dwightwatson "dwightwatson (73 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")

---

Tags

laravelroomiesphonable

###  Code Quality

TestsPHPUnit

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/roomies-phonable/health.svg)

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

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[laravel/socialite

Laravel wrapper around OAuth 1 &amp; OAuth 2 libraries.

5.7k108.5M889](/packages/laravel-socialite)[laravel/boost

Laravel Boost accelerates AI-assisted development by providing the essential context and structure that AI needs to generate high-quality, Laravel-specific code.

3.5k21.5M603](/packages/laravel-boost)[spatie/laravel-export

Create a static site bundle from a Laravel app

674146.0k6](/packages/spatie-laravel-export)[nativephp/mobile

NativePHP for Mobile

1.1k75.1k97](/packages/nativephp-mobile)[spatie/laravel-health

Monitor the health of a Laravel application

87512.0M167](/packages/spatie-laravel-health)

PHPackages © 2026

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