For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Log inSign up
Support
ReferenceGuidesClick-to-Call
ReferenceGuidesClick-to-Call
  • Core
    • Overview
  • SignalWire Client
    • Overview
    • Notifications
    • Client
    • Utility functions
  • Video
    • Overview
    • LocalOverlay
    • RoomSession
    • RoomSessionDevice
    • RoomSessionPlayback
    • RoomSessionRecording
    • RoomSessionScreenShare
    • RoomSessionStream
    • RoomDevice
    • RoomScreenShare
  • Chat
    • Overview
    • Client
      • Events
        • disconnect
        • getAllowedChannels
        • getMembers
        • getMemberState
        • getMessages
        • off
        • on
        • once
        • publish
        • removeAllListeners
        • setMemberState
        • subscribe
        • unsubscribe
        • updateToken
    • ChatMember
    • ChatMemberEntity
    • ChatMessage
    • ChatMessageEntity
  • PubSub
    • Overview
    • Client
    • PubSubMessage
  • WebRTC
    • Overview
LogoLogoSignalWire Docs
Log inSign up
Support
On this page
  • Parameters
  • Returns
  • Example
ChatClientMethods

setMemberState

|View as Markdown|Open in Claude|
Was this page helpful?
Edit this page
Previous

subscribe

Next
Built with
  • setMemberState(params): Promise<void>

Sets a state object for a member, for the specified channels. The previous state object will be completely replaced.

Parameters

params
objectRequired

Configuration object for setting member state

params.channels
string | string[]Required

Channels for which to set the state.

params.memberId
stringRequired

Id of the member to affect. If not provided, defaults to the current member.

params.state
Record<any, any toc={true}>Required

The state to set. There are no requirements on the content of the state.

Returns

Promise<void>

Example

1await chatClient.setMemberState({
2 channels: ["chan1", "chan2"],
3 state: {
4 online: true,
5 typing: false,
6 },
7});