You should name your routes so every route has a unique name. For instance, we do something like:
Route::middleware('api')
->domain('api.example.test')
->name('api::')
->group(base_path('routes/api.php'));
// later in the routes file
Route::prefix('software')
->name('software.')
->group(function () {
Route::get(
'version-report',
[SoftwareVersionReportController::class, 'index'],
)->name('version-report');
and then the route would be
route('api::software.version-report')
Along similar lines, you could use app:: to denote routes in your main web app.