title: API validation errors not showing In Laravel
body: <p>I am trying to make a post request to my Laravel post endpoint but I am not getting any validation errors.</p>
  
  <p><strong>Controller</strong></p>
  
  <pre class="lang-php prettyprint-override"><code>class LoginController extends Controller
  {
      public function adminLogin(AdminLoginRequest $request)
      {
          if (Auth::attempt([
              'email' =&gt; $request-&gt;get('email'), 'password' =&gt; $request-&gt;get('password'), 'role' =&gt; 'admin'
          ])) {
              $user = Auth::user();
              $success['token'] = $user-&gt;createToken('AppName')-&gt;accessToken;
              return response()-&gt;json(['success' =&gt; $success], 200);
          } else {
              return response()-&gt;json(['error' =&gt; 'Unauthorised'], 401);
          }
      }
  }
  </code></pre>
  
  <p><strong>API Route</strong></p>
  
  <pre class="lang-php prettyprint-override"><code>Route::post('/admin/jamisi/login', 'Api\Admin\Auth\LoginController@adminLogin');
  
  Route::middleware('auth:api')-&gt;get('/user', function (Request $request) {
      return $request-&gt;user();
  });
  </code></pre>
  
  <p><strong>AdminLoginRequest</strong></p>
  
  <pre><code>class AdminLoginRequest extends FormRequest
  {
      public function authorize()
      {
          return true;
      }
  
      public function rules()
      {
          return [
              'email' =&gt; 'required|email|unique:users',
              'password' =&gt; 'required'
          ];
      }
  
      public function messages()
      {
          return [
              'email.required' =&gt; 'The Email Field Is required.',
              'email.unique' =&gt; 'The Email Has Already Been Taken.',
              'password.required' =&gt; 'The Password Field Is Required',
          ];
      }
  
      protected function failedValidation(Validator $validator)
      {
          throw new HttpResponseException(response()-&gt;json($validator-&gt;errors(), 422));
      }
  }
  </code></pre>
  
  <p>When I try to test with Postman I get a '401 Unauthorised error.' The validation errors are not showing.</p>