title: Laravel 5.4 Pusher (laravel-echo) cannot access private channel
body: <p>I've been testing Laravel Echo and it works fine for non-private channels. I receive the data that gets passed through an event on that non-private channel. But the problem is when I set up the event to broadcast on a private channel I receive an error message as per the below:
  Note: I am logged in as a user as per the picture.
  <a href="https://i.stack.imgur.com/Qwevg.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Qwevg.png" alt="Private server error"></a></p>
  
  <p>As I'm subscribing to a private channel, in Laravel I went to config/app.php and uncommented ' App\Providers\BroadcastServiceProvider::class, '.
  Also went to App\Providers\BroadcastServiceProvider.php and used the code as per the picture below:
  <a href="https://i.stack.imgur.com/YGIwK.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/YGIwK.png" alt="BroadcastServiceProvider"></a></p>
  
  <p>My Resources/assets/js/bootstrap.js file have the following code and compiled using laravel mix:</p>
  
  <pre><code>import Echo from 'laravel-echo'
  window.Pusher = require('pusher-js');
  
  window.Echo = new Echo({
    broadcaster: 'pusher',
    key: 'hiddenkey',
    cluster: 'ap1',
    encrypted: true
   });
  
  window.Echo.private('chat-room.1')
        .listen('ChatMessageWasReceived', (e) =&gt; {
            console.log(e.user, e.chatMessage);
  });
  </code></pre>
  
  <p>btw i already installed all dependencies, ie:
  - composer require pusher/pusher-php-server ,
  - npm install --save laravel-echo pusher-js ,
  Also configured my config/broadcasting.php using the reference to .env file which have inputed all the information needed for pusher. Everything works fine as you can see for a non-private channel which i receive the data from the event as per the picture below:
  <a href="https://i.stack.imgur.com/KT2U9.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/KT2U9.png" alt="enter image description here"></a></p>
  
  <p>Here is the event i created:
  <a href="https://i.stack.imgur.com/kVHKy.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/kVHKy.png" alt="Event"></a></p>
  
  <p>I am receiving the private channel, event and data as per the picture:
  <a href="https://i.stack.imgur.com/1W7OM.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/1W7OM.png" alt="enter image description here"></a></p>
  
  <p>Why even if i am a signed-in authenticated user, and in the BroadcastServiceProvider.php file i am returning true to the  <code>Broadcast::channel()</code> method, i don't see the data passed from my event? i receive data from non-private channel, so why not in a private-channel? What are my doing wrong? why do I get these errors in my console and not the data:</p>
  
  <pre><code>- POST http://example.dev/broadcasting/auth 500 (Internal Server Error)
  - Pusher : Couldn't get auth info from your webapp : 500
  </code></pre>
  
  <p>BTW I was following this tutorial until I got stuck with private channel:
      <a href="https://mattstauffer.co/blog/introducing-laravel-echo" rel="nofollow noreferrer">https://mattstauffer.co/blog/introducing-laravel-echo</a></p>