Data/name-api/v1.1/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] [&country=country] [&language=language] [&formatid=formatid] [&imagecount=imagecount] [&imageoffset=imageoffset] [&imagesize=imagesize] [&imagesort=imagesort] [&imagetypeid=imagetypeid] [&zoomlevel=zoomlevel]

Request Example 1

Request images of Leonard Bernstein.

Request Example 2

Request images that are in the range of 70 to 100 pixels in both dimensions.

Request Example 3

Request two JPGs of The Doors that fit a bounding box of 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, 32-hex-digit authorization code. To perform the calculation, execute the MD5 function on the concatenation of the following three ASCII 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.

Express the alpha hex digits as lower case.

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
country No Country the language parameter applies to. 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. Select the format IDs you want from the Format IDs table.

Specify multiple format IDs in a comma-separated list, like this: formatid=36,44,51.

Returned images meet a combination of all of the following specified filters:

  • formatid
  • imagesize
  • imagetypeid
  • zoomlevel
imagecount No Number of images to be returned. If fewer images are available, the available images are returned without error. The default is 25.

Use imagecount and imageoffset to paginate the response.

imageoffset No Number of images at the start of the response to skip. The default is zero.

Use imagecount and imageoffset to paginate the response. These parameters execute last, after any filtering and sorting parameters.

imagesize No Image sizes to be returned. Images are not dynamically resized to fit, so only available sizes are returned.
  • Specify an exact size in width x height format, like this: imagesize=332x419.
  • Specify a size range in width x height format, like this: imagesize=60-80x80-100.
  • Specify multiple sizes in a comma-separated list, like this: imagesize=332x419,60-80x80-100.

Returned images meet a combination of all of the following specified filters:

  • formatid
  • imagesize
  • imagetypeid
  • zoomlevel
imagesort No Sort order of returned images. Images can be sorted in ascending or descending order by the following properties:
  • width
Image width.
  • height
Image height.
  • formatid
Image format ID, as shown in the Format IDs table.
  • author
Person or company that took the photo.
  • copyrightowner  
Company that owns the image copyright.
  • url
URL to the image (ASCII sort).

Specify a descending sort order with a minus (-) sign, like this: imagesort=-width.
Specify a multilevel sort in highest-to-lowest order in a comma-separated list, like this: imagesort=formatid,-height,width.

Note: A request cannot include both the multi and imagesort parameters.

imagetypeid No Image type of returned images. Select the IDs you want from the Image Type IDs table.

Specify multiple image type IDs in a comma-separated list, like this: imagetypeid=4,6. Image types are returned in the order shown in the Image Order table.

Returned images meet a combination of all of the following specified filters:

  • formatid
  • imagesize
  • imagetypeid
  • zoomlevel
language No Language of the response data. This request supports only en (English).
multi No How to score images against multiple filters and multiple filter values. Applies to formatid, imagetype, and zoomlevel. Default is balanced.
This value . . .Decrements the score for each value in a list . . .
balancedIn equal proportion to the number of values. For four values, the score decrements by 25 percent. For three, by 33 percent.
fuzzyIn less than equal proportion to the number of values, decreasing the importance of the first value. For four values, the score decrements by less than 25 percent.
targetedIn more than equal proportion to the number of values, increasing the importance of the first value. For four values, the score decrements by more than 25 percent.
diminishedLess for the first parameter in the request and more for the last. For this option, list your parameters in order of importance.
zoomlevel No How close up people in the image appear. Select the zoom level you want from the Image Zoom Level table.

Specify multiple zoom levels in a comma-separated list, like this: zoomlevel=2,3.

Returned images meet a combination of all of the following specified filters:

  • formatid
  • imagesize
  • imagetypeid
  • zoomlevel

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.
parametersparametersThe parameters that were 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, which 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, which asks for two JPGs of The Doors that fit a bounding box of 250 pixels in one or both dimensions. The response is formatted with extra spaces and carriage returns to make it easy to read.
Requested with http://api.rovicorp.com/data/v1.1/name/images?apikey=apikey&sig=sig&
nameid=MN0000114342&formatid=44&imagecount=2
.
{
   "status":"ok",
   "code":200,
   "messages":null,
   "build":"1.0",
   "parameters":{
      "apiKey":"4p1k3y",
      "id":"MN0000114342",
      "format":"json",
      "formatid":"44",
      "imageCount":"2"
   },
   "view":{
      "offset":0,
      "count":2,
      "total":2
   },
   "serverName":"tul1cssrcs6.corporate.local",
   "startTime":"2012-08-28T17:29:03Z",
   "endTime":"2012-08-28T17:29:03Z",
   "duration":8,
   "parentIds":{
      "amgClassicalId":"Q    99625",
      "amgMovieId":"P 19698",
      "amgPopId":"P     4119",
      "nameId":"MN0000114342"
   },
   "images":[
      {
         "override":false,
         "musicSort":0,
         "height":123,
         "width":250,
         "formatid":44,
         "url":"http://actual-url-concealed.jpg",
         "author":null,
         "copyrightOwner":null,
         "imageTypeId":3,
         "zoomLevel":2
      },
      {
         "override":false,
         "musicSort":0,
         "height":157,
         "width":250,
         "formatid":44,
         "url":"http://actual-url-concealed.jpg",
         "author":"Edmund Teske",
         "copyrightOwner":null,
         "imageTypeId":3,
         "zoomLevel":2
      }
   ]
}

XML Response Example

Here's an XML response to Request Example 3, which asks for two JPGs of The Doors that fit a bounding box of 250 pixels in one or both dimensions.
Requested with http://api.rovicorp.com/data/v1.1/name/images?apikey=apikey&sig=sig&
nameid=MN0000114342&formatid=44&imagecount=2&format=xml
.
<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.0</build>
    <parameters>
        <apiKey>4p1k3y</apiKey>
        <id>MN0000114342</id>
        <format>xml</format>
        <formatid>44</formatid>
        <imageCount>2</imageCount>
    </parameters>
    <view>
        <offset>0</offset>
        <count>2</count>
        <total>2</total>
    </view>
    <serverName>tul1cssrcs3.corporate.local</serverName>
    <startTime>2012-08-28T17:33:29Z</startTime>
    <endTime>2012-08-28T17:33:29Z</endTime>
    <duration>6</duration>
    <parentIds>
        <amgClassicalId>Q    99625</amgClassicalId>
        <amgMovieId>P 19698</amgMovieId>
        <amgPopId>P     4119</amgPopId>
        <nameId>MN0000114342</nameId>
    </parentIds>
    <images>
        <Image>
            <override>false</override>
            <musicSort>0</musicSort>
            <height>123</height>
            <width>250</width>
            <formatid>44</formatid>
            <url>http://actual-url-concealed.jpg</url>
            <author i:nil="true" />
            <copyrightOwner i:nil="true" />
            <imageTypeId>3</imageTypeId>
            <zoomLevel>2</zoomLevel>
        </Image>
        <Image>
            <override>false</override>
            <musicSort>0</musicSort>
            <height>157</height>
            <width>250</width>
            <formatid>44</formatid>
            <url>http://actual-url-concealed.jpg</url>
            <author>Edmund Teske</author>
            <copyrightOwner i:nil="true" />
            <imageTypeId>3</imageTypeId>
            <zoomLevel>2</zoomLevel>
        </Image>
    </images>
</NameImages>


See Also

↑ Top

Personal tools