Skip to content

Commit

Permalink
Update notification.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
wsxiaoys authored Dec 13, 2024
1 parent a804122 commit 32d7faa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ee/tabby-schema/src/schema/notification.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,12 @@ pub struct Notification {

#[async_trait]
pub trait NotificationService: Send + Sync {
/// Create notification
async fn create(&self, recipient: NotificationRecipient, content: &str) -> Result<ID>;

/// List notifications
async fn list(&self, user_id: &ID) -> Result<Vec<Notification>>;

/// Mark notification as read for user
async fn mark_read(&self, user_id: &ID, id: Option<&ID>) -> Result<()>;
}

0 comments on commit 32d7faa

Please sign in to comment.