pub struct Topics<'a> { /* private fields */ }Implementations§
Source§impl<'a> Topics<'a>
impl<'a> Topics<'a>
Sourcepub async fn empty_spam(&self) -> Result<(), Error>
pub async fn empty_spam(&self) -> Result<(), Error>
Empty the spam box. Runs synchronously, so it can take a while on a large mailbox.
Sourcepub async fn empty_trash(&self) -> Result<(), Error>
pub async fn empty_trash(&self) -> Result<(), Error>
Empty the trash. Runs synchronously, so it can take a while on a large mailbox.
Sourcepub async fn get_entries(
&self,
topic_id: i64,
params: &GetTopicEntriesParams,
) -> Result<Page<GetTopicEntriesResponseContent>, Error>
pub async fn get_entries( &self, topic_id: i64, params: &GetTopicEntriesParams, ) -> Result<Page<GetTopicEntriesResponseContent>, Error>
Get entries for a topic
Sourcepub async fn get_everything(
&self,
params: &GetEverythingTopicsParams,
) -> Result<Page<GetEverythingTopicsResponseContent>, Error>
pub async fn get_everything( &self, params: &GetEverythingTopicsParams, ) -> Result<Page<GetEverythingTopicsResponseContent>, Error>
Get all topics (everything view)
Sourcepub async fn get_sent(
&self,
params: &GetSentTopicsParams,
) -> Result<Page<GetSentTopicsResponseContent>, Error>
pub async fn get_sent( &self, params: &GetSentTopicsParams, ) -> Result<Page<GetSentTopicsResponseContent>, Error>
Get sent topics
Sourcepub async fn get_spam(
&self,
params: &GetSpamTopicsParams,
) -> Result<Page<GetSpamTopicsResponseContent>, Error>
pub async fn get_spam( &self, params: &GetSpamTopicsParams, ) -> Result<Page<GetSpamTopicsResponseContent>, Error>
Get spam topics
Sourcepub async fn get_trash(
&self,
params: &GetTrashTopicsParams,
) -> Result<Page<GetTrashTopicsResponseContent>, Error>
pub async fn get_trash( &self, params: &GetTrashTopicsParams, ) -> Result<Page<GetTrashTopicsResponseContent>, Error>
Get trash topics
Sourcepub async fn mark_ham(&self, topic_id: i64) -> Result<(), Error>
pub async fn mark_ham(&self, topic_id: i64) -> Result<(), Error>
Mark a spam topic as ham. Every other spam topic from the same sender is hammed too.
Sourcepub async fn move_topic(
&self,
topic_id: i64,
body: &MoveTopicRequestContent,
) -> Result<(), Error>
pub async fn move_topic( &self, topic_id: i64, body: &MoveTopicRequestContent, ) -> Result<(), Error>
Move a topic to another box.
Answers 204 without moving anything when the acting user has no posting for the topic.
Source§impl Topics<'_>
impl Topics<'_>
Sourcepub async fn move_to_box(&self, topic_id: i64, box_id: i64) -> Result<(), Error>
pub async fn move_to_box(&self, topic_id: i64, box_id: i64) -> Result<(), Error>
Moves a topic to a box, by the box’s id. The generated Topics::move_topic takes
the request body; this takes the one thing it carries.
Sourcepub async fn trash_topic(
&self,
topic_id: i64,
confirm_destroy: bool,
) -> Result<(), Error>
pub async fn trash_topic( &self, topic_id: i64, confirm_destroy: bool, ) -> Result<(), Error>
Trashes a topic.
HEY will not trash a shared topic without being asked twice: it answers the removal confirmation page instead, which comes back here as a usage error rather than as a trashing that quietly did nothing. Confirming trashes the topic and removes your access to it.
The generated Topics::trash sends the same request from its parts, and follows
that redirect rather than reading it.