Batch Celebrity Image URL Retrieval

Batch Celebrity Image URL Retrieval

Postby enternoescape » Thu Jun 22, 2017 4:37 am

I would like to know if we can add the ability to batch get celebrity images. (https://github.com/SchedulesDirect/JSON-Service/wiki/API-20141201#retrieving-images-for-a-particular-celebrity)

What I would like to be able to do is provide multiple celebrity personId's and get back either simply confirmation that images exist for each personId in the batch and which personId's or the same kind of data that is returned for one celebrity, but for multiple. The latter would probably be more useful since the former would likely just result in another query for the personId's that say they have images. Below is an idea about what that would look like.

A message would be posted to the following URL:
Code: Select all
POST https://json.schedulesdirect.org/20141201/metadata/celebrity


The body of the message would be something like this (the numbers correspond with personId's):
Code: Select all
["68293", "383774", "189517"]


The returned JSON would be something like this:

Code: Select all
[
  {
    "personID": "68293",
    "data": [
      {
        "uri": "assets/35605_aq.jpg",
        "height": "288",
        "width": "432",
        "category": "Scene Still",
        "caption": {
          "content": "Billy Bob Thornton and Lauren Graham in Terry Zwigoff's BAD SANTA.",
          "lang": "en"
        },
        "rootId": "33125",
        "title": "Bad Santa"
      },
      {
        "uri": "assets/35605_aq.jpg",
        "height": "288",
        "width": "432",
        "category": "Scene Still",
        "caption": {
          "content": "Billy Bob Thornton and Lauren Graham in Terry Zwigoff's BAD SANTA.",
          "lang": "en"
        },
        "rootId": "33125",
        "title": "Bad Santa"
      }
    ]
  },
  {
    "personID": "383774",
    "data": [
      {
        "uri": "assets/35605_aq.jpg",
        "height": "288",
        "width": "432",
        "category": "Scene Still",
        "caption": {
          "content": "Billy Bob Thornton and Lauren Graham in Terry Zwigoff's BAD SANTA.",
          "lang": "en"
        },
        "rootId": "33125",
        "title": "Bad Santa"
      },
      {
        "uri": "assets/35605_aq.jpg",
        "height": "288",
        "width": "432",
        "category": "Scene Still",
        "caption": {
          "content": "Billy Bob Thornton and Lauren Graham in Terry Zwigoff's BAD SANTA.",
          "lang": "en"
        },
        "rootId": "33125",
        "title": "Bad Santa"
      }
    ]
  },
  {
    "personID": "189517"
  }
]


Obviously I just copied and pasted the same image a few times so the example doesn't match what would actually be returned, but I think this illustrates the desired outcome. 189517 is an example of no images being available.
enternoescape
 
Posts: 5
Joined: Wed Jul 27, 2016 2:42 pm

Return to Developer

Who is online

Users browsing this forum: No registered users and 1 guest