Netflix API Forums

API Forum

RSS Feed

Category SubCategory

  1. Can someone please show me an example of how I can use the REST Calls to get a subcategory list for a given category_item label?

    Message edited by toddpi314 8 months ago

    Tags

  2. priya2 years ago

    Hello,

    May I ask what are you particularly looking for?

    Thanks,
    Priya.

  3. toddpi3142 years ago

    Sure!

    I would like to have a composite (Tree) navigation structure for directing filter criteria in my client application.
    Basically, I have a great list of categories, but can't seem to figure out how they are related in terms of hierarchy.

    For instance, image you are in a 'distopian film' mood and would like to navigate into a "sci-fi' category and see that listing as a leaf...

    Is this possible with the existing REST API?

  4. Michael Hart2 years ago

    This has already been implemented in our forthcoming REST API. We're in the final phases of QA for this release, so stay tuned.

  5. toddpi3142 years ago

    sweet!

    ETA?

    and, if your not crazy enough to tell me a eta, can you give me a bit of insight as to how the relationships are managed?
    For instance, if I key my Category Items via string label, will the new format allow me to relate the string key to a guid/id later, or will this drop be a major data representation rewrite?

    Just curious if I just need to close the compiler until the new feature is out.

  6. priya2 years ago

    Here are some details of how the genre category listings (for instance) would look like in our latest version (2.0).

    The resource http://api.netflix.com/categories/genres?v=2.0 would give a list of top level genres.
    The response of this resource would look like below:

    <?xml version="1.0" standalone="yes"?>

    <category_scheme>
    <category_item term="Action &amp; Adventure">
    <link href="http://api.netflix.com/categories/genres/296" rel="http://schemas.netflix.com/catalog/sub_genres" title="Action &amp; Adventure"></link>
    </category_item>
    <category_item term="Anime &amp; Animation">
    <link href="http://api.netflix.com/categories/genres/623" rel="http://schemas.netflix.com/catalog/sub_genres" title="Anime &amp; Animation"></link>
    </category_item>
    <category_item term="Blu-ray"></category_item>

    <category_item term="Children &amp; Family">
    <link href="http://api.netflix.com/categories/genres/302" rel="http://schemas.netflix.com/catalog/sub_genres" title="Children &amp; Family"></link>
    </category_item>
    ...
    </category_scheme>


    In the above response, there will be a link in each 'category_item' that would give you a listing of the associated sub-genres

    For ex.,
    http://api.netflix.com/categories/genres/296?v=2.0 => this would give a listing of the associated sub-genres

    The response would look like below: (list of sub-genres)
    <?xml version="1.0" standalone="yes"?>

    <category_scheme>
    <category_item term="Action Classics"></category_item>
    <category_item term="Action Comedies"></category_item>
    <category_item term="Action Thrillers"></category_item>
    <category_item term="Adventures"></category_item>
    <category_item term="African-American Action"></category_item>
    ...
    </category_scheme>

    In addition to this, when a request is made for the title details, the sub genres would refer to the parent genre scheme like below:
    http://api.netflix.com/catalog/titles/movies/60002360?v=2.0

    <catalog_title>
    <id>
    http://api.netflix.com/catalog/titles/movies/60002360
    </id>
    <title short="Jurassic Park" regular="Jurassic Park"/>
    <release_year>1993</release_year>
    <category scheme="http://api.netflix.com/categories/mpaa_ratings" label="PG-13" term="PG-13"/>
    <category scheme="http://api.netflix.com/categories/genres" label="Action & Adventure" term="Action & Adventure"/>
    <category scheme="http://api.netflix.com/categories/genres/373" label="Sci-Fi Adventure" term="Sci-Fi Adventure"/>
    <category scheme="http://api.netflix.com/categories/genres/302" label="Dinosaurs" term="Dinosaurs"/>
    ...
    ...
    ...
    </catalog_title>

    In the above example, Sci-Fi Adventure (sub genre) would link to the parent genre scheme http://api.netflix.com/categories/genres/373 (which is Sci-Fi & Fantasy)

    Hope this helps. We will keep you posted as soon as our 2.0 is live and would point to our 2.0 documentation which might explain this a bit better.

    Thanks,
    -Priya.

  7. Doron2 years ago

    Will you be able to limit search to those genres (or sub genres)?

    Man, I've been working on making my own DB based on the catalog for this stuff, good to see the official API will have this

  8. toddpi3142 years ago

    This is great! That will do wonderfully.

    I would still suggest that the category cache be created for each client, since requests are limited and we don't want to cause the Netflix team to take any performance hits because yall have been so nice as to let us use your API.

  9. Michael Hart2 years ago

    We're trying to enable non-personalized faceted search in the next 6 months. The goal is to let a dev submit an XQuery that constrains the search on any title metadata attribute.

  10. Doron2 years ago

    Good to know, the most frequent request I get is limiting searches or browsing titles that are bluray or instant watchable. Having ids for each category does help.

  11. Ben B10 months ago

    When I try to retrieve the sub-genres of any genre, I get a 404 error. For example:

    http://api.netflix.com/categories/genres/296?v=2.0&oauth_consumer_key=XXXX

    Returns:

    <?xml version="1.0" standalone="yes"?>

    <status>
    <status_code>404</status_code>
    </status>

    Is this working for anyone else? Any help would be much appreciated. Thanks.

  12. g_reno10 months ago

    Michael - will the new API allow for more search options like the ODATA interface allows? For example, show me all titles available for instant with a rating of 3 stars or more in the Sci Fi category, sorted by available release date?

  13. Nicholas Clarkson10 months ago

    @Ben B

    I don't think you need the version or any kind of OAuth. I just used http://api.netflix.com/categories/genres/296 in a browser and got the sub-genres.

  14. Ben B10 months ago

    @Nicholas Clarkson, thanks for the reply. This is perplexing. When I go to http://api.netflix.com/categories/genres/296 in my browser I get the following:

    <h1>403 Developer Inactive</h1>

  15. Nicholas Clarkson10 months ago

    Very strange. I just tried in Chrome and got that error. wget also gives the 403 error. Firefox 4 on Mac works. Firefox 4 on Windows gives the 403 error.

  16. Ben B10 months ago

    Can anyone from Netflix clear this up? That is, can a genre's listing of sub-genres be retrieved?

  17. meaux10 months ago

    I am also getting a 403 when using http://api.netflix.com/categories/genres?v=2.0 to retrieve categories, but not when I use oData, nor any other query using the RESTful API (so far).

    Can anyone help?

  18. Jeff Dillon10 months ago

    Hi,

    I am checking into the 403 error when retrieving categories, and will post more information here when available.

    Jeff Dillon, Netflix API Support

  19. David Gross8 months ago

    See http://developer.netflix.com/blog/read/Old_Genres_Are_Going_Away for an update on genres in the API.

[ Page 1 of 1 ]