Authorizing Requests

Many times you would need a user authorization system for some requests. Api Auto Pilot gives you that ability, using the power of Laravel Policiesopen in new window.

Api Auto Pilot, treats Policies, in the exact same way as the Laravel framework does. You can register your existing Policies in the App\Providers\AuthServiceProvider in the $policies array , or you can follow the naming convention and let the policy be auto-discovered, by the package.


To invoke a policy, using the Api Auto Pilot package, the endpoint must have some type of authentication for the api consumer. For example, the endpoints should be protected with Sanctumopen in new window or Passportopen in new window or any kind of authentication system.

Last Updated:
Contributors: GeorgeFourkas