Laravel Broadcast - Combining multiple middleware (web, auth:api)
问题 I am using Laravel Event Broadcast and Pusher to utilize websockets both on my API and Web. If I try them individually, both work fine. What I mean is: Broadcast::routes(['middleware' => 'web']); // this works for my Laravel website Broadcast::routes(['middleware' => 'auth:api']); // this works for my api However, if I want to use both at the same time like this: Broadcast::routes(['middleware' => ['auth:api', 'web']]); // doesn't work ... it crashes for both, which I suspect that it is