use crate::{
AppState,
controllers::{api_keys, auth, posts, security},
};
use utoipa_axum::{router::OpenApiRouter, routes};
pub fn router() -> OpenApiRouter<AppState> {
OpenApiRouter::new()
.routes(routes!(auth::welcome))
.routes(routes!(auth::show_login, auth::login))
.routes(routes!(auth::show_register, auth::register))
.routes(routes!(auth::logout))
.routes(routes!(auth::show_verify_email))
.routes(routes!(auth::verify_email))
.routes(routes!(auth::resend_verification))
.routes(routes!(auth::show_forgot, auth::forgot))
.routes(routes!(auth::show_reset_form))
.routes(routes!(auth::reset))
.routes(routes!(auth::dashboard))
.routes(routes!(posts::index, posts::store))
.routes(routes!(posts::create))
.routes(routes!(posts::edit))
.routes(routes!(posts::update, posts::destroy))
.routes(routes!(api_keys::index, api_keys::store))
.routes(routes!(api_keys::revoke))
.routes(routes!(security::index))
.routes(routes!(security::revoke_grant))
.routes(routes!(security::revoke_device))
.routes(routes!(security::logout_everywhere))
.routes(routes!(security::change_password))
.routes(routes!(security::delete_account))
}