PHPackages                             juanparati/inmobile - 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. [API Development](/categories/api)
4. /
5. juanparati/inmobile

ActiveLibrary[API Development](/categories/api)

juanparati/inmobile
===================

InMobile client for Laravel

1.4(1y ago)02.5k↓33.3%MITPHPPHP &gt;=8.1CI passing

Since Oct 13Pushed 1y ago1 watchersCompare

[ Source](https://github.com/juanparati/laravel-inmobile)[ Packagist](https://packagist.org/packages/juanparati/inmobile)[ RSS](/packages/juanparati-inmobile/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (5)Dependencies (5)Versions (6)Used By (0)

InMobile library for Laravel
============================

[](#inmobile-library-for-laravel)

[InMobile](https://inmobile.dk) library for Laravel.

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

[](#installation)

```
composer require juanparati/inmobile

```

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

[](#configuration)

Publish configuration file:

```
artisan vendor:publish --tag="inmobile"

```

Usage examples
--------------

[](#usage-examples)

### List service

[](#list-service)

#### Create list

[](#create-list)

```
InMobile::lists()->create('My list');
```

#### Get all lists

[](#get-all-lists)

```
// Return a paginated results instance.
$lists = InMobile::lists()->all();

// Will automatically transverse all the pages automatically.
// Rewind is not allowed.
foreach ($lists as $list)
    var_dump($list->toArray());
```

#### Get a list

[](#get-a-list)

```
InMobile::lists()->find($myListId);
```

#### Create a list

[](#create-a-list)

```
InMobile::lists()->create('My new list');
```

#### Get all recipients in list

[](#get-all-recipients-in-list)

```
$recipients = InMobile::lists()->getRecipients($myListId);

// Will automatically transverse all the pages automatically.
// Rewind is not allowed.
foreach ($recipients as $recipient)
    var_dump($recipient->toArray());
```

#### Other methods

[](#other-methods)

- update
- delete
- truncate

### Recipient service

[](#recipient-service)

#### Create recipient

[](#create-recipient)

```
$recipient = InMobile::recipients()->create(
    $listId,
    \Juanparati\InMobile\Models\Recipient::make('45', '12345678')
        ->addField('firstname', 'John')
        ->addField('lastname', 'Random')
        ->addField('custom1', 'foobar')
        ->setCreatedAt(now()->subMinute())
);

echo 'Recipient id: ' . $recipient->getId();
```

#### Update recipient

[](#update-recipient)

```
// Only update some fields
InMobile::recipients()->updateById(
    $listId,
    $recipientId,
    \Juanparati\InMobile\Models\Recipient::make()
        ->addField('firstname', 'John')
        ->addField('lastname', 'Random')
        ->addField('custom1', 'foobar'),
    false   // Indicate that only values set are updated (Default)
);

// Full update
InMobile::recipients()->updateById(
    $listId,
    $recipientId,
    \Juanparati\InMobile\Models\Recipient::make('35', '12345678')
        ->addField('firstname', 'John')
        ->addField('lastname', 'Random')
        ->addField('custom1', 'foobar')
        ->setCreatedAt(now())
        ,
    true   // Indicate that all fields are update, the fields missing in the recipient model are emptied
);

// or use updateByNumber instead (It's slower than updateById because it has to lookup for the recipient Id)
InMobile::recipients()->updateByNumber(
    $listId,
    $prefix,
    $number,
     \Juanparati\InMobile\Models\Recipient::make()
        ->addField('firstname', 'John')
        ->addField('lastname', 'Random')
        ->addField('custom1', 'foobar')
);
```

#### Find recipient by Id

[](#find-recipient-by-id)

```
if ($recipient = InMobile::recipients()->findById('listid', 'recipientId')) {
    echo 'Recipient ' . $recipient->getId() . ' has phone +' . $recipient->getCode() . ' ' . $recipient->getPhone();
    var_dump($recipient->toArray());
} else {
    echo 'Recipient not found';
}
```

#### Find recipient

[](#find-recipient)

```
// Search by phone number
$recipient = InMobile::recipients()->findByNumber('listid', '45', '12345678');

// or search by recipient id
$recipient = InMobile::recipients()->findById('listid', 'recipientId');
```

#### Other methods

[](#other-methods-1)

- deleteById
- deleteByNumber
- updateOrCreateByNumber
- moveToList

### Blacklist service

[](#blacklist-service)

#### Methods

[](#methods)

- all
- create
- findById
- findByNumber
- deleteById
- deleteByNumber

### Email service

[](#email-service)

#### Send message

[](#send-message)

```
$message = \Juanparati\InMobile\Models\Message(
    '+45',
    '1234567',
    'from me',
    'Hello world'
);

InMobile::sms()->send([$message]);
```

#### Send template message

[](#send-template-message)

```
$templateMessage = \Juanparati\InMobile\Models\MessageTemplate::make('+45', '1234567');
$templateMessage->addPlaceholder('{NAME}', 'John Random');

InMobile::sms()->sendUsingTemplate('FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFFF', [$templateMessage]);
```

### Email template service

[](#email-template-service)

#### Methods

[](#methods-1)

- all
- find

### Gdpr service

[](#gdpr-service)

- create

### Sms service

[](#sms-service)

#### Methods

[](#methods-2)

- send
- sendUsingTemplate
- cancel
- status

###  Health Score

36

—

LowBetter than 81% of packages

Maintenance49

Moderate activity, may be stable

Popularity20

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity55

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 ~132 days

Total

5

Last Release

409d ago

Major Versions

0.93 → 1.12024-10-23

### Community

Maintainers

![](https://www.gravatar.com/avatar/4caf72b4d969cfb8cdfbdc1d594c85b51c9316caf76b80aa0f9de7e3736cf59f?d=identicon)[juanparati](/maintainers/juanparati)

---

Top Contributors

[![juanparati](https://avatars.githubusercontent.com/u/835173?v=4)](https://github.com/juanparati "juanparati (2 commits)")

---

Tags

clientlaravelsmsinmobile

###  Code Quality

TestsPHPUnit

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/juanparati-inmobile/health.svg)

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

###  Alternatives

[openai-php/laravel

OpenAI PHP for Laravel is a supercharged PHP API client that allows you to interact with the Open AI API

3.7k7.6M74](/packages/openai-php-laravel)[ardakilic/mutlucell

Mutlucell SMS API wrapper for sending sms text messages for Laravel

457.3k](/packages/ardakilic-mutlucell)

PHPackages © 2026

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