Add the "Dismiss Notification" endpoint

master
Paul Woolcock 5 years ago
parent f41253241e
commit 817e18fc16
  1. 1
      src/lib.rs
  2. 4
      src/mastodon_client.rs

@ -239,6 +239,7 @@ impl<H: HttpSend> MastodonClient<H> for Mastodon<H> {
(post (uri: Cow<'static, str>,)) follows: "follows" => Account, (post (uri: Cow<'static, str>,)) follows: "follows" => Account,
(post multipart (file: Cow<'static, str>,)) media: "media" => Attachment, (post multipart (file: Cow<'static, str>,)) media: "media" => Attachment,
(post) clear_notifications: "notifications/clear" => Empty, (post) clear_notifications: "notifications/clear" => Empty,
(post (id: &str,)) dismiss_notification: "notifications/dismiss" => Empty,
(get) get_push_subscription: "push/subscription" => Subscription, (get) get_push_subscription: "push/subscription" => Subscription,
(delete) delete_push_subscription: "push/subscription" => Empty, (delete) delete_push_subscription: "push/subscription" => Empty,
(get) get_filters: "filters" => Vec<Filter>, (get) get_filters: "filters" => Vec<Filter>,

@ -120,6 +120,10 @@ pub trait MastodonClient<H: HttpSend = HttpSender> {
fn clear_notifications(&self) -> Result<Empty> { fn clear_notifications(&self) -> Result<Empty> {
unimplemented!("This method was not implemented"); unimplemented!("This method was not implemented");
} }
/// POST /api/v1/notifications/dismiss
fn dismiss_notification(&self, id: &str) -> Result<Empty> {
unimplemented!("This method was not implemented");
}
/// GET /api/v1/accounts/:id /// GET /api/v1/accounts/:id
fn get_account(&self, id: &str) -> Result<Account> { fn get_account(&self, id: &str) -> Result<Account> {
unimplemented!("This method was not implemented"); unimplemented!("This method was not implemented");

Loading…
Cancel
Save