ncm_api_rs/api/topic_detail.rs
1use super::Query;
2use crate::error::Result;
3/// 话题详情
4/// 对应 Node.js module/topic_detail.js
5use crate::request::{ApiClient, ApiResponse, CryptoType};
6use serde_json::json;
7
8impl ApiClient {
9 /// 话题详情
10 /// 对应 /topic/detail
11 pub async fn topic_detail(&self, query: &Query) -> Result<ApiResponse> {
12 let data = json!({
13 "actid": query.get_or("actid", "")
14 });
15 self.request("/api/act/detail", data, query.to_option(CryptoType::Weapi))
16 .await
17 }
18}