Sonos players support audio play modes including shuffle, repeat, and crossfade. Your app can receive notifications for changes with the playbackStatus event and set the current play modes with the setPlayModes command.

The playMode type defines the functionality of one or more play modes. Play modes are either enabled or disabled. Sonos supports the following play modes:

Play modeFunctionality when enabled
repeatRepeat tracks. When playback reaches the end of the current queue of tracks, playback will wrap around and continue from the beginning of the queue.
repeatOneRepeat the current track indefinitely until this mode is disabled or your app explicitly changes the playhead position to a different track, for example, by skipping to the next track, a previous track, or a specific track in a cloud queue.
shufflePlay the tracks in the queue in a randomly shuffled order.
crossfadeFade out and mix the end of a track with the start of the next track as it is being faded in, creating a crossfade effect.