Skip to content

Conversation

@dennisrijsdijk
Copy link
Collaborator

@dennisrijsdijk dennisrijsdijk commented Nov 12, 2025

Description of the Change

This PR adds additional logic for shared chat, including a cache for the shared chat session which is updated on chat connect and when Twitch sends an EventSub event for shared chat started, updated or ended
The following variables are added:

  • isSharedChatEnabled
  • sharedChatParticipants
  • sharedChatSourceDisplayName
  • sharedChatSourceUserId
  • sharedChatSourceUser
  • sharedChatSourceUsername

Applicable Issues

#2846

Testing

Ensured Firebot starts

Ensured Firebot connects to chat

Ensured variables appear in variables menu

Ensured when starting a shared chat session, the shared chat participants are loaded into the cache and available through variables

Ensured isSharedChatEnabled and sharedChatParticipants variables are always available

Ensured sharedChatSourceUser, sharedChatSourceUsername, sharedChatSourceDisplayName and sharedChatSourceUserId are only available in chat messages and chat message events

Ensured all above variables resolve to correct data (eg. correct source channel, correct shared chat state)

Ensured when connecting to chat, the current shared chat session is fetched and loaded into the cache

Ensured the Shared Chat Session Started event fires when a shared chat session is started

Ensured the Shared Chat Session Updated event fires when a streamer joins or leaves the shared chat session

Ensured the Shared Chat Session Ended event fires when the shared chat session is ended

@dennisrijsdijk
Copy link
Collaborator Author

In the meantime, can I also get a review on the desired behavior for variables when a shared chat user is not found? Currently they return null. Should I do something like [No User Found] instead? Or maybe default to the broadcaster, considering they'd be the default source channel if there is no shared chat session.

@dennisrijsdijk dennisrijsdijk marked this pull request as ready for review November 14, 2025 17:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant