Joke Button MCP Server
Provides a joke button UI for ChatGPT that, when clicked, asks the assistant to respond with one short, family-friendly joke.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Joke Button MCP ServerShow the joke button"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP Joke Button App
This project is a tiny MCP server that exposes one MCP App UI: a single button. When the button is clicked, the app sends a message to the host asking the assistant to answer with one short, family-friendly joke.
It intentionally uses only Node.js built-in modules. There are no runtime package dependencies.
What It Demonstrates
MCP core protocol version
2026-07-28Stateless Streamable HTTP on one endpoint:
/mcpserver/discover,tools/list,tools/call,resources/list, andresources/readMCP Apps UI resource metadata with
_meta.ui.resourceUriA sandbox-friendly
text/html;profile=mcp-appwidgetui/initializeandui/messageoverpostMessage
Related MCP server: Jokes MCP Server
Requirements
Install Node.js 20 or newer from nodejs.org. The LTS download is fine.
You do not need to run npm install; this project has no third-party libraries.
Start the Server
Open a terminal in this folder and run:
npm startYou should see:
MCP Joke Button server listening on http://127.0.0.1:8787/mcp
Preview the widget shell at http://127.0.0.1:8787/previewLeave that terminal open while you test.
MCP requests are logged by method while the server is running. For an interactive app render, the log should include a successful UI resource read similar to:
[mcp] request method=resources/read name=ui://joke-button/app.html
[mcp] response method=resources/read status=200Set MCP_LOG_REQUESTS=false if you want to disable these development logs.
Heroku Deployment
The joke-button Heroku app is deployed at:
https://joke-button-31cddc4bc964.herokuapp.comIts MCP endpoint is:
https://joke-button-31cddc4bc964.herokuapp.com/mcpDeploy the current branch with:
git push heroku HEAD:mainQuick Local Check
Open this address in a browser:
http://127.0.0.1:8787/previewThis only previews the button's appearance. The button can ask the AI for a joke only when it is rendered inside an MCP Apps-compatible host such as ChatGPT.
Use with ChatGPT Desktop or ChatGPT Web
ChatGPT needs an HTTPS URL for a remote MCP server during development. Keep npm start running, then expose port 8787 with a tunnel tool such as ngrok or Cloudflare Tunnel.
Example with ngrok:
ngrok http 8787Copy the HTTPS forwarding URL and add /mcp to the end, for example:
https://example.ngrok.app/mcpThen connect it in ChatGPT:
Open ChatGPT.
Open Settings.
Open Security and login.
Turn on Developer mode if it is not already enabled.
Open Plugins. If you are in the desktop app and do not see it in the sidebar, open
https://chatgpt.com/pluginsin a browser while signed in to the same account.Select the plus button to add a developer MCP server connection.
Paste the HTTPS URL ending in
/mcp.Name it
Joke Button.Start a new chat, select the plugin from the More menu, and ask:
Show the joke button.Click
Tell a joke.
You do not need a setting named MCP servers for this ChatGPT UI test. That setting is for Codex's local MCP host configuration, not for adding a ChatGPT developer plugin connection.
If Developer mode or the plus button is missing, check that the desktop app is up to date and that your account or workspace allows plugin development.
If the app is working, ChatGPT should receive the button's message and respond with a short joke.
Use with Codex in the ChatGPT Desktop App
Codex can connect to Streamable HTTP MCP servers from the shared MCP settings.
The MCP servers setting appears only on Codex-capable local clients and may not appear in a regular ChatGPT chat settings view. If it is available:
Keep
npm startrunning.Open the ChatGPT desktop app.
Open Settings, then MCP servers.
Select Add server.
Choose Streamable HTTP.
Name the server
joke_button.Use this URL:
http://127.0.0.1:8787/mcpSave, then restart when prompted.
In a Codex task, type
/mcpto confirm the server is connected.Ask Codex:
Use the Joke Button MCP server.
Codex MCP tool support may show the text fallback rather than rendering the iframe UI, depending on the surface. For the actual one-button UI, use ChatGPT with MCP Apps UI support.
If the setting is not visible, copy the sample configuration from codex-config.example.toml into a trusted project's .codex/config.toml or into your user ~/.codex/config.toml, then restart the ChatGPT desktop app or Codex client.
Useful URLs
Health check:
http://127.0.0.1:8787/healthMCP endpoint:
http://127.0.0.1:8787/mcpWidget preview:
http://127.0.0.1:8787/preview
Security Notes
The server validates the MCP protocol version and mirrored MCP headers required by the 2026-07-28 Streamable HTTP transport.
For local development, requests without an Origin header are accepted, loopback browser origins are accepted, and common OpenAI host origins are accepted. For another host origin, start the server with:
$env:MCP_ALLOWED_ORIGINS="https://your-host.example"
npm startUse authentication before exposing a real MCP server that can access private data or perform actions. This sample does neither.
Project Files
server.js: dependency-free MCP serverpublic/joke-button.html: MCP App UI widgetcodex-config.example.toml: sample Codex MCP configuration
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceAn MCP server that fetches jokes from multiple sources (Chuck Norris, Dad jokes, and Yo Mama jokes) and integrates with Microsoft Copilot Studio to create a humor-focused conversational experience.MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server implementation that delivers various joke types (Chuck Norris, Dad jokes, etc.) to Microsoft Copilot Studio and GitHub Copilot through the Model Context Protocol.MIT
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol (MCP) server that provides joke-fetching capabilities, demonstrating how to deploy an MCP Server and integrate it with Microsoft Copilot Studio.MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server that provides jokes on demand, allowing users to request different types of jokes (Chuck Norris, Dad jokes, etc.) through natural language in both GitHub Copilot and Microsoft Copilot Studio.MIT
Related MCP Connectors
MCP server for AI dialogue using various LLM models via AceDataCloud
A very simple remote MCP server that greets you, with a custom icon.
MCP server exposing the AceDataCloud Fish Audio API (text-to-speech with voice conditioning)
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/mwilber/mcpapptest'
If you have feedback or need assistance with the MCP directory API, please join our Discord server