It might be sensible to remove messages from users that have been timed out or banned, or messages that have been deleted individually from chat by a moderator.
Depending on the content, and because even moderators can make mistakes, maybe a facility to restore some could be helpful, too (probably not a high priority).
Channel bans and unbans are easy enough to deal with. Timeouts are the same event, but with a timestamp saying when it expires.
Finding out if a user was globally banned/suspended sadly requires subscribing to channel.update on EventSub for each user, prior to this happening and checking /helix/users if you get a "user does not exist" response whenever you receive such an update event, which I can't say is ideal. Detecting a global unban is even worse, because only polling /helix/users will get you that...
It might be sensible to remove messages from users that have been timed out or banned, or messages that have been deleted individually from chat by a moderator.
Depending on the content, and because even moderators can make mistakes, maybe a facility to restore some could be helpful, too (probably not a high priority). Channel bans and unbans are easy enough to deal with. Timeouts are the same event, but with a timestamp saying when it expires. Finding out if a user was globally banned/suspended sadly requires subscribing to
channel.update
on EventSub for each user, prior to this happening and checking/helix/users
if you get a "user does not exist" response whenever you receive such an update event, which I can't say is ideal. Detecting a global unban is even worse, because only polling/helix/users
will get you that...