feat: implement OpenAPI spec for bots and root

This commit is contained in:
Paul Makles
2022-03-18 21:22:31 +00:00
parent a0926eea32
commit 14e17b10c0
14 changed files with 290 additions and 63 deletions

View File

@@ -1,4 +1,5 @@
use rocket::Route;
use rocket_okapi::okapi::openapi3::OpenApi;
mod create;
mod delete;
@@ -8,8 +9,8 @@ mod fetch_owned;
mod fetch_public;
mod invite;
pub fn routes() -> Vec<Route> {
routes![
pub fn routes() -> (Vec<Route>, OpenApi) {
openapi_get_routes_spec![
create::create_bot,
invite::invite_bot,
fetch_public::fetch_public_bot,