File: D:/HostingSpaces/Eurotools/euro-tools.nl/app/KommaApp/Shop/Catalog/catalogRoutes.php
<?php
use App\KommaApp\Shop\Catalog\Kms\CatalogService;
Route::get('kms/catalog/index', CatalogService::class.'@createIndex'); //Note that this route hits a service. This is expected as it is hit from an artisan command and a future "index" button in the kms.
Route::get('/search', CatalogService::class.'@search')->name('catalog.search');
Route::get('/kms/catalog/reindexSearch', function () {
CatalogService::reIndexSearch();
echo 'Done!';
});