feat: wrap-up REST API endpoints
This commit is contained in:
@@ -7,6 +7,7 @@ mod social;
|
||||
mod users;
|
||||
mod watchlist;
|
||||
mod webhook;
|
||||
mod wrapup;
|
||||
|
||||
use axum::Router;
|
||||
use utoipa::{
|
||||
@@ -42,6 +43,7 @@ fn build() -> utoipa::openapi::OpenApi {
|
||||
api.merge(search::SearchDoc::openapi());
|
||||
api.merge(watchlist::WatchlistDoc::openapi());
|
||||
api.merge(webhook::WebhookDoc::openapi());
|
||||
api.merge(wrapup::WrapUpDoc::openapi());
|
||||
#[cfg(feature = "federation")]
|
||||
api.merge(social::SocialDoc::openapi());
|
||||
SecurityAddon.modify(&mut api);
|
||||
|
||||
18
crates/presentation/src/openapi/wrapup.rs
Normal file
18
crates/presentation/src/openapi/wrapup.rs
Normal file
@@ -0,0 +1,18 @@
|
||||
use utoipa::OpenApi;
|
||||
|
||||
#[derive(OpenApi)]
|
||||
#[openapi(
|
||||
paths(
|
||||
crate::handlers::wrapup::post_generate,
|
||||
crate::handlers::wrapup::get_list,
|
||||
crate::handlers::wrapup::get_status,
|
||||
crate::handlers::wrapup::get_report,
|
||||
),
|
||||
components(schemas(
|
||||
api_types::wrapup::GenerateWrapUpRequest,
|
||||
api_types::wrapup::WrapUpGeneratedResponse,
|
||||
api_types::wrapup::WrapUpStatusResponse,
|
||||
api_types::wrapup::WrapUpListResponse,
|
||||
))
|
||||
)]
|
||||
pub struct WrapUpDoc;
|
||||
Reference in New Issue
Block a user