Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

sk8rboi7566's avatar

Pusher Event Not Firing on API endpoint

I have set pusher as the new broadcast_driver and followed the set up instructions by Pusher. I added the event to my api endpoint. The logs are showing it being occupied and subscribed to the channel. But when i send a post event to that api endpoint the event is not being fired. I cleared my cache, views. served the application again and re bundled my files.

API ENDPOINT:

event(new IncomingText('hello world'));

Event:

class IncomingText implements ShouldBroadcast
{
    use Dispatchable, InteractsWithSockets, SerializesModels;

    public $message;

    public function __construct($message)
    {
        $this->message = $message;
    }

    public function broadcastOn()
    {
        return ['my-channel'];
    }

    public function broadcastAs()
    {
        return 'my-event';
    }
}
0 likes
0 replies

Please or to participate in this conversation.