Skip to main content
Glama
drakonkat

wizzy-mcp-tmdb

trending_all

Discover trending movies, TV shows, and people by time period to analyze current popularity patterns and generate media recommendations.

Instructions

Retrieves trending content across movies, TV shows, and people. Input: time_window (required: day|week), page (optional), language (optional ISO 639-1), region (optional ISO 3166-1), include_adult (optional boolean). Output: JSON with paginated trending results. Purpose: Discover currently popular media for trend analysis and recommendations by AI agents.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
include_adultNo
languageNo
pageNo
regionNo
time_windowYesTime window

Implementation Reference

  • The core handler function for the 'trending_all' tool. It takes parameters like time_window (day/week), page, language, region, include_adult, calls tmdbFetch to get trending data from TMDB API endpoint /trending/all/{time_window}, and returns the JSON response formatted as MCP content.
    handler: async ({time_window, page, language, region, include_adult}) => {
        const data = await tmdbFetch(`/trending/all/${time_window}`, {page, language, region, include_adult});
        return {content: [{type: 'text', text: JSON.stringify(data, null, 2)}]};
    }
  • The input schema for the 'trending_all' tool, defining validation for parameters: time_window (required enum day/week), optional page (number >=1), language (string), region (string), include_adult (boolean).
    inputSchema: {
        type: "object",
        properties: {
            time_window: {type: "string", enum: ["day", "week"], description: "Time window"},
            page: {type: "number", minimum: 1},
            language: {type: "string"},
            region: {type: "string"},
            include_adult: {type: "boolean"}
        },
        required: ["time_window"],
        additionalProperties: false
  • The full tool registration object for 'trending_all' within the 'tools' array, which is used by MCP server handlers for listing and calling tools.
    {
        name: "trending_all",
        description: "Retrieves trending content across movies, TV shows, and people. Input: time_window (required: day|week), page (optional), language (optional ISO 639-1), region (optional ISO 3166-1), include_adult (optional boolean). Output: JSON with paginated trending results. Purpose: Discover currently popular media for trend analysis and recommendations by AI agents.",
        inputSchema: {
            type: "object",
            properties: {
                time_window: {type: "string", enum: ["day", "week"], description: "Time window"},
                page: {type: "number", minimum: 1},
                language: {type: "string"},
                region: {type: "string"},
                include_adult: {type: "boolean"}
            },
            required: ["time_window"],
            additionalProperties: false
        },
        handler: async ({time_window, page, language, region, include_adult}) => {
            const data = await tmdbFetch(`/trending/all/${time_window}`, {page, language, region, include_adult});
            return {content: [{type: 'text', text: JSON.stringify(data, null, 2)}]};
        }
    },
  • Shared helper function tmdbFetch used by the trending_all handler (and all tools) to make authenticated API calls to TMDB via proxy, handling URL params, fetch, error checking, and JSON parsing.
    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();
    }
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden. It discloses that the output is JSON with paginated results, which is useful behavioral context. However, it lacks details on rate limits, authentication needs, error handling, or specific data formats in the response.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the core purpose, followed by input/output details, and ends with the tool's purpose. Every sentence adds value with no wasted words, making it efficient and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and no output schema, the description does a good job covering inputs and output format. However, for a tool with 5 parameters and paginated results, it could benefit from more details on response structure or error cases to be fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is low (20%), but the description compensates by listing all parameters with brief semantics (e.g., 'time_window (required: day|week)', 'language (optional ISO 639-1)'), adding value beyond the sparse schema. It doesn't fully explain each parameter's effect, but provides enough context for basic use.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose with a specific verb ('Retrieves') and resource ('trending content across movies, TV shows, and people'), and distinguishes it from siblings like 'trending_movies' or 'trending_tv' by specifying it covers multiple media types. It also explicitly mentions the purpose for AI agents.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context for when to use this tool ('Discover currently popular media for trend analysis and recommendations'), but does not explicitly state when not to use it or name alternatives among the many sibling tools (e.g., 'trending_movies' for movies only).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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