GET filmLiveSearch

Description

Returns film titles matching search string – useful for search as you type or standard search. List is ordered by popularity using a count of number of showtimes in database. For ‘search as you type’, send a request after every character entered in your app’s search field.

Example request

filmLiveSearch/?query=star+wars&n=6

Recommendation: If you are using this feature to implement a “Search as you type” solution, we recommend that you implement a short delay before submitting the request, to detect if the user has stopped typing.

Required headers

Sent headerDescriptionData typeOptional / Mandatory
NoneNoneNoneNone

Sent Arguments

Sent argumentDescriptionData typeOptional / Mandatory
query The search string to be queries (URL enoded), for example query=star+wars. You can submit a search for one or more characters.StringMandatory
nLimit the number of returned results. Default is 5, System max is 25.IntegerOptional

Caching

The returned data can be cached.

Returned data

Returned KeyDescription
filmsArray – containing details of films matching search criteria
film_idThe MovieGlu numeric internal film ID
film_nameThe film name
release_dateThe release date of the film in format YYYY-MM-DD
durationThe duration in minutes for each film
age_ratingAge rating for film
imagesLocation and details of primary images for film.
Please refer to the GET Images for format.
NOTE: Only the film poster and one still will be returned.

Example response


{
  "films": [
    {
      "film_id": 206405,
      "film_name": "Rogue One: A Star Wars Story",
      "release_date": "2016-12-16",
      "duration": 133,
      "age_rating": "12A ",
      "images": {
        "poster": {
          "1": {
            "image_orientation": "portrait",
            "region": "US",
            "medium": {
              "film_image": "https://d3ltpb4h29tx4j.cloudfront.net/206405/206405h1.jpg",
              "width": 200,
              "height": 300
            }
          }
        },
        "still": {
          "2": {
            "image_orientation": "landscape",
            "medium": {
              "film_image": "https://d3ltpb4h29tx4j.cloudfront.net/206405/206405h2.jpg",
              "width": 300,
              "height": 200
            }
          }
        }
      }
    },
    {
      "film_id": 230283,
      "film_name": "Rogue One: A Star Wars Story 3D",
      "release_date": "2016-12-16",
      "duration": 133,
      "age_rating": "12A ",
      "images": {
        "poster": {
          "1": {
            "image_orientation": "portrait",
            "region": "US",
            "medium": {
              "film_image": "https://d3ltpb4h29tx4j.cloudfront.net/230283/230283h1.jpg",
              "width": 200,
              "height": 300
            }
          }
        },
        "still": {
          "2": {
            "image_orientation": "landscape",
            "medium": {
              "film_image": "https://d3ltpb4h29tx4j.cloudfront.net/230283/230283h2.jpg",
              "width": 300,
              "height": 200
            }
          }
        }
      }
    }
  ],
  "count": 2,
  "status": {
    "state": "OK",
    "code": 1,
    "method": "filmLiveSearch",
    "message": null,
    "request_method": "GET",
    "version": "MGv102",
   }
}