V1.MetaData.NameService.Name:Images

Jump to: navigation, search

Name/Images

Returns URLs to images of a person or group. Note: Access to images is governed by your subscription level and geographical location.

This request may return a large amount of data. To speed data transmission, do the following:

  • Request one page of data at a time, requesting only what you want to immediately display.
  • Request a compressed response by including Accept-Encoding: gzip,deflate in the HTTP header.

IMPORTANT: A photographer (author) credit for an image must be displayed with the image if available. For images from Getty Images, the full photographer/collection/owner credit must be displayed next to the image. If space prevents that, you may omit parts of the credit to show just Getty Images or Getty, provided the full credit is displayed at the next reasonable alternative location, even if that is on another screen, if that location exists.

Syntax

name/images? name=name
nameid=nameid
cosmoid=cosmoid
amgpopid=amgpopid
amgmovieid=amgmovieid
amgclassicalid=amgclassicalid
&apikey=apikey&sig=sig [&format=format] [&offset=offset] [&count=count] [&country=country] [&language=language] [&formatid=formatid]

Request Example 1

Request images of Leonard Bernstein.

Request Example 2

Request just the first two images in the list.

Request Example 3

Request the next two images.

Request Example 4

Request JPGs of The Doors that are 250 pixels in one or both dimensions.

Request Parameters

Sort none.gif  Click to re-sort

Parameter Required Description
apikey Yes Access code that authorizes your request for data from Rovi.
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.

amgclassicalid Conditional All Media Guide (AMG) ID for a classical music artist, consisting of a ten-character string that starts with Q and is followed by nine digits with leading spaces. For example: Q     9065.

When using an AMG Classical ID in a request, replace any spaces in the ID with plus (+) or percent20 (%20) symbols, like this: Q+++++9065. AMG is a legacy database of entertainment information.

Condition: The request must contain just one of these parameters:

  • name
  • nameid
  • cosmoid   
  • amgpopid
  • amgmovieid
  • amgclassicalid
amgmovieid Conditional All Media Guide (AMG) ID for a person who works in movies, consisting of a seven-character string that starts with P and is followed by 6 digits with leading spaces. For example: P 30474.

When using an AMG Movie ID in a request, replace any spaces in the ID with plus (+) or percent20 (%20) symbols, like this: P+30474.

Condition: The request must contain just one of these parameters:

  • name
  • nameid
  • cosmoid   
  • amgpopid
  • amgmovieid
  • amgclassicalid
amgpopid Conditional All Media Guide (AMG) ID for a popular music artist, consisting of a ten-character string that starts with P and is followed by 9 digits with leading spaces. For example: P    84363.

When using an AMG Pop ID in a request, replace any spaces in the ID with plus (+) or percent20 (%20) symbols, like this: P++++84363.

Condition: The request must contain just one of these parameters:

  • name
  • nameid
  • cosmoid   
  • amgpopid
  • amgmovieid
  • amgclassicalid
cosmoid Conditional Cosmo database ID for a person, group, or organization. You can get Cosmo IDs with Search requests. Cosmo is a database of television data.

Condition: The request must contain just one of these parameters:

  • name
  • nameid
  • cosmoid   
  • amgpopid
  • amgmovieid
  • amgclassicalid
name Conditional Name of the person or group. This returns the top search result for that name. Replace any spaces with plus (+) or percent20 (%20) symbols.

Condition: The request must contain just one of these parameters:

  • name
  • nameid
  • cosmoid   
  • amgpopid
  • amgmovieid
  • amgclassicalid
nameid Conditional Rovi Music ID for a person, group, or organization, consisting of the prefix MN followed by a ten-digit number. For example: MN0000114342. Your application can grab name IDs from responses to Search and from Info, Credits, Tracks, and Recommendations requests. For a complete list of requests that return name IDs, click here.

Condition: The request must contain just one of these parameters:

  • name
  • nameid
  • cosmoid   
  • amgpopid
  • amgmovieid
  • amgclassicalid
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.
formatid No Size and file format of returned images, as specified by format ID. Format IDs of images are shown in the Format IDs table. To select multiple format IDs, specify a comma-separated list like this formatid=36,44,51.
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.
parentIdsparentIdsAll of the IDs for the requested name that are recognized by the Name API.
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 Name/Images

ResponseTypeDescription
images Image [ ] URLs to pictures of the person or group along with information about the images.

JSON Response Example

Here's the response to Request Example 3. 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":"MN0000239859",
    "offset":2,
    "count":2
  },
  "view":{
    "offset":2,
    "count":2,
    "total":10
  },
  "serverName":"tul1cssw3",
  "startTime":"2011-04-28T21:10:54.7844738Z",
  "endTime":"2011-04-28T21:10:54.8000991Z",
  "duration":15,
  "parentIds":{
    "amgClassicalId":"Q    7057",
    "amgMovieId":"P 81651",
    "amgPopId":"P    910",
    "cosmoId":"105549",
    "nameId":"MN0000239859"
  },
  "images":[
    {
      "height":325,
      "width":250,
      "formatid":44,
      "url":"http:\/\/actual-url-concealed.jpg",
      "author":"",
      "copyrightOwner":""
    },
    {
      "height":520,
      "width":400,
      "formatid":64,
      "url":"http:\/\/actual-url-concealed.jpg",
      "author":"",
      "copyrightOwner":""
    }
  ]
}

XML Response Example

Here's an XML response to Request Example 3.
<NameImages 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>MN0000239859</id>
    <offset>2</offset>
    <count>2</count>
    <format>xml</format>
  </parameters>
  <view>
    <offset>2</offset>
    <count>2</count>
    <total>10</total>
  </view>
  <serverName>tul1cssw1</serverName>
  <startTime>2011-04-28T21:10:38.7693758Z</startTime>
  <endTime>2011-04-28T21:10:38.7693758Z</endTime>
  <duration>0</duration>
  <parentIds>
    <amgClassicalId>Q 7057</amgClassicalId>
    <amgMovieId>P 81651</amgMovieId>
    <amgPopId>P 910</amgPopId>
    <cosmoId>105549</cosmoId>
    <nameId>MN0000239859</nameId>
  </parentIds>
  <images>
    <Image>
      <height>325</height>
      <width>250</width>
      <formatid>44</formatid>
      <url>http://actual-url-concealed.jpg</url>
      <author/>
      <copyrightOwner/>
    </Image>
    <Image>
      <height>520</height>
      <width>400</width>
      <formatid>64</formatid>
      <url>http://actual-url-concealed.jpg</url>
      <author/>
      <copyrightOwner/>
    </Image>
  </images>
</NameImages>


See Also

↑ Top

Personal tools