Offers Docker deployment support with a pre-configured Docker image, allowing containerized execution of the IMDb MCP server with proper environment variable configuration.
Provides comprehensive access to IMDb movie and TV show data, including search capabilities, detailed information about titles, cast and crew details, top-rated content lists, box office data, upcoming releases, and country-specific movie information with special focus on Indian cinema.
Utilizes RapidAPI's IMDb API service to fetch movie and TV show information, requiring users to set up a RapidAPI account and subscribe to the IMDb API to obtain the necessary API key.
IMDb MCP Server
A Python server implementing Model Context Protocol (MCP) for movie and TV show information using the IMDb API service.
Table of Contents
Related MCP server: mmnt-mcp-server
Overview
This server provides a comprehensive set of tools for accessing IMDb data through the IMDb API. It serves as a bridge between agents and the IMDb database, offering detailed information about movies, TV shows, actors, directors, and more.
Features
๐ฌ Movie and TV show search capabilities
๐ Detailed information about movies and TV shows
๐จโ๐ฉโ๐งโ๐ฆ Cast and crew information
๐ Top-rated and popular content lists
๐ฐ Box office data
๐ Country-specific movie information (with special focus on Indian cinema)
๐ Upcoming releases
๐ Efficient response caching system
Requirements
Python: 3.13 or higher
Package Manager: uv (recommended) or pip
RapidAPI Account: Required for IMDb API access
Configuration
This server requires an API key from RapidAPI for the IMDb API service:
Create an account on RapidAPI
Subscribe to the IMDb API on RapidAPI
Configure the API key using one of these methods:
Method 1: Smithery Configuration (for HTTP mode)
When installing via Smithery, provide your API key through the Smithery configuration system
The key is passed per-request, allowing for multi-user scenarios
Method 2: Environment Variable (for stdio mode)
export RAPID_API_KEY_IMDB=your_api_key_here
Tools
Search Tools
Tool | Description | Example |
search_imdb | Search for movies and TV shows with various filtering options |
|
IMDb ID Tools
Tool | Description | Example |
get_imdb_details | Retrieve detailed information about a movie or TV show |
|
get_directors | Retrieve the directors of a movie |
|
get_cast | Retrieve the cast of a movie |
|
get_writers | Retrieve the writers of a movie |
|
Configuration Tools
Tool | Description | Example |
get_types | Get all available content types |
|
get_genres | Get all available genres |
|
get_countries | Get all available countries |
|
get_languages | Get all available languages |
|
Movies Tools
Paginated (5 results per page)
Tool | Description | Example |
get_top_250_movies | Get the top 250 movies from IMDb |
|
get_top_box_office_us | Get the US box office records |
|
get_most_popular_movies | Get the most popular movies |
|
TV Shows Tools
Paginated (5 results per page)
Tool | Description | Example |
get_top_250_tv_shows | Get the top 250 TV shows from IMDb |
|
get_most_popular_tv_shows | Get the most popular TV shows |
|
Upcoming Releases Tools
Paginated (5 results per page)
Tool | Description | Example |
get_upcoming_releases | Get upcoming movie and TV show releases by country |
|
get_country_codes_for_upcoming_releases | Get available country codes for upcoming releases |
|
India Spotlight Tools
Paginated (5 results per page)
Tool | Description | Example |
get_top_rated_malayalam_movies | Get top 50 rated Malayalam movies |
|
get_upcoming_indian_movies | Get most anticipated upcoming Indian movies |
|
get_trending_tamil_movies | Get trending Tamil movies |
|
get_trending_telugu_movies | Get trending Telugu movies |
|
get_top_rated_tamil_movies | Get top 50 rated Tamil movies |
|
get_top_rated_telugu_movies | Get top 50 rated Telugu movies |
|
get_top_rated_indian_movies | Get top 250 rated Indian movies |
|
Example Prompt and Response
What are the 5 action movies that will be released in the nearest future?
I'll find the upcoming action movies for you.
Called MCP tool get_upcoming_releases
Now I'll look for the action movies from these upcoming releases:
Called MCP tool get_upcoming_releases
Based on the search results, here are the 5 upcoming action movies that will be released in the nearest future:
A Minecraft Movie (April 4, 2025)
Genres: Action, Adventure, Comedy
Description: Four misfits are pulled through a portal into a cubic wonderland and embark on a quest with an expert crafter to get back home.
Freaky Tales (April 4, 2025)
Genres: Action, Adventure, Comedy
Description: Four interconnected stories set in 1987 Oakland, CA about the love of music, movies, people, places and memories.
Wake Up (April 4, 2025)
Genres: Action, Horror
Description: Young activists invade a furniture store to protest environmental issues but find themselves trapped with a hunting-obsessed night guard.
Warfare (April 11, 2025)
Genres: Action, Drama, War
Description: Based on ex-Navy Seal Ray Mendoza's real-life experiences during the Iraq War.
The Amateur (April 11, 2025)
Genres: Action, Thriller
Description: A CIA cryptographer blackmails his agency into training him to pursue terrorists who killed his wife.
Installation
Installing via Smithery (Recommended)
To install IMDb Server for Claude Desktop automatically via Smithery:
This will automatically configure the server with your RapidAPI key through Smithery's configuration system.
Option 1: Using Docker
Clone this repository
Build the Docker image
Run the Docker container
Note: The Docker container runs in HTTP mode by default on port 8081.
Option 2: Direct Python Execution (using uv)
Clone this repository
Install uv (if not already installed)
Install dependencies using uv
Add this to your
claude_desktop_config.json:
Starting the Server
Stdio Mode (Default for local development)
HTTP Mode (Used by Docker and Smithery)
After adding your chosen configuration, restart Claude Desktop to load the IMDb server. You'll then be able to use all the movie and TV show data tools in your conversations with Claude.
Technical Details
The server is built on:
Python 3.13+: Modern Python runtime
FastMCP: Server implementation with HTTP and stdio transport support
IMDb API via RapidAPI: Primary data source
Requests: API communication library
Smithery: Configuration and deployment management
uv: Fast Python package manager and runner
Custom in-memory caching system: Optimized response caching with LRU eviction
Smart pagination: Limits results to 5 items per request, optimizing for AI agent consumption
Transport Modes
The server supports two transport modes:
Stdio Mode (Default): Traditional MCP server communication via standard input/output
Used for local Claude Desktop installations
Configured via environment variables (
RAPID_API_KEY_IMDB)
HTTP Mode: RESTful HTTP transport with CORS support
Used for Docker deployments and Smithery
Supports per-request configuration via Smithery config system
Runs on port 8081 by default (configurable via
PORTenvironment variable)
Pagination System
All data retrieval tools implement pagination to enhance AI agent performance:
Purpose
AI-Optimized Responses: Limits each response to 5 items, preventing overwhelm in AI agents that process the data
Focused Results: Helps agents provide more relevant and concise information to users
Improved Processing: Reduces the cognitive load on AI agents when analyzing movie and TV show data
Implementation
Each paginated endpoint accepts a
startparameter (default: 0)Results include navigation metadata (totalCount, hasMore, nextStart)
Consistent 5-item page size across all collection endpoints
Example request with pagination:
get_top_250_movies(start=5)returns items 6-10
Benefits
Better Agent Responses: Prevents AI agents from receiving too much data at once
Manageable Information: Creates digestible chunks of data that agents can process effectively
Sequential Access: Allows structured exploration of large datasets through multiple tool calls
Caching System
The server implements an efficient caching system to improve performance and reduce API calls:
Features
In-memory Cache: Stores API responses in memory for quick retrieval
Configurable Expiration and Size: Cache entries expire after a customizable time period (default: 10 minutes) and have a default size of 100 cache keys
Automatic Cache Cleaning: Periodically (default: 5 minutes) removes expired entries to manage memory usage using a background thread
Cache Keys: Generated based on the URL and query parameters to ensure uniqueness
Benefits
Reduced API Usage: Helps stay within API rate limits by reusing responses
Faster Response Times: Eliminates network latency for cached queries
Cost Efficiency: Minimizes the number of API calls, especially for popular or repeated queries
Configuration
The cache size and expiration time can be adjusted in src/main.py:
Limitations
API rate limits apply based on your RapidAPI subscription
Some detailed information may require additional API calls
Search results may be limited to a certain number of items per request
In-memory cache is lost when server restarts
All paginated responses return a maximum of 5 items per page
Troubleshooting
Problem | Solution |
API key not recognized | Stdio mode : Ensure the
environment variable is properly set. HTTP mode : Verify the
is provided in the Smithery configuration |
Rate limit exceeded | Check your RapidAPI subscription tier and limits at |
Timeout errors | The server has a 30-second timeout; for large requests, try limiting parameters or using pagination |
Empty results | Try broader search terms or check if the content exists in IMDb's database |
High memory usage | If running for extended periods with many unique queries, restart the server occasionally to clear the cache |
Port already in use | Change the port using the
environment variable (HTTP mode only):
|
Import errors | Ensure all dependencies are installed:
or
|
Connection refused (Docker) | Ensure the container is running:
and check the logs:
|
License
This MCP server is available under the MIT License.