title: How do I move a request to API in laravel?
body: <p>I can't seem to find an answer on the web or maybe I'm missing something.</p>
  
  <p>Let's say my laravel application domain is <code>my-laravel.com</code></p>
  
  <p>Now I want to make requests at <code>api.my-laravel.com</code> which will work just same as <code>my-laravel.com/api/</code></p>
  
  <p>How do I do that?</p>
  
  <p>Solution: Changed <code>prefix('api')</code> to <code>domain('api.my-laravel.com')</code> in <code>RouteServiceProvider@mapApiRoutes</code></p>