use crate::BilibiliRequest;
use crate::BpiResult;
use crate::creativecenter::CreativeCenterClient;
use serde_json::json;
impl<'a> CreativeCenterClient<'a> {
pub async fn dynamic_delete(&self, dyn_id: &str) -> BpiResult<Option<serde_json::Value>> {
let csrf = self.client.csrf()?;
self.client
.post("https://api.bilibili.com/x/dynamic/feed/operate/remove")
.query(&[("csrf", csrf)])
.json(&json!({
"dyn_id_str": dyn_id
}))
.send_bpi_optional_payload("creativecenter.dynamic.delete")
.await
}
pub async fn article_delete(&self, aid: u64) -> BpiResult<Option<serde_json::Value>> {
let csrf = self.client.csrf()?;
self.client
.post("https://member.bilibili.com/x/web/article/delete")
.form(&[("aid", aid.to_string()), ("csrf", csrf)])
.send_bpi_optional_payload("creativecenter.article.delete")
.await
}
}