hello, i have a quest about when handler recive a Result, the api docs seem out put empty(expect string) a aide apirouter ```rs use super::handler; use aide::axum::{ApiRouter, routing::*}; pub fn register() -> ApiRouter { let test_router = ApiRouter::new() .api_route( "/session_save", get(handler::session_save), ); ApiRouter::new().nest_api_service("/test", test_router) } ``` when out put session with string with wrapper HttpResult ```rs pub async fn session_save() -> http::HttpResult<String> { http::response_200(Some(format!("{} session saved ", total)), None) } ``` http result implment ```rs pub type HttpResult<T> = Result<SResponseBasic<T>, HttpInternalError>; #[derive(Debug, Clone, JsonSchema)] pub struct SResponseBasic<T> { pub body: Option<T>, #[schemars(skip)] pub status_code: Option<StatusCode>, pub msg: Option<String>, } impl<T> IntoResponse for SResponseBasic<T> where T: Serialize + Clone + JsonSchema + Send, { fn into_response(self) -> Response<Body> { let status_code = self.status_code.unwrap_or(StatusCode::OK); let response_data = SReponseStruct { success: status_code == StatusCode::OK, data: self.body, msg: self.msg.unwrap_or("success".to_string()), }; Json(response_data).into_response() } } impl<T> OperationOutput for SResponseBasic<T> where T: Serialize + Clone + Send + JsonSchema + 'static, { type Inner = SResponseBasic<T>; } #[derive(Serialize, Deserialize, JsonSchema)] pub struct HttpInternalError(String); impl IntoResponse for HttpInternalError { fn into_response(self) -> Response { (StatusCode::INTERNAL_SERVER_ERROR, Json(self.0)).into_response() } } impl OperationOutput for HttpInternalError { type Inner = Infallible; } ``` but empty was output <img width="441" height="177" alt="Image" src="https://github.com/user-attachments/assets/adf3d7b9-be49-4089-9cbc-bc334c0e0eca" /> SResponseBasic also implement IntoResponse
Activity
joebnb commentedon Oct 17, 2025
would any one give me some suggest, im stuck on this
AstrickHarren commentedon Oct 19, 2025
I think you need to use
get_withinstead ofget