create api controller laravel code example
Example 1: Laravel 8 Resource
php artisan make:controller BlogController --resource
Example 2: controller in laravel 8
Rout::get('/test' , [TestController::class , 'index']);
php artisan make:controller BlogController --resource
Rout::get('/test' , [TestController::class , 'index']);