New Sonos Integrator

Sonos Integrator — Feature Overview

Sonos Integrator is a new, fully local Sonos integration.
To install, go to Integrations, + Add Integration, then select Sonos Integrator (immediatly below the legacy Sonos Integration).
The legacy Sonos Integration will be depreciated at the completion of beta and will not be avaiable for new installations.

Local discovery and reliability

  • Discovers Sonos players through mDNS.
  • Tracks IP-address changes and updates Hubitat's LAN routing without replacing the device.
  • Recovers from failed commands with a targeted liveness check and a bounded rediscovery request.
  • Uses Sonos event subscriptions for normal state updates instead of continuous discovery or active polling.
  • Reports player connectivity through the Hubitat NetworkDevice capability and networkStatus attribute.
  • Serializes discovery, descriptor verification, subscription recovery, and refresh work to avoid excessive hub load.
  • Refreshes and restores subscriptions automatically when a player or hub restarts.
  • Synchronizes Sonos room-name changes back to the Hubitat device label.

Player control

  • Play, pause, stop, next track, previous track, and seek.
  • Independent player volume, volume adjustment, mute, and unmute.
  • Retains setLevel compatibility for existing Hubitat automations.
  • Track title and artist through trackDescription.
  • Track URI, position, duration, playback state, and volume state.
  • Reports unavailable track position or duration as unknown rather than stale data.
  • Shuffle control.
  • Repeat modes: Off, Repeat One, and Repeat All.
  • Crossfade control.
  • Optional hardware status-light control.

Favorites and Sonos playlists

  • Reads the household's current Sonos Favorites.
  • Presents Favorites in a dynamic command list on each player device.
  • Supports direct radio and streaming Favorites.
  • Supports Sonos playlists saved as Favorites by loading the playlist into the Sonos queue and starting at track one.
  • Makes Favorite selection available to Rule Machine and other apps through a custom command parameter.

Text-to-speech and audio notifications

  • Supports Hubitat speech synthesis, notification, playText, and restore-style audio commands.
  • Queues overlapping TTS requests and plays them in order instead of interrupting the announcement already in progress.
  • Captures and restores the previous source, queue track, playback position, playing or paused state, volume, mute state, and group topology.
  • Restores music at its previous position after an announcement instead of abandoning the prior stream or queue.
  • Provides a configurable TTS volume boost or cut.
  • Supports explicit announcement volume where provided by the Hubitat command.
  • Provides an optional 0, 15, 30, or 60-second TTS startup delay on Sonos Port, Connect, and Amp players, allowing attached audio equipment time to power up.

Sonos groups

  • Tracks live Sonos group topology, including coordinators and members.
  • Immediately respects groups created, changed, or removed in the Sonos app.
  • Learns Sonos-created groups automatically as saved group presets.
  • Supports named group presets that can be created, renamed, edited, and deleted in the integration app.
  • Activates an existing preset directly from the integration's main page.
  • Exposes an Activate Group Preset command on physical player devices with a dynamic list of presets containing that room.
  • Makes the player used to activate a preset the group's coordinator and content source.
  • Routes group playback commands through the current coordinator.
  • Keeps normal volume and mute control available for each physical player within a group.
  • Adds setGroupVolume, adjustGroupVolume, muteGroup, and unmuteGroup commands to physical player devices.
  • Sends TTS invoked on a coordinator to the whole group.
  • Temporarily detaches a member for member-only TTS, then restores that member to its previous group without interrupting the coordinator's content.
  • Uses friendly room and preset names in the UI while retaining RINCON identifiers internally.
  • Does not require permanent virtual group devices, so transient Sonos groups cannot leave orphaned Hubitat devices behind.

Sonos Port, Connect, and Amp support

A separate input-capable player driver adds Hubitat's Media Input Source capability while retaining the normal Sonos player commands.

  • Dynamically lists the input sources actually available to the player.
  • Supports Music, Line-In, and TV sources where the hardware exposes them.
  • Exposes line-input connection state when Sonos reports it.
  • Allows the current input's display name to be edited without changing the underlying Sonos source code.
  • Accepts the stable source number or its friendly display name from automations.
  • Can optionally restore the previous Sonos queue, track position, and playback state when switching back from a physical input to Music.
  • Provides Fixed or Variable line-out level selection, initialized from the player's current setting.
  • Provides line-input gain choices from 0.0 dB through +11.3 dB.
  • Provides Line-In Auto Play On or Off control.
  • Provides the equipment-startup TTS delay described above.

Hubitat app and automation support

  • Separate app pages for player discovery/import, group-preset activation, and group-preset management.
  • Discovered players are shown by friendly room name and model rather than IP address or RINCON ID.
  • Blank or abandoned group-preset drafts are not saved.
  • Dynamic command lists are populated when the device page is opened, making current Favorites, input sources, and group presets available in the device UI.
  • Custom commands and their parameter lists are available to Rule Machine.

Migration from the built-in Sonos Integration

  • Detects the installed Hubitat legacy Sonos Integration app without confusing it with similarly named user apps.
  • Offers migration only when an enabled legacy integration is present.
  • Migrates existing player devices in place and preserves their Hubitat numeric device IDs.
  • Preserves existing Rule Machine rules and app device references because the original device records are retained.
  • Selects the standard or input-capable driver according to the Sonos model.
  • Reparents the existing devices to Sonos Integrator and updates their current network endpoints.
  • Disables and quiesces the legacy integration without immediately uninstalling it.
  • Saves a migration manifest and provides a Restore Legacy option.
  • Warns about players added only after migration; these do not block restoration and remain with the new integration.
  • Excludes Hub Mesh linked devices from local migration.

Design goals

  • Fully local operation.
  • Event-driven state updates with minimal background traffic.
  • Stable player identity across DHCP address changes.
  • Transparent coexistence with grouping changes made in the Sonos app.
  • Reliable TTS that does not sacrifice the listener's current music, position, or group arrangement.
  • Automation-friendly commands without creating disposable group devices.
18 Likes