search_keywords
Find TMDB keywords to categorize content and optimize search results for movies and TV shows using text queries.
Instructions
Searches for TMDB keywords (tags) by text query. Input: query (required search string), page (optional page number). Output: JSON with paginated keyword results. Purpose: Discover keywords for content categorization and search optimization by AI agents.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| page | No | Page number | |
| query | Yes | Search query for keywords |
Implementation Reference
- mcp-tmdb-server.js:216-219 (handler)The handler function for the search_keywords tool. It calls tmdbFetch with '/search/keyword' endpoint using query and optional page parameters, then returns the JSON-stringified data wrapped in MCP content format.handler: async ({query, page}) => { const data = await tmdbFetch('/search/keyword', {query, page}); return {content: [{type: 'text', text: JSON.stringify(data, null, 2)}]}; }
- mcp-tmdb-server.js:210-215 (schema)The inputSchema for search_keywords tool, specifying required 'query' string and optional 'page' number (min 1).inputSchema: { type: "object", properties: {query: {type: "string", description: "Search query for keywords"}, page: {type: "number", minimum: 1, description: "Page number"}}, required: ["query"], additionalProperties: false },
- mcp-tmdb-server.js:207-220 (registration)The complete tool registration object for 'search_keywords' within the tools array, which is used by MCP server handlers for listing and calling tools.{ name: "search_keywords", description: "Searches for TMDB keywords (tags) by text query. Input: query (required search string), page (optional page number). Output: JSON with paginated keyword results. Purpose: Discover keywords for content categorization and search optimization by AI agents.", inputSchema: { type: "object", properties: {query: {type: "string", description: "Search query for keywords"}, page: {type: "number", minimum: 1, description: "Page number"}}, required: ["query"], additionalProperties: false }, handler: async ({query, page}) => { const data = await tmdbFetch('/search/keyword', {query, page}); return {content: [{type: 'text', text: JSON.stringify(data, null, 2)}]}; } },