staskjs / laravel-faye
Laravel package for faye
Installs: 114
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/staskjs/laravel-faye
Requires
- guzzlehttp/guzzle: ^6.2
This package is not auto-updated.
Last update: 2025-09-28 11:24:42 UTC
README
Installation
composer require staskjs/laravel-faye
On laravel 5.5+ skip this point, but on lower versions register service provider in config/app.php
:
Staskjs\LaravelFaye\LaravelFayeServiceProvider::class
Then register faye broadcasting service in config/broadcasting.php
:
'connections' => [
'faye' => [
'driver' => 'faye',
],
],
In your .env
file define url to api and api token:
FAYE_URL=http://localhost:3001
FAYE_SENDER_NAME=my-sender-name
Also in .env
set default broadcast driver to faye
:
BROADCAST_DRIVER=faye
Usage
Create events and use built-in broadcasting though events.
Sender name will be used as prefix to all channels. For example, in sender name is
my-sender-name
and channel is /users
, then final channel will be /my-sender-name/users
.