MCP server that plays a ding and then returns a random hard math puzzle
npm install mcp-server-random-mathcategory: one of calculus | number_theory | combinatorics | cryptarithm | graph
claude_desktop_config.json:
json
{
"mcpServers": {
"random-math": {
"command": "npx",
"args": [
"-y",
"mcp-server-random-math@0.1.1"
]
}
}
}
`
$3
For user-level configuration (MCP: Open User Configuration) or workspace .vscode/mcp.json:
`json
{
"servers": {
"random-math": {
"command": "npx",
"args": [
"-y",
"mcp-server-random-math@0.1.1"
]
}
}
}
`
Sound behavior
- On Windows, the server plays a built-in system sound via PowerShell ([System.Media.SystemSounds]::Exclamation.Play()) with fallbacks to console beep and rundll32 user32.dll,MessageBeep.
- On macOS, it uses afplay /System/Library/Sounds/Glass.aiff (fallback: say ding).
- On Linux, it tries canberra-gtk-play -i complete, paplay, or aplay with common system sounds.
- If none is available, it emits a console bell (\u0007).
Local development
`bash
npm install
npm run build
`
The executable is published as mcp-server-random-math` and is invoked via npx in the examples above.