2024-02-29 18:09:17 +01:00
|
|
|
<?php
|
|
|
|
|
|
|
|
use Illuminate\Support\Facades\Route;
|
2024-03-07 19:04:52 +01:00
|
|
|
use App\Http\Controllers\API\AuthAPIController;
|
2024-03-07 22:42:11 +01:00
|
|
|
use App\Http\Controllers\API\PageAPIController;
|
2024-03-11 23:32:38 +01:00
|
|
|
use App\Http\Controllers\API\FileUploadAPIController;
|
2024-03-19 22:34:01 +01:00
|
|
|
use App\Http\Controllers\API\SettingsAPIController;
|
2024-02-29 18:09:17 +01:00
|
|
|
|
|
|
|
/*
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
| API Routes
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
| Here is where you can register API routes for your application. These
|
|
|
|
| routes are loaded by the RouteServiceProvider and all of them will
|
|
|
|
| be assigned to the "api" middleware group. Make something great!
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
2024-03-07 22:42:11 +01:00
|
|
|
//check if session is active
|
2024-03-07 19:04:52 +01:00
|
|
|
Route::get("/v1/status", [AuthAPIController::class, 'status']);
|
2024-03-12 23:16:36 +01:00
|
|
|
//handle page editing actions
|
2024-03-07 22:42:11 +01:00
|
|
|
Route::put("/v1/page/write", [PageAPIController::class, 'write']);
|
2024-03-12 23:16:36 +01:00
|
|
|
Route::post("/v1/page/create", [PageAPIController::class, 'create']);
|
|
|
|
//handle file uploads
|
2024-03-11 23:32:38 +01:00
|
|
|
Route::post("/v1/files", [FileUploadAPIController::class, 'upload']);
|
2024-03-19 22:34:01 +01:00
|
|
|
//settings
|
|
|
|
Route::put("/v1/settings/publish", [SettingsAPIController::class, 'publish']);
|