Album & artist

When the listener selects the ellipsis (...) to see the Info View, Sonos sends the getExtendedMetadata request.

  • To add album information to the Info View, return an albumId value in your getExtendedMetadata response.
  • To add artist information to the Info View, return an artistId value in your getExtendedMetadata response.

The album and artist information displays as the last custom actions. The displayed text strings are fixed and cannot be modified.

Album and artist information for a song and an album.

Album and artist information for a song and an album.


Add album and artist information for a song

The following getExtendedMetadata response for a song includes albumId and artistId, which enable the Album Info and Browse the Artist custom actions.

<soap:Envelope xmlns:soap="<http://schemas.xmlsoap.org/soap/envelope/>">   
  <soap:Body>  
   <getExtendedMetadataResponse xmlns="http://www.sonos.com/Services/1.1">  
     <getExtendedMetadataResult>  
       <mediaMetadata>  
         <id>T:123456789</id>  
         <itemType>track</itemType>  
         <title>Example Track</title>  
         <mimeType>audio/mp3</mimeType>  
         <trackMetadata>  
           <artistId>A:123456</artistId>  
           <artist>Example Artist</artist>  
           <albumId>M:123456</albumid>  
           <album>Example Album</album>  
           <duration>343</duration>  
           <albumArtURI><http://example.com/images/aa/1.jpg></albumArtURI>  
           <canSkip>true</canSkip>  
           <canAddToFavorites>true</canAddToFavorites>  
         </trackMetadata>  
       </mediaMetadata>  
       . . . Details for other custom actions in the Info View not shown . . .  
     </getExtendedMetadataResult>  
   </getExtendedMetadataResponse>  
  </soap:Body>  
</soap:Envelope>

Add artist information for an album

The following getExtendedMetadata response for an album includes artistId, which enables the Browse the Artist custom action. The album information displays by default as View all Songs on Album when a listener is browsing an album.

<soap:Envelope xmlns:soap="<http://schemas.xmlsoap.org/soap/envelope/>">   
  <soap:Body>  
   <getExtendedMetadataResponse xmlns="http://www.sonos.com/Services/1.1">  
     <getExtendedMetadataResult>  
       <mediaCollection readonly="true">  
         <id>AL:123456</id>  
         <itemType>album</itemType>  
         <title>Example Album</title>  
         <artist>Example Artist</artist>  
         <artistId>A:123456</artistId>  
         <canScroll>false</canScroll>  
         <canPlay>true</canPlay>  
         <canEnumerate>true</canEnumerate>  
         <canAddToFavorites>true</canAddToFavorites>  
         <albumArtURI><http://example.com/images/aa/1.jpg></albumArtURI>  
       </mediaCollection>  
       . . . Details for other custom actions in the Info View not shown . . .  
     </getExtendedMetadataResult>  
   </getExtendedMetadataResponse>  
  </soap:Body>  
</soap:Envelope>