V1.MetaData.MusicService.Descriptor:SignificantCompositions

Jump to: navigation, search

Descriptor/SignificantCompositions

Returns the top compositions in the classical music genre and subgenres. By design, the list is limited to a maximum of 100 per genre or subgenre.

Significant compositions are defined for these genres and subgenres:

  • MA0000004505—Ballet
  • MA0000004501—Band Music
  • MA0000004500—Chamber Music
  • MA0000002521—Classical
  • MA0000004506—Show/Musical
  • MA0000004520—Vocal Music

Syntax

descriptor/significantcompositions?apikey=apikey&sig=sig&genreids=genreids [&format=format] [&offset=offset] [&count=count] [&country=country] [&language=language]

Request Example 1

Request the top compositions in the Chamber Music and Vocal Music subgenres.

Request Example 2

Request the top composition in the Chamber Music subgenre.

Request Example 3

Request the second top composition in the Chamber Music subgenre in an XML response.

Request Parameters

Sort none.gif  Click to re-sort

Parameter Required Description
apikey Yes Access code that authorizes your request for data from Rovi.
genreids Yes Genre ID or subgenre ID. You can get IDs of musical genres and subgenres from Descriptor/Genres or Descriptor/MusicGenres.

To specify multiple IDs, use a comma-separated list, like this: genreids=MA0000002467,MA0000002944.

sig Yes A calculated authorization code. To perform the calculation, execute the MD5 function on the concatenation of the following three strings:
  • Your API key.
  • The secret key you received with your API key.
  • The Unix time. Unix time is a timestamp supported in most development environments, and is generally defined as the number of seconds since January 1, 1970 00:00:00 GMT.

Perform the calculation at the time of each request to be sure it's within a five-minute window of the server time. If you're testing the call in a browser, use our online signature generator to perform the calculation.

count No Number of items to be returned. The default is zero, which returns all items after the offset.

Use count and offset to paginate the response.

country No Country of the language of the response. The current release of the API supports only US.
format No Format of the returned data: json or xml. The default is JSON.
language No Language of the response data. This request supports only en (English).
offset No Number of items at the start of the returned list to skip. The default is zero.

Use count and offset to paginate the response.

Response

Response Header

ResponseTypeDescription
buildStringThe software release level of the API.
codeIntegerHTTP status code. See the status field for the text part of the code.
durationIntegerServer processing time in milliseconds. The difference between startTime and endTime.
endTimeStringWhen the server sent the response (UTC time).
messagesMessage [ ]Elements of a multiple HTTP response status message.
parametersparametersList of the parameters included in the request.
serverNameStringName of the server that processed the request.
startTimeStringWhen the server received the request (UTC time).
statusStringText part of the HTTP status code that is shown in the code field.
viewviewSummary of items returned in a list of items.

Response for Descriptor/SignificantCompositions

ResponseTypeDescription
compositions SignificantComposition [ ] Top compositions in the genres and subgenres specified in the request.

JSON Response Example

Here's the response to Request Example 2. It is formatted with extra spaces and carriage returns to make it easy to read.
{
  "status":"ok",
  "code":200,
  "messages":null,
  "build":"1.5.1.9",
  "parameters":{
    "apiKey":"apikey",
    "id":"MA0000004500"
    "offset":0,
    "count":1
  },
  "view":{
    "offset":0,
    "count":1,
    "total":2
  },
  "serverName":"tul1cssw3",
  "startTime":"2011-04-29T01:03:36.1837414Z",
  "endTime":"2011-04-29T01:03:36.2149920Z",
  "duration":31,
  "compositions":[
    {
      "genre":{
        "id":"MA0000004500",
        "name":"Chamber Music"
      },
      "rank":9,
      "id":"MC0002376999",
      "title":"Serenade No. 13 for strings in G major (\"Eine kleine Nachtmusik\"), K. 525",
      "alternatetitle":"Eine kleine Nachtmusik, A Little Night Music",
      "composers":[
        {
          "id":"MN0000026350",
          "name":"Wolfgang Amadeus Mozart"
        }
      ],
      "genres":[
        {
          "id":"MA0000004499",
          "name":"Orchestral",
          "weight":10
        },
        {
          "id":"MA0000004500",
          "name":"Chamber Music",
          "weight":9
        },
        {
          "id":"MA0000002521",
          "name":"Classical",
          "weight":9
        }
      ],
      "periods":[
        {
          "id":"MA0000000081",
          "name":"Classical"
        }
      ]
    }
  ]
}

XML Response Example

Here's the response to Request Example 3.
<SignificantCompositions xmlns="com.rovicorp.metadataservice" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <status>ok</status>
  <code>200</code>
  <messages i:nil="true"/>
  <build>1.5.1.9</build>
  <parameters>
    <apiKey>apikey</apiKey>
    <id>MA0000004500</id>
    <offset>1</offset>
    <count>1</count>
    <format>xml</format>
  </parameters>
  <view>
    <offset>1</offset>
    <count>1</count>
    <total>2</total>
  </view>
  <serverName>tul1cssw1</serverName>
  <startTime>2011-04-29T01:03:22.3992472Z</startTime>
  <endTime>2011-04-29T01:03:22.4148723Z</endTime>
  <duration>15</duration>
  <compositions>
    <SignificantComposition>
      <genre>
        <id>MA0000004500</id>
        <name>Chamber Music</name>
      </genre>
      <rank>9</rank>
      <id>MC0002658097</id>
      <title>Serenade for winds &amp; strings in D minor, B. 77 (Op. 44)</title>
      <alternatetitle/>
      <composers>
        <CompositionComposer>
          <id>MN0000768609</id>
          <name>Antonin Dvorák</name>
        </CompositionComposer>
      </composers>
      <genres>
        <Genre>
          <id>MA0000004499</id>
          <name>Orchestral</name>
          <weight>10</weight>
        </Genre>
        <Genre>
          <id>MA0000004500</id>
          <name>Chamber Music</name>
          <weight>9</weight>
        </Genre>
        <Genre>
          <id>MA0000002521</id>
          <name>Classical</name>
          <weight>9</weight>
        </Genre>
      </genres>
      <periods>
        <CompositionPeriod>
          <id>MA0000000081</id>
          <name>Romantic</name>
        </CompositionPeriod>
      </periods>
    </SignificantComposition>
  </compositions>
</SignificantCompositions>


See Also

↑ Top

Personal tools