home / mcp / dad jokes mcp server
Provides dad jokes via MCP by querying icanhazdadjoke.com and exposing tools to fetch random jokes, search by keyword, and retrieve by ID.
Configuration
View docs{
"mcpServers": {
"aamangeldi-dad-jokes-mcp": {
"command": "fastmcp",
"args": [
"run",
"server.py"
]
}
}
}You run a lightweight MCP server that serves dad jokes by querying icanhazdadjoke.com. It exposes practical tools that let you fetch a random joke, search jokes by a keyword, or retrieve a specific joke by its ID, all through your MCP client.
You can use three core tools to interact with the Dad Jokes MCP Server. First, fetch a random joke to get a quick laugh. Second, search jokes by a keyword to find jokes that match a topic youβre interested in. Third, retrieve a specific joke by its ID when you already know the joke you want.
Intended interactions include combining these tools into your automation or using them directly from an MCP client to build joke-driven experiences in your apps, chats, or demonstrations.
Prerequisites you need before installing: Python 3.11 or newer, and pip.
Step-by-step commands to set up and run locally:
git clone https://github.com/aamangeldi/dad-jokes-mcp.git
cd dad-jokes-mcp
python3 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
pip install fastmcp smithery httpx
fastmcp run server.pyThis server requires no authentication or extra configuration. It utilizes the free icanhazdadjoke.com API by default.
Key capabilities include: random joke retrieval, keyword-based search, and direct access to a joke by its ID.
Development and deployment notes: you can run the server locally during development, or deploy to Smithery with the runtime set to Python and the FastMCP implementation.
get_random_joke_tool β fetches a random dad joke.
search_jokes_tool β searches jokes by a given term and returns multiple results (default 5, max 30).
get_joke_by_id_tool β retrieves a joke using its unique ID.
Fetches a random dad joke from the API and exposes it through your MCP client.
Searches for dad jokes that contain a given term and returns a list of results, with configurable limit.
Retrieves a specific joke by its unique ID so you can display or reference it precisely.