barrymcgee/dadjokes-mcp
If you are the rightful owner of dadjokes-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to dayong@mcphub.com.
The Dad Jokes MCP Server provides dad jokes from icanhazdadjoke.com and can be run locally or remotely.
Dad Jokes MCP Server
A Model Context Protocol (MCP) server that provides dad jokes from icanhazdadjoke.com. This server can run locally via stdio or remotely on Fly.io.
Features
- get_joke - Fetches a random dad joke
- get_joke_by_id - Retrieves a specific dad joke by ID
Installation
Option 1: Using with Claude Desktop (Local)
-
Build the server:
npm install npm run build -
Add to your Claude Desktop configuration file:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:%APPDATA%\Claude\claude_desktop_config.json{ "mcpServers": { "dadjokes": { "command": "node", "args": ["/absolute/path/to/dadjokes/build/index.js"] } } } -
Restart Claude Desktop
Option 2: Using with Claude Code (Remote via Fly.io)
The server is already deployed at: https://dadjokes-restless-field-2789.fly.dev
Add to your Claude Code MCP configuration:
claude mcp add --transport sse dadjokes https://dadjokes-restless-field-2789.fly.dev
This will automatically configure Claude Code to use the remote MCP server via Server-Sent Events (SSE).
Development
Build
npm run build
Test Locally
npm run build
node build/index.js
The server will start and listen for MCP protocol messages on stdio.
Deployment to Fly.io
The server is deployed using fly mcp wrap which converts the stdio MCP server to HTTP/SSE for remote access.
Deploy Your Own Instance
- Install flyctl
- Authenticate:
fly auth login - Deploy:
fly deploy
The Dockerfile automatically:
- Builds the TypeScript code
- Wraps the stdio server with
fly mcp wrapfor HTTP access - Configures auto-stop/auto-start to minimize costs
Project Structure
src/index.ts- Main MCP server implementationbuild/- Compiled JavaScript outputDockerfile- Multi-stage build for Fly.io deploymentfly.toml- Fly.io configuration
API
The server connects to the icanhazdadjoke.com API which provides:
- Random jokes via
GET / - Specific jokes via
GET /j/{id}
All requests include Accept: application/json header.
License
ISC