io.github.CloudCorpRecords/diceport
Dice rolls, coin flips, and random numbers, reproducible with a seed.
Installation
Ajoutez ceci à la configuration MCP de votre client (Claude Desktop : claude_desktop_config.json ; Cursor : .cursor/mcp.json ; VS Code et les autres utilisent la même forme « mcpServers »).
@reneturcios/diceportclaude mcp add diceport -- npx -y @reneturcios/diceport@0.1.0 mcp
{
"mcpServers": {
"diceport": {
"command": "npx",
"args": [
"-y",
"@reneturcios/diceport@0.1.0",
"mcp"
]
}
}
}
ghcr.io/cloudcorprecords/diceport:0.1.0claude mcp add diceport -- docker run -i --rm ghcr.io/cloudcorprecords/diceport:0.1.0 mcp
{
"mcpServers": {
"diceport": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/cloudcorprecords/diceport:0.1.0",
"mcp"
]
}
}
}
Documentation
Tirée du README du projet sur GitHub, actualisée chaque semaine. Les liens ouvrent GitHub.
diceport
diceport rolls dice, flips coins, and picks random integers. It is built for the moments when a script or an agent needs a fair, explainable bit of chance: a roll reports every face that went into its total, and any call can take a seed that makes the outcome reproducible — same seed, same result, every time.
Install
npx @reneturcios/diceport roll 2d6
Or run the container image:
docker run -i ghcr.io/cloudcorprecords/diceport
The container defaults to the MCP server (see below). Pass CLI arguments to use it as a CLI instead.
CLI
# Roll dice in NdM notation, with an optional +N / -N modifier
diceport roll 2d6
# 2d6: [3, 5] total 8
diceport roll 3d8+2 --seed 42 # reproducible
# Flip a coin
diceport flip # heads (or tails)
diceport flip --seed 7 --json
# Pick an integer between two bounds, inclusive
diceport random 1 100
diceport random 1 100 --seed 42
diceport --version
Notation is NdM: roll N dice with M sides each. The count may be
left off (d20 rolls one die) and a flat modifier may be appended
(2d6+3, 1d100-5).
Exit codes: 0 on success, 1 when a roll or range cannot be done
(bad notation, an inverted range — the error says why), 2 for usage
errors.
MCP server
One bin serves both faces. The mcp subcommand starts a stdio MCP
server:
npx -y @reneturcios/diceport mcp
MCP client configuration:
{
"mcpServers": {
"diceport": {
"command": "npx",
"args": ["-y", "@reneturcios/diceport", "mcp"]
}
}
}
Tools
| Tool | Input | What it returns |
|---|---|---|
roll_dice | notation (string, required, e.g. 2d6+3), seed (integer, optional) | Every individual face rolled, the modifier, and the total. |
flip_coin | seed (integer, optional) | heads or tails. |
random_number | min, max (integers, required), seed (integer, optional) | One integer between min and max, inclusive. |
Seeded calls use a mulberry32 generator, so a seed fully determines the outcome and any reported result can be replayed. Unseeded calls draw from the platform random source.
Development
npm install
npm run build # tsc -> dist/
npm test # node test runner over test/*.test.ts, no network
npm run dev # run the CLI from source via tsx
License
MIT — see LICENSE.
Questions fréquentes
Qu'est-ce que io.github.CloudCorpRecords/diceport ?
Dice rolls, coin flips, and random numbers, reproducible with a seed.
Comment installer io.github.CloudCorpRecords/diceport ?
Il s'exécute sur votre machine. Dans Claude Code : claude mcp add diceport -- npx -y @reneturcios/diceport@0.1.0 mcp. Pour les autres clients, collez la configuration JSON de cette page dans leurs réglages MCP.
Faut-il une clé API pour io.github.CloudCorpRecords/diceport ?
Son entrée au registre n'indique aucune clé ni secret obligatoire. Certaines fonctions peuvent tout de même demander un compte auprès du service auquel il se connecte.
io.github.CloudCorpRecords/diceport est-il open source ?
Oui. Son code est sur GitHub sous licence MIT.
Qui maintient io.github.CloudCorpRecords/diceport ?
Il est publié par CloudCorpRecords. AI.tn le référence sans le maintenir ni le recommander.
Issu du registre MCP officiel. Être listé n'est pas une recommandation : vérifiez le code et les permissions d'un serveur avant de lui donner accès à vos données.