fix api routing and config paths

This commit is contained in:
2026-07-16 12:17:47 +02:00
parent ccd91b4f0f
commit fa663a6a6c
5 changed files with 22 additions and 11 deletions
+3 -3
View File
@@ -44,9 +44,9 @@ if (strpos($request->path(), '/api/') === 0) {
}
// register routes (path without version prefix)
$router->get('/users', 'UsersController@index');
$router->post('/users', 'UsersController@create');
$router->get('/example', 'ExampleController@test');
$router->get('/users/index', 'UsersController@index');
$router->post('/users/create', 'UsersController@create');
$router->get('/example/test', 'ExampleController@test');
// Rate limiting by IP address
$key = $_SERVER['REMOTE_ADDR'] ?? 'unknown';