Skip to content

Twitch.UserBanned

A moderator bans someone.

  • Platform: twitch
  • Shape: userBanned
  • Source event: Twitch.UserBanned
Widget.on("Twitch.UserBanned", (event) => {
// event.user, event.platform…
});
  • user (string): Display name; «Anonymous» for anonymous gifts.
  • userId (string): User id on its platform.
  • userLogin (string): Login, lowercase.
  • reason (string): Reason, if any.
  • duration (number): Timeout seconds (0 for a ban).

It also carries platform (the source platform) and raw (the original payload).

The example payload that reaches the Studio simulator:

{
"moderator": {
"id": "100000002",
"login": "lunagamer",
"name": "LunaGamer",
"type": "twitch"
},
"broadcaster": {
"id": "100000000",
"login": "canaldeprueba",
"name": "CanalDePrueba",
"type": "twitch"
},
"isInSharedChat": false,
"isSharedChatHost": false,
"isFromSharedChatGuest": false,
"createdAt": "2026-09-26T05:52:36.7710946Z",
"isTest": false,
"targetUser": {
"id": "100000008",
"login": "spambot3000",
"name": "SpamBot3000",
"type": "twitch"
},
"reason": "Bot de spam"
}