Skip to main content
Glama
drakonkat

wizzy-mcp-tmdb

movie_lists

Find curated collections and lists that include specific movies to support content curation and discovery workflows.

Instructions

Retrieves lists and collections that include a specific movie. Input: movie_id (required TMDB ID), language (optional ISO 639-1 code), page (optional page number). Output: JSON with paginated results of lists containing the movie. Purpose: Discover curated collections and lists featuring a movie for content curation by AI agents.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
languageNoISO 639-1 language (e.g., en-US)
movie_idYesTMDB Movie ID
pageNoPage number

Implementation Reference

  • The handler function implementing the tool logic: fetches lists containing the specified movie from TMDB and returns the data as formatted JSON text.
    handler: async ({movie_id, language, page}) => {
        const data = await tmdbFetch(`/movie/${movie_id}/lists`, {language, page});
        return {content: [{type: "text", text: JSON.stringify(data, null, 2)}]};
    }
  • Input schema for validating tool arguments: requires movie_id (TMDB Movie ID), optional language and page.
    inputSchema: {
        type: "object",
        properties: {
            movie_id: {type: "number", description: "TMDB Movie ID"},
            language: {type: "string", description: "ISO 639-1 language (e.g., en-US)"},
            page: {type: "number", minimum: 1, description: "Page number"}
        },
        required: ["movie_id"],
        additionalProperties: false
    },
  • The tool registration object added to the 'tools' array, which is used by the MCP server's listTools and callTool request handlers.
    {
        name: "movie_lists",
        description: "Retrieves lists and collections that include a specific movie. Input: movie_id (required TMDB ID), language (optional ISO 639-1 code), page (optional page number). Output: JSON with paginated results of lists containing the movie. Purpose: Discover curated collections and lists featuring a movie for content curation by AI agents.",
        inputSchema: {
            type: "object",
            properties: {
                movie_id: {type: "number", description: "TMDB Movie ID"},
                language: {type: "string", description: "ISO 639-1 language (e.g., en-US)"},
                page: {type: "number", minimum: 1, description: "Page number"}
            },
            required: ["movie_id"],
            additionalProperties: false
        },
        handler: async ({movie_id, language, page}) => {
            const data = await tmdbFetch(`/movie/${movie_id}/lists`, {language, page});
            return {content: [{type: "text", text: JSON.stringify(data, null, 2)}]};
        }
    },
  • Helper function used by the handler to perform authenticated API requests to TMDB.
    async function tmdbFetch(path, params = {}) {
        if (!TMDB_AUTH_TOKEN) {
            throw new Error("TMDB authorization token is not configured");
        }
        const url = new URL(TMDB_BASE + path);
        Object.entries(params).forEach(([k, v]) => {
            if (v !== undefined && v !== null && v !== "") url.searchParams.set(k, String(v));
        });
    
        const res = await fetch(url, {
            headers: {
                Accept: "application/json",
                Authorization: TMDB_AUTH_TOKEN,
            },
        });
        if (!res.ok) {
            const text = await res.text().catch(() => "");
            throw new Error(`TMDB request failed ${res.status}: ${text}`);
        }
        return res.json();
    }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/drakonkat/wizzy-mcp-tmdb'

If you have feedback or need assistance with the MCP directory API, please join our Discord server