ncm_api_rs/api/
hot_topic.rs1use super::Query;
2use crate::error::Result;
3use crate::request::{ApiClient, ApiResponse, CryptoType};
6use serde_json::json;
7
8impl ApiClient {
9 pub async fn hot_topic(&self, query: &Query) -> Result<ApiResponse> {
12 let data = json!({
13 "limit": query.get_or("limit", "20").parse::<i64>().unwrap_or(20),
14 "offset": query.get_or("offset", "0").parse::<i64>().unwrap_or(0)
15 });
16 self.request("/api/act/hot", data, query.to_option(CryptoType::Weapi))
17 .await
18 }
19}