diff --git a/src/sbot.rs b/src/sbot.rs index 4ff8608..341ee03 100644 --- a/src/sbot.rs +++ b/src/sbot.rs @@ -153,6 +153,23 @@ impl Sbot { self.publish(msg).await } + + + /// Get the about messages for a particular user. + pub async fn get_about_messages(&mut self, ssb_id: String) -> Result { + let req_id = self.client.getsubset_req_send(query).await?; + + utils::get_async_until_eof(&mut self.rpc_reader, req_id, utils::kvt_res_parse).await + } + + + /// Get the latest description for a particular user from their about messages. + pub async fn get_description(&mut self, ssb_id: String) -> Result { + let req_id = self.client.getsubset_req_send(query).await?; + + utils::get_async_until_eof(&mut self.rpc_reader, req_id, utils::kvt_res_parse).await + } + /// Call the `createHistoryStream` RPC method and return a vector /// of SsbMessageValue. pub async fn create_history_stream(