PHPackages                             sierratecnologia/transmissor - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. sierratecnologia/transmissor

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

sierratecnologia/transmissor
============================

Simple user messaging and notifications tool for Laravel

0.4.4(2y ago)01274MITPHPPHP ^7.2|^8.0CI failing

Since Jul 20Pushed 6mo ago1 watchersCompare

[ Source](https://github.com/SierraTecnologia/Transmissor)[ Packagist](https://packagist.org/packages/sierratecnologia/transmissor)[ Docs](https://sierratecnologia.com/packages/transmissor/)[ Fund](https://ricasolucoes.com.br/open-source/support-us)[ GitHub Sponsors](https://github.com/ricasolucoes)[ RSS](/packages/sierratecnologia-transmissor/feed)WikiDiscussions stable Synced 2d ago

READMEChangelogDependencies (21)Versions (21)Used By (4)

SierraTecnologia Transmissor
============================

[](#sierratecnologia-transmissor)

**SierraTecnologia Transmissor** transmissor services transmissor and providers for users required by various SierraTecnologia packages. Validator functionality, and basic controller included out-of-the-box.

[![Packagist](https://camo.githubusercontent.com/86738e0b99dcea1355fc13448ab6d92d72cb08a828821d10f71ba50b8961651e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7369657272617465636e6f6c6f6769612f7472616e736d6973736f722e7376673f6c6162656c3d5061636b6167697374267374796c653d666c61742d737175617265)](https://packagist.org/packages/sierratecnologia/transmissor)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/7f7f72f397eb997f91890bd275a2b2a22471a49b86347cea3b09d860af329217/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f7369657272617465636e6f6c6f6769612f7472616e736d6973736f722e7376673f6c6162656c3d5363727574696e697a6572267374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/sierratecnologia/transmissor/)[![Travis](https://camo.githubusercontent.com/33065921e0de274f269899a1ea2136b4e7296962c6bd10047dc2e450332d868c/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f7369657272617465636e6f6c6f6769612f7472616e736d6973736f722e7376673f6c6162656c3d5472617669734349267374796c653d666c61742d737175617265)](https://travis-ci.org/sierratecnologia/transmissor)[![StyleCI](https://camo.githubusercontent.com/4191b35d1ee7b0da2e27c1fe2bd612ce3dfe1673a64523a762f99155892e2142/68747470733a2f2f7374796c6563692e696f2f7265706f732f36303936383838302f736869656c64)](https://styleci.io/repos/60968880)[![License](https://camo.githubusercontent.com/8f1a5e82f49a14918be8af19c15474a8275e9a979f78f537c6d510c6d6a74dc1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f7369657272617465636e6f6c6f6769612f7472616e736d6973736f722e7376673f6c6162656c3d4c6963656e7365267374796c653d666c61742d737175617265)](https://github.com/sierratecnologia/Transmissor/blob/master/LICENSE)

Table of Contents
-----------------

[](#table-of-contents)

- [Overview](#overview)
- [Features](#features)
- [Requirements](#requirements)
- [Installation](#installation)
- [Configuration](#configuration)
- [Usage](#usage)
    - [Notifications](#notifications)
    - [User Messaging](#user-messaging)
    - [Activity Logging](#activity-logging)
    - [Webhooks](#webhooks)
- [Facades](#facades)
- [API Reference](#api-reference)
- [Testing](#testing)
- [Changelog](#changelog)
- [Support](#support)
- [Contributing &amp; Protocols](#contributing--protocols)
- [Security Vulnerabilities](#security-vulnerabilities)

Overview
--------

[](#overview)

**Transmissor** is a comprehensive messaging and notification library for Laravel applications. It provides a unified interface for managing user notifications, internal messaging systems, activity logging, and webhook handling. The package integrates seamlessly with Laravel's notification system and extends it with additional features like threaded messaging, user activity tracking, and real-time notifications.

Features
--------

[](#features)

- **User Notifications System**: Create, manage, and deliver notifications to users with support for multiple channels
- **Internal Messaging**: Complete threaded messaging system with support for groups, participants, and message history
- **Activity Logging**: Track user activities and system events with detailed request information
- **Webhook Management**: Handle incoming webhooks with support for various integrations
- **Real-time Broadcasting**: Built-in support for Laravel Broadcasting channels
- **Flexible Policies**: Includes authorization policies for threads, topics, and replies
- **Multiple Database Support**: Compatible with MySQL, PostgreSQL, SQLite, and SQL Server
- **API Ready**: Includes API controllers and resources for RESTful implementations
- **Helper Functions**: Convenient helper functions for quick access to features
- **Cacheable Eloquent Models**: Performance optimization through model caching
- **Laravel Integration**: Seamless integration with Laravel's service container, facades, and events

Requirements
------------

[](#requirements)

- PHP 7.2 or higher (PHP 8.0+ supported)
- Laravel 5.5 or higher (Laravel 8.x supported)
- Dependencies:
    - `sierratecnologia/muleta` ^0.4.0
    - `sierratecnologia/crypto` ^0.4.0
    - `sierratecnologia/integrations` ^0.4.0
    - `sierratecnologia/porteiro` ^0.4.0
    - `sierratecnologia/population` ^0.4.0
    - `sierratecnologia/locaravel` ^0.4.0
    - `sierratecnologia/telefonica` ^0.4.0

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

[](#installation)

Install the package via Composer:

```
composer require sierratecnologia/transmissor
```

The package will automatically register its service provider thanks to Laravel's package auto-discovery.

### Publish Configuration and Assets

[](#publish-configuration-and-assets)

Publish the configuration files:

```
php artisan vendor:publish --provider="Transmissor\TransmissorProvider" --tag="config"
```

Publish views (optional):

```
php artisan vendor:publish --provider="Transmissor\TransmissorProvider" --tag="views"
```

Publish translations (optional):

```
php artisan vendor:publish --provider="Transmissor\TransmissorProvider" --tag="lang"
```

### Run Migrations

[](#run-migrations)

The package includes migrations for notifications, messages, threads, and related tables:

```
php artisan migrate
```

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

[](#configuration)

After publishing, you'll find the configuration file at `config/sitec/transmissor.php`. While the default configuration is empty (allowing you to use defaults), you can customize various aspects of the package.

### Available Configuration Options

[](#available-configuration-options)

```
return [
    // Add custom configuration here if needed
];
```

Usage
-----

[](#usage)

### Notifications

[](#notifications)

The Transmissor package extends Laravel's notification system with additional features.

#### Creating Notifications

[](#creating-notifications)

You can create notifications programmatically using the `NotificationService`:

```
use Transmissor\Services\NotificationService;

$notificationService = app(NotificationService::class);

// Send a notification to a specific user
$notificationService->notify(
    $userId,
    'info', // flag: info, warning, error, success
    'Welcome to Transmissor',
    'This is a detailed notification message.'
);

// Create a notification with full control
$notificationService->create([
    'user_id' => $userId,
    'flag' => 'success',
    'title' => 'Task Completed',
    'details' => 'Your task has been completed successfully.',
]);

// Broadcast to all users (user_id = 0)
$notificationService->create([
    'user_id' => 0,
    'flag' => 'announcement',
    'title' => 'System Maintenance',
    'details' => 'Scheduled maintenance on Sunday.',
]);
```

#### Retrieving Notifications

[](#retrieving-notifications)

```
// Get all notifications (paginated)
$notifications = $notificationService->paginated();

// Get notifications for a specific user
$userNotifications = $notificationService->userBased($userId);

// Get paginated notifications for a user
$userNotifications = $notificationService->userBasedPaginated($userId);

// Search notifications
$results = $notificationService->search('keyword', $userId);

// Find by UUID
$notification = $notificationService->findByUuid($uuid);
```

#### Managing Notifications

[](#managing-notifications)

```
// Mark as read
$notificationService->markAsRead($notificationId);

// Update a notification
$notificationService->update($notificationId, [
    'title' => 'Updated Title',
    'details' => 'Updated details',
]);

// Delete a notification
$notificationService->destroy($notificationId);
```

#### Using the Notification Facade

[](#using-the-notification-facade)

```
use Transmissor\Facades\Notifications;

// Access notification service methods through the facade
Notifications::notify($userId, 'info', 'Title', 'Details');
```

### User Messaging

[](#user-messaging)

Transmissor includes a complete messaging system based on threads and participants.

#### Models

[](#models)

- **Thread**: Represents a conversation
- **Message**: Individual messages within a thread
- **Participant**: Users participating in a thread

#### Creating a Message Thread

[](#creating-a-message-thread)

```
use Transmissor\Models\Messenger\Thread;
use Transmissor\Models\Messenger\Message;
use Transmissor\Models\Messenger\Participant;

// Create a new thread
$thread = Thread::create([
    'subject' => 'Discussion Topic',
]);

// Add the first message
$message = Message::create([
    'thread_id' => $thread->id,
    'user_id' => auth()->id(),
    'body' => 'Hello! This is the first message.',
]);

// Add participants
$thread->addParticipant($userId);
$thread->addParticipants([$userId1, $userId2, $userId3]);
```

#### Using the Messagable Trait

[](#using-the-messagable-trait)

Add the trait to your User model:

```
use Transmissor\Traits\Messagable;

class User extends Authenticatable
{
    use Messagable;

    // Your user model code...
}
```

Now you can use messaging methods directly on user instances:

```
// Get all threads for a user
$threads = $user->threads();

// Get unread messages count
$unreadCount = $user->unreadMessagesCount();

// Check if user is participant in a thread
$isParticipant = $user->isParticipantInThread($threadId);
```

#### Retrieving Messages

[](#retrieving-messages)

```
// Get all threads
$threads = Thread::getAllLatest();

// Get threads for current user
$userThreads = Thread::forUser(auth()->id());

// Get messages in a thread
$messages = $thread->messages;

// Get latest message
$latestMessage = $thread->latestMessage;

// Get participants
$participants = $thread->participants;
```

### Activity Logging

[](#activity-logging)

Track user activities and system events throughout your application.

#### Using the Activity Service

[](#using-the-activity-service)

```
use Transmissor\Services\ActivityService;

$activityService = app(ActivityService::class);

// Log an activity
$activityService->log('User viewed dashboard');

// Get activities for a user
$activities = $activityService->getByUser($userId);

// Get paginated activities
$activities = $activityService->getByUser($userId, 25);
```

#### Using the Activity Helper

[](#using-the-activity-helper)

The package includes a convenient helper function:

```
// Log an activity anywhere in your application
activity('User completed checkout process');
activity('Admin updated settings');
```

#### Activity Middleware

[](#activity-middleware)

Apply the activity middleware to routes for automatic logging:

```
use Transmissor\Http\Middleware\Activity;

Route::middleware([Activity::class])->group(function () {
    // Your routes here
});
```

#### What Gets Logged

[](#what-gets-logged)

Each activity record includes:

- User ID
- Description
- Request details (URL, method, query string, IP address, payload)
- Timestamp

### Webhooks

[](#webhooks)

Handle incoming webhooks from external services.

#### Webhook Controller

[](#webhook-controller)

The package includes controllers for webhook handling:

```
use Transmissor\Http\Controllers\Webhook\StoreController;
use Transmissor\Http\Controllers\WebhookReceivedController;
```

#### Webhook Jobs

[](#webhook-jobs)

Process webhooks asynchronously with included job classes:

```
use Transmissor\Jobs\Webhook\UptimeCheckFailed;
use Transmissor\Jobs\Webhook\BrokenLinksFound;
```

#### Creating Custom Webhook Handlers

[](#creating-custom-webhook-handlers)

```
namespace App\Jobs;

use Transmissor\Jobs\Webhook\UptimeCheckFailed;

class HandleUptimeAlert extends UptimeCheckFailed
{
    public function handle()
    {
        // Your custom webhook handling logic
        $payload = $this->webhookCall->payload;

        // Process the webhook data
        // Send notifications, update database, etc.
    }
}
```

Facades
-------

[](#facades)

The package provides convenient facades for quick access to services:

### Transmissor Facade

[](#transmissor-facade)

```
use Transmissor\Facades\Transmissor;

// Access the main Transmissor service
Transmissor::method();
```

### Notifications Facade

[](#notifications-facade)

```
use Transmissor\Facades\Notifications;

// Access notification service methods
Notifications::notify($userId, 'info', 'Title', 'Details');
```

### Activity Facade

[](#activity-facade)

```
use Transmissor\Facades\Activity;

// Access activity service methods
Activity::log('User performed action');
```

API Reference
-------------

[](#api-reference)

### NotificationService Methods

[](#notificationservice-methods)

MethodParametersDescription`all()`-Get all notifications`paginated()`-Get paginated notifications`userBased($id)``$id` (int)Get all notifications for a user`userBasedPaginated($id)``$id` (int)Get paginated notifications for a user`search($input, $id)``$input` (string), `$id` (intnull)`notify($userId, $flag, $title, $details)``$userId` (int), `$flag` (string), `$title` (string), `$details` (string)Create and send a notification`create($input)``$input` (array)Create a notification`find($id)``$id` (int)Find notification by ID`findByUuid($uuid)``$uuid` (string)Find notification by UUID`update($id, $input)``$id` (int), `$input` (array)Update a notification`markAsRead($id)``$id` (int)Mark notification as read`destroy($id)``$id` (int)Delete a notification### ActivityService Methods

[](#activityservice-methods)

MethodParametersDescription`getByUser($userId, $paginate)``$userId` (int), `$paginate` (intnull)`log($description)``$description` (string)Create an activity log entry### Thread Model Methods

[](#thread-model-methods)

MethodParametersDescription`getAllLatest()`-Get all threads ordered by latest activity`forUser($userId)``$userId` (int)Get threads for a specific user`addParticipant($userId)``$userId` (int)Add a participant to the thread`addParticipants($userIds)``$userIds` (array)Add multiple participants`removeParticipant($userId)``$userId` (int)Remove a participant`markAsRead($userId)``$userId` (int)Mark thread as read for userTesting
-------

[](#testing)

The package includes comprehensive tests for all major features.

### Running Tests

[](#running-tests)

```
# Run all tests
composer test

# Run tests with coverage
composer test-coverage
```

### Test Structure

[](#test-structure)

```
tests/
├── Feature/
│   └── NotificationIntegrationTest.php
├── Unit/
│   └── NotificationServiceTest.php
└── ActivityServiceTest.php

```

Changelog
---------

[](#changelog)

Refer to the [Changelog](CHANGELOG.md) for a full history of the project.

Support
-------

[](#support)

The following support channels are available at your fingertips:

- [Chat on Slack](https://bit.ly/sierratecnologia-slack)
- [Help on Email](mailto:help@sierratecnologia.com.br)
- [Follow on Twitter](https://twitter.com/sierratecnologia)

Contributing &amp; Protocols
----------------------------

[](#contributing--protocols)

Thank you for considering contributing to this project! The contribution guide can be found in [CONTRIBUTING.md](CONTRIBUTING.md).

Bug reports, feature requests, and pull requests are very welcome.

- [Versioning](CONTRIBUTING.md#versioning)
- [Pull Requests](CONTRIBUTING.md#pull-requests)
- [Coding Standards](CONTRIBUTING.md#coding-standards)
- [Feature Requests](CONTRIBUTING.md#feature-requests)
- [Git Flow](CONTRIBUTING.md#git-flow)

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

[](#security-vulnerabilities)

If you discover a security vulnerability within this project, please send an e-mail to [help@sierratecnologia.com.br](help@sierratecnologia.com.br). All security vulnerabilities will be promptly addressed.

About SierraTecnologia
----------------------

[](#about-sierratecnologia)

SierraTecnologia is a software solutions startup, specialized in integrated enterprise solutions for SMEs established in Rio de Janeiro, Brazil since June 2008. We believe that our drive The Value, The Reach, and The Impact is what differentiates us and unleash the endless possibilities of our philosophy through the power of software. We like to call it Innovation At The Speed Of Life. That’s how we do our share of advancing humanity.

License
-------

[](#license)

This is opensource package [The MIT License (MIT)](LICENSE).

(c) 2008-2020 SierraTecnologia, Permitimos a cópia sem restrições.

###  Health Score

35

—

LowBetter than 79% of packages

Maintenance47

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 98.8% 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 ~98 days

Recently: every ~299 days

Total

14

Last Release

848d ago

PHP version history (3 changes)0.0.1PHP ^7.3.0

0.5.x-devPHP ^7.4

0.4.3PHP ^7.2|^8.0

### Community

Maintainers

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

---

Top Contributors

[![ricardosierra](https://avatars.githubusercontent.com/u/5499444?v=4)](https://github.com/ricardosierra "ricardosierra (82 commits)")[![claude](https://avatars.githubusercontent.com/u/81847?v=4)](https://github.com/claude "claude (1 commits)")

---

Tags

laravelmessagingMessengeruser messagingSierraTecnologiatransmissor

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/sierratecnologia-transmissor/health.svg)

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

###  Alternatives

[cmgmyr/messenger

Simple user messaging tool for Laravel

2.6k2.4M6](/packages/cmgmyr-messenger)[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9682.1M97](/packages/roots-acorn)[laravel-zero/framework

The Laravel Zero Framework.

3371.4M369](/packages/laravel-zero-framework)[tzsk/sms

A robust and unified SMS gateway integration package for Laravel, supporting multiple providers.

320244.3k6](/packages/tzsk-sms)[lexxyungcarter/chatmessenger

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

10724.1k](/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.2k](/packages/syntaxlexx-chatmessenger)

PHPackages © 2026

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