reorderContainer

Sonos uses reorderContainer to reorder content in a playlist. See Add playlists for details.

Request parameters

NameTypeDescription
idstring(128)Unique ID of the playlist.
fromstringList of comma-delimited indexes of the tracks to move. This field must be a list of comma-delimited indexes. These indexes are the current track positions in the playlist. The list can also include ranges. For example: 1,2,4-7.
tointIndex of the new position. As with from, this list can include ranges. You are required to provide a value for this parameter if you used the from parameter.
updateIdstring(128)Future implementation. This field can be used to handle editing collisions and data concurrency validation.

Response

NameTypeDescription
updateIdstring(128)Future implementation. Can be used to handle editing collisions and data concurrency validation.

Sample request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <reorderContainer xmlns="http://www.sonos.com/Services/1.1">
      <id>playlist-001</id>
      <from>1,3,5</from>
      <to>9</to>
      <updatedId />
    </reorderContainer>
  </soap:Body>
</soap:Envelope>

Sample response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <reorderContainerResponse xmlns="http://www.sonos.com/Services/1.1">
      <reorderContainerResult>
        <updateId />
      </reorderContainerResult>
    </reorderContainerResponse>
  </soap:Body>
</soap:Envelope>