---
title: "Events — Messages for Laravel | Roundly"
description: "Plain Laravel events fire from every write path — with or without broadcasting — for notifications, search indexing and activity logs."
url: https://roundly-consulting.com/open-source/docs/messages-for-laravel/events
language: en
---

[All packages](https://roundly-consulting.com/open-source.md)

[Messages for Laravel](https://roundly-consulting.com/open-source/docs/messages-for-laravel.md)

# Events

Plain Laravel events fire from every write path regardless of whether broadcasting is on, so non-broadcasting apps can still react — notifications, search indexing, activity logs. All live under RoundlyConsulting\\Messages\\Events:

| Event | Public properties | Fired when |
| --- | --- | --- |
| `ThreadCreated` | $thread | A thread is created — once its participants are in (StartThread, including a new DM). |
| `MessageSent` | $message | A message is sent — after the transaction commits, so attachments are already bound. |
| `MessageEdited` | $message | EditMessage changes a body. |
| `MessageDeleted` | $message | DeleteMessage unsends (soft-deletes) a message. |
| `ParticipantJoined` | $participant | AddParticipant adds a new participant row — not on a re-add of someone already in. |
| `ParticipantLeft` | $thread, $participant (the model) | RemoveParticipant or LeaveThread removes someone. |
| `ThreadRead` | $participant | MarkRead advances a read pointer. |
| `ThreadRenamed` | $thread, $previousName | RenameThread changes the name. |
| `ThreadArchived` | $thread | ArchiveThread archives a thread for the first time. |
| `ParticipantTyping` | $thread, $participant | Messages::thread($t)->typing() (or $thread->typing()) is called with broadcasting on — broadcast only. |

```php
use Illuminate\Support\Facades\Event;
use RoundlyConsulting\Messages\Events\MessageSent;

Event::listen(MessageSent::class, function (MessageSent $event): void {
    // $event->message
});
```

ParticipantTyping is a transient, never-persisted signal that exists only to be broadcast — see Broadcasting. Role changes and ownership transfers fire no events of their own.

## The package’s own listeners

The package listens to MessageSent twice: NotifyParticipantsOfNewMessage (inert unless notifications are enabled) and the queued WarmMessageMediaVariants (image previews for attachments). Your listeners run alongside them.

## Show your open-source love

This package is free and MIT-licensed. If it saves you time, a one-off donation or a Patreon membership keeps it maintained, tested and documented.

[More ways to support, including crypto](https://roundly-consulting.com/support-us.md)

By donating, you agree to our [donation terms](https://roundly-consulting.com/donation-terms.md).

[Support our open source work (opens in a new tab)](https://donate.stripe.com/dRmeVe8FX5PF1Qd9pXcEw00) [Join us on Patreon (opens in a new tab)](https://www.patreon.com/cw/roundly)

## Want this built into your product?

We integrate our packages into custom Laravel and AI builds. Tell us what you're working on and we'll reply within 48 hours.

[Get a quote in 48 hours](https://roundly-consulting.com/contact.md) [Browse all packages](https://roundly-consulting.com/open-source/docs/messages-for-laravel.md)
