Loheide-eu-mitarbeiterplatt.../plugins-core/ideen/routes/api.php
Friederich Loheide f9922f7308
Some checks failed
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 6m49s
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 7m19s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 7m29s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 7m39s
CI / PHP 8.3 / mysql:8.0 (pull_request) Failing after 9m38s
CI / PHP 8.4 / mysql:8.0 (pull_request) Failing after 9m25s
CI / PHP 8.4 / mysql:8.4 (pull_request) Failing after 7m57s
CI / PHP 8.3 / mysql:8.4 (pull_request) Failing after 8m4s
CI / Bekannte Sicherheitslücken in Paketen (pull_request) Successful in 46s
CI / Build-Artefakte aktuell (pull_request) Successful in 1m9s
Ideenbox-Moderation und Wochenüberblick per E-Mail (0.36.0)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-27 15:17:47 +00:00

15 lines
804 B
PHP

<?php
use Illuminate\Support\Facades\Route;
use Inhaus\Plugins\Ideen\Http\Controllers\IdeaController;
// /api/v1/ideas … (Token nötig, siehe docs/API.md)
Route::controller(IdeaController::class)->group(function () {
Route::get('/ideas', 'index');
Route::post('/ideas', 'store')->middleware('throttle:10,60');
Route::get('/ideas/{idea}', 'show')->whereNumber('idea');
Route::post('/ideas/{idea}/support', 'support')->whereNumber('idea')->middleware('throttle:60,1');
Route::delete('/ideas/{idea}/support', 'unsupport')->whereNumber('idea')->middleware('throttle:60,1');
Route::post('/ideas/{idea}/report', 'report')->whereNumber('idea')->middleware('throttle:20,60');
Route::post('/ideas/{idea}/comments', 'comment')->whereNumber('idea')->middleware('throttle:20,1');
});