Initialer Laravel Commit für BetiX
Some checks failed
linter / quality (push) Has been cancelled
tests / ci (8.4) (push) Has been cancelled
tests / ci (8.5) (push) Has been cancelled

This commit is contained in:
2026-04-04 18:01:50 +02:00
commit 0280278978
374 changed files with 65210 additions and 0 deletions

40
routes/operator.php Normal file
View File

@@ -0,0 +1,40 @@
<?php
use App\Http\Controllers\OperatorController;
use Illuminate\Support\Facades\Route;
/*
|--------------------------------------------------------------------------
| B2B Operator / Casino Integration Routes
|--------------------------------------------------------------------------
|
| These routes are loaded without the /api prefix by bootstrap/app.php,
| so they are available at /operator/* as documented.
|
| All routes are protected by the license.key middleware which:
| - Reads X-License-Key header OR license_key body/query field
| - Hashes the key and looks it up in operator_casinos
| - Checks the casino is active
| - Enforces IP whitelist if configured
| - Binds the OperatorCasino instance as $request->attributes->get('operator_casino')
|
*/
Route::middleware(['license.key'])->group(function () {
// Game catalog — list all available games with metadata
Route::get('/games', [OperatorController::class, 'games'])
->middleware('throttle:120,1')
->name('operator.games');
// Launch a game session for a player — returns launch_url + session_token
Route::post('/launch', [OperatorController::class, 'launch'])
->middleware('throttle:30,1')
->name('operator.launch');
// Query the current / final state of a session (balance delta, status)
Route::get('/session/{token}', [OperatorController::class, 'session'])
->middleware('throttle:120,1')
->where('token', '[0-9a-f\-]{36}')
->name('operator.session');
});