Merge pull request #12538 from AndrewSav/develop
Added #12532: add version endpoint
This commit is contained in:
commit
ba461d0114
1 changed files with 11 additions and 1 deletions
|
@ -1162,6 +1162,17 @@ Route::group(['prefix' => 'v1', 'middleware' => ['api', 'throttle:api']], functi
|
|||
)->name('api.activity.index');
|
||||
}); // end reports api routes
|
||||
|
||||
/**
|
||||
* Version API routes
|
||||
*/
|
||||
|
||||
Route::get('/version', function () {
|
||||
return response()->json(
|
||||
[
|
||||
'version' => config('version.app_version'),
|
||||
], 200);
|
||||
}); // end version api routes
|
||||
|
||||
|
||||
Route::fallback(function () {
|
||||
return response()->json(
|
||||
|
@ -1172,5 +1183,4 @@ Route::group(['prefix' => 'v1', 'middleware' => ['api', 'throttle:api']], functi
|
|||
], 404);
|
||||
}); // end fallback routes
|
||||
|
||||
|
||||
}); // end API routes
|
||||
|
|
Loading…
Add table
Reference in a new issue