feat: add reusable gallery carousel and ranking feed infrastructure
This commit is contained in:
@@ -21,6 +21,23 @@ Route::middleware(['web', 'throttle:10,1'])
|
||||
->whereNumber('id')
|
||||
->name('api.art.download');
|
||||
|
||||
// ── Ranking lists (public, throttled, Redis-cached) ─────────────────────────
|
||||
// GET /api/rank/global?type=trending|new_hot|best
|
||||
// GET /api/rank/category/{id}?type=trending|new_hot|best
|
||||
// GET /api/rank/type/{contentType}?type=trending|new_hot|best
|
||||
Route::prefix('rank')->name('api.rank.')->middleware(['throttle:60,1'])->group(function () {
|
||||
Route::get('global', [\App\Http\Controllers\Api\RankController::class, 'global'])
|
||||
->name('global');
|
||||
|
||||
Route::get('category/{id}', [\App\Http\Controllers\Api\RankController::class, 'byCategory'])
|
||||
->whereNumber('id')
|
||||
->name('category');
|
||||
|
||||
Route::get('type/{contentType}', [\App\Http\Controllers\Api\RankController::class, 'byContentType'])
|
||||
->where('contentType', '[a-z0-9\-]+')
|
||||
->name('content_type');
|
||||
});
|
||||
|
||||
/**
|
||||
* API v1 routes for Artworks module
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user