MongoDB Movie Database FastMCP Tools is an MCP server that connects large language models to a MongoDB instance hosting the sample_mflix movie dataset. Built using the FastMCP library and PyMongo, it enables AI assistants to search, filter, and analyze extensive film catalogs via structured function calls. Software developers, data analysts, and AI application builders use this server to equip language models with direct database query capabilities. It provides specialized tools for retrieving movies by title, cast members, directors, release years, MPAA ratings, and genres, with support for customizable projections and sorting orders. The server also provides dedicated analytical operations to count films satisfying multi-attribute criteria and calculate average scores across IMDb, Metacritic, and Rotten Tomatoes review aggregations. Because it accommodates stringified list arguments, it prevents common tool-use parsing failures encountered during model tool calling.
Category: Data & Analytics
Tags: database-query, mongodb, movies, nosql
Visit MongoDB Movie Database FastMCP Tools
Follow these steps to set up and configure the server for Claude Desktop: 1. Ensure Python 3.7+ is installed and a MongoDB instance with the sample_mflix dataset loaded is accessible. 2. Clone the repository: bash git clone https://github.com/patw/movie-mcp.git cd movie-mcp 3. Install the required Python dependencies: bash pip install -r requirements.txt 4. Add the server configuration to your Claude Desktop configuration file under mcpServers: json { "mcpServers": { "Movie Database": { "command": "uv", "args": [ "run", "--with", "fastmcp, pymongo", "fastmcp", "run", "<path to>/movie-mcp/movie-mcp.py", "<mongo connection string URI>" ] } } } 5. Replace <path to> and <mongo connection string URI> with your local file path and database credentials, then restart Claude Desktop.
Part of MCP Servers
The server exposes tools that allow connected AI models to query the sample_mflix dataset. These tools include find_movies for detailed searches, count_movies for tallying matching records, and get_average_rating for computing average IMDb, Metacritic, or Rotten Tomatoes scores across selected titles.
Clone the repository using git, then install dependencies with pip install -r requirements.txt. You can run the server directly with Python or execute it via uv inside the Claude Desktop configuration by passing your MongoDB connection URI as an argument.
The server works with Claude Desktop using the standard configuration file. It can also be integrated into any MCP-compatible AI agent, workflow, or Python script that connects to standard FastMCP tool endpoints.
You need access to a running MongoDB instance, either hosted locally or on MongoDB Atlas, with the official sample_mflix dataset imported and available in the movies collection.
Yes, MongoDB Movie Database FastMCP Tools is open-source software licensed under the MIT License, and the source code is hosted on GitHub.