diff options
author | Trygve Aaberge <trygveaa@gmail.com> | 2023-10-01 22:22:36 +0200 |
---|---|---|
committer | Trygve Aaberge <trygveaa@gmail.com> | 2024-02-18 11:32:54 +0100 |
commit | 39c0cdc15645b6f82d2feff015c249535a66976d (patch) | |
tree | 10a121fcd48cd91e8f72b5730f09d2f6491a7602 /typings/slack_rtm | |
parent | b4211c69b4a2b0099a1ad18c569c0df36abac8b2 (diff) | |
download | wee-slack-39c0cdc15645b6f82d2feff015c249535a66976d.tar.gz |
Mark buffer as read when conversation/thread is marked
Diffstat (limited to 'typings/slack_rtm')
-rw-r--r-- | typings/slack_rtm/slack_rtm_message.pyi | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/typings/slack_rtm/slack_rtm_message.pyi b/typings/slack_rtm/slack_rtm_message.pyi index 01c3f9c..548e695 100644 --- a/typings/slack_rtm/slack_rtm_message.pyi +++ b/typings/slack_rtm/slack_rtm_message.pyi @@ -144,6 +144,60 @@ class SlackReactionRemoved(TypedDict): event_ts: str ts: str +class SlackNotImMarked(TypedDict): + channel: str + ts: str + unread_count: int + unread_count_display: int + num_mentions: int + num_mentions_display: int + mention_count: int + mention_count_display: int + event_ts: str + +@final +class SlackChannelMarked(SlackNotImMarked): + type: Literal["channel_marked"] + +@final +class SlackGroupMarked(SlackNotImMarked): + type: Literal["group_marked"] + is_mpim: Literal[False] + +@final +class SlackMpImMarked(SlackNotImMarked): + type: Literal["mpim_marked"] + is_mpim: Literal[True] + +@final +class SlackImMarked(TypedDict): + type: Literal["im_marked"] + channel: str + ts: str + dm_count: int + unread_count_display: int + num_mentions_display: int + mention_count_display: int + event_ts: str + +class SlackThreadSubscription(TypedDict): + type: Literal["thread"] + channel: str + thread_ts: str + date_create: int + active: bool + last_read: str + +# Dummy event to make sure we check that subscription is of type thead when used +class SlackThreadSubscriptionUnknown(TypedDict): + type: Literal["unknown"] + +@final +class SlackThreadMarked(TypedDict): + type: Literal["thread_marked"] + subscription: SlackThreadSubscription | SlackThreadSubscriptionUnknown + event_ts: str + class SlackShRoomHuddle(TypedDict): channel_id: str @@ -197,6 +251,11 @@ SlackRtmMessage = ( | SlackMessageReplied | SlackReactionAdded | SlackReactionRemoved + | SlackChannelMarked + | SlackGroupMarked + | SlackMpImMarked + | SlackImMarked + | SlackThreadMarked | SlackShRoomJoin | SlackShRoomUpdate | SlackUserTyping |