Notifications Services

class services.notifications.notification.NotificationService[source]

Bases: object

Notification Service

classmethod create(sender: User, receiver: User, post: Post | None, data: Dict[str, Any] | None, type: str) None[source]
classmethod mark_as_read_notification(user: User) None[source]
classmethod send_comment_notification(sender: User, receiver: User, post: Post, data: Dict[str, Any]) None[source]

Send commnet notification

classmethod send_follow_notification(sender: User, receiver: User) None[source]

Send follow notification

classmethod send_like_notification(sender: User, receiver: User, post: Post) None[source]

Send like notification

classmethod send_notification(receiver: User) None[source]
classmethod send_publish_followers_notification(sender: User, receiver: User, post: Post) None[source]

Send follower publish post notification

classmethod send_publish_notification(sender: User, receiver: User, post: Post) None[source]

Send publish notification