title: Automatically export subscribers using Mailchimp in Laravel
body: <p>I am making an admin area as an easy way to keep track of my subscribers. All I want is to display and update their email address every time someone new subscribes to my list. As shown below I want the email addresses to go under email. I am sure there is some sort of code that I need to use to get subscriber information and display it, but I am not sure where to get it. I am using the laravel package <a href="https://github.com/skovmand/mailchimp-laravel" rel="nofollow noreferrer">https://github.com/skovmand/mailchimp-laravel</a></p>
  
  <p><a href="https://i.stack.imgur.com/O8FPQ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/O8FPQ.png" alt="enter image description here"></a></p>
  
  <p>Here is my mailchimp conbtroller:</p>
  
  <pre><code>&lt;?php
  
  namespace App\Http\Controllers;
  
  use Illuminate\Http\Request;
  
  use App\Http\Requests;
  
  class MailChimpController extends Controller
  {
      public $mailchimp;
      public $listId = '111111111';
  
      public function __construct(\Mailchimp $mailchimp)
      {
          $this-&gt;mailchimp = $mailchimp;
      }
  
      public function manageMailChimp()
      {
          return view('mailchimp');
      }
  
      public function subscribe(Request $request)
      {
          $this-&gt;validate($request, [
              'email' =&gt; 'required|email',
          ]);
  
          try {
  
  
              $this-&gt;mailchimp
              -&gt;lists
              -&gt;subscribe(
                  $this-&gt;listId,
                  ['email' =&gt; $request-&gt;input('email')]
              );
  
              return redirect()-&gt;back()-&gt;with('success','Email Subscribed successfully');
  
          } catch (\Mailchimp_List_AlreadySubscribed $e) {
              return redirect()-&gt;back()-&gt;with('error','Email is Already Subscribed');
          } catch (\Mailchimp_Error $e) {
              return redirect()-&gt;back()-&gt;with('error','Error from MailChimp');
          }
      }
  }
  </code></pre>
  
  <p>and here is my admin.blade.php file I want the email addresses to be displayed.</p>
  
  <pre><code>@extends('layouts.app')
  
  @section('content')
  &lt;div class="container"&gt;
      &lt;h1 class="text-center"&gt;Subscribers&lt;/h1&gt;
      &lt;table class="table"&gt;
          &lt;thead&gt;
              &lt;tr&gt;
                  &lt;th&gt;Check&lt;/th&gt;
                  &lt;th&gt;Email&lt;/th&gt;
                  &lt;th&gt;City&lt;/th&gt;
                  &lt;th&gt;Airport&lt;/th&gt;
              &lt;/tr&gt;
              &lt;tbody&gt;
                  &lt;tr&gt;
                      &lt;td&gt;&lt;/td&gt;
                  &lt;/tr&gt;
              &lt;/tbody&gt;
          &lt;/thead&gt;
  
      &lt;/table&gt;
  &lt;/div&gt;
  @endsection
  </code></pre>
  
  <p>Let me know if there is anything else I need. Any help would be appreciated!</p>