diff --git a/app/Config/routes.yaml b/app/Config/routes.yaml index 73951d3..b9f40c9 100644 --- a/app/Config/routes.yaml +++ b/app/Config/routes.yaml @@ -2,19 +2,23 @@ api_init: uri: /api/init controller: Controller\api\InitController httpMethod: [GET] +doc: + uri: /doc + controller: Controller\DocController + httpMethod: [GET] api_stations: uri: /api/stations controller: Controller\api\Station\StationsController httpMethod: [GET] api_station_id: - uri: /api/station/{id} + uri: '/api/station/{id}' controller: Controller\api\Station\StationIdController httpMethod: [GET] api_station_id_status: - uri: /api/station/{id}/status + uri: '/api/station/{id}/status' controller: Controller\api\Station\StationStatusIdController httpMethod: [GET] api_stations_status: uri: /api/stations/status controller: Controller\api\Status\StationsStatusController - httpMethod: [GET] \ No newline at end of file + httpMethod: [GET] diff --git a/app/Controller/DocController.php b/app/Controller/DocController.php new file mode 100644 index 0000000..7c2ba75 --- /dev/null +++ b/app/Controller/DocController.php @@ -0,0 +1,18 @@ +render('api/redoc.html'); + } +} diff --git a/app/Template/api/redoc.html b/app/Template/api/redoc.html new file mode 100644 index 0000000..0f3db5d --- /dev/null +++ b/app/Template/api/redoc.html @@ -0,0 +1,350 @@ + + + +
+ +Download OpenAPI specification:Download