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
    • ChatMember
    • ChatMemberEntity
    • ChatMessage
    • ChatMessageEntity
  • PubSub
    • Overview
    • Client
      • Events
    • PubSubMessage
  • WebRTC
    • Overview
LogoLogoSignalWire Docs
Log inSign up
Support
On this page
  • Events
  • message
  • session.expiring
PubSubClient

Events

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

disconnect

Next
Built with

The PubSub.Client object emits the events listed below. You can work with these events using the following methods:

on

Subscribe to an event

once

Subscribe to an event once

off

Unsubscribe from an event

removeAllListeners

Remove all event listeners

Events

message

  • message(message)

A new message has been received.

Properties
message
PubSubMessage<PubSubMessageContract toc={true}>Required

The received message. See PubSubMessage for more details.


session.expiring

  • session.expiring()

The session is going to expire. Use the updateToken method to refresh your token.