PHPackages                             deskti/laravel-chat - 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. deskti/laravel-chat

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

deskti/laravel-chat
===================

Laravel chat package

1.0.5(9y ago)2182[2 issues](https://github.com/deskti/laravel-chat/issues)MITPHP

Since May 28Pushed 9y agoCompare

[ Source](https://github.com/deskti/laravel-chat)[ Packagist](https://packagist.org/packages/deskti/laravel-chat)[ RSS](/packages/deskti-laravel-chat/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (1)Versions (7)Used By (0)

Chat
----

[](#chat)

This package allows you to add a chat system to your Laravel 5 application

Obs: Chat copiado do musonza/chat apenas para o uso pessoal da Deskti

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

[](#installation)

From the command line, run:

```
composer require deskti/laravel-chat

```

Add the service provider to your `config\app.php` the providers array

```
Deskti\Chat\ChatServiceProvider

```

You can use the facade for shorter code. Add this to your aliases:

```
'Chat' => Deskti\Chat\Facades\ChatFacade::class to your `config\app.php`

```

The class is bound to the ioC as chat

```
$chat = App::make('chat');

```

Publish the assets:

```
php artisan vendor:publish

```

This will publish database migrations and a configuration file `chat.php` in the Laravel config folder.

Usage
-----

[](#usage)

By default the package assumes you have a User model in the App namespace. However, you can update the user model in 'chat.php' published in the `config` folder.

#### Creating a conversation

[](#creating-a-conversation)

```
$conversation = Chat::createConversation([$userId, $userId2,...]); //takes an array of user ids

```

#### Get a conversation given a conversation\_id

[](#get-a-conversation-given-a-conversation_id)

```
$conversation = Chat::conversation($conversation_id);

```

#### Send a message

[](#send-a-message)

```
Chat::send($conversation->id, 'Hello', $userId); //$userId sending a message to created conversation

```

#### Mark message as read

[](#mark-message-as-read)

```
Chat::messageRead($messageId, $userId); //$userId marks the mesage as read

```

#### Mark whole conversation as read

[](#mark-whole-conversation-as-read)

```
Chat::conversationRead($conversation->id, $userId);

```

#### Delete a message

[](#delete-a-message)

```
Chat::trash($messageId, $userId);

```

#### Clear a conversation

[](#clear-a-conversation)

```
Chat::clear($conversation->id, $userId);

```

#### Get conversation for two users

[](#get-conversation-for-two-users)

```
Chat::getConversationBetweenUsers($userId, $userId2);

```

#### Remove user(s) from conversation

[](#remove-users-from-conversation)

```
Chat::removeParticipants($conversation->id, $usersId); //removing one user

```

```
Chat::removeParticipants($conversation->id, [$usersId, $userId2]); //removing multiple users

```

#### Add user(s) to a conversation

[](#add-users-to-a-conversation)

```
Chat::addParticipants($conversation->id, $userId3); //add one user

```

```
Chat::addParticipants($conversation->id, [$userId3, $userId4]); //add multiple users

```

#### Get messages in a conversation

[](#get-messages-in-a-conversation)

```
Chat::messages($userId, $conversation->id, $perPage, $page);

```

#### Get recent messages

[](#get-recent-messages)

```
$mesages = Chat::conversations($userId);

```

#### Get users in a conversation

[](#get-users-in-a-conversation)

```
$users = $conversation->users;

```

###  Health Score

25

—

LowBetter than 36% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity67

Established project with proven stability

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

Total

6

Last Release

3304d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/21258161?v=4)[Marcos Moraes](/maintainers/socramjunio2)[@socramjunio2](https://github.com/socramjunio2)

---

Top Contributors

[![socramjunio2](https://avatars.githubusercontent.com/u/21258161?v=4)](https://github.com/socramjunio2 "socramjunio2 (7 commits)")

---

Tags

laravelmessagingchatconversation

### Embed Badge

![Health badge](/badges/deskti-laravel-chat/health.svg)

```
[![Health](https://phpackages.com/badges/deskti-laravel-chat/health.svg)](https://phpackages.com/packages/deskti-laravel-chat)
```

###  Alternatives

[musonza/chat

Chat Package for Laravel

1.2k267.5k1](/packages/musonza-chat)[psalm/plugin-laravel

Psalm plugin for Laravel

3345.1M337](/packages/psalm-plugin-laravel)[lexxyungcarter/chatmessenger

Simple one-to-one/group chat messaging tool for Laravel 5, 6, 7, 8, 9 &amp; 10 with Pusher Integration

10525.0k](/packages/lexxyungcarter-chatmessenger)[syntaxlexx/chatmessenger

Simple one-to-one/group chat messaging tool for Laravel 5, 6, 7, 8, 9 &amp; 10 with Pusher Integration

10510.9k](/packages/syntaxlexx-chatmessenger)

PHPackages © 2026

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