mcpField
R
Random Tables

Random Tables

Remote
pipeworx.ioGames & Entertainment0Updated 6d ago

About Random Tables

Random Tables is an MCP server with original random tables for tabletop and narrative play. It supports nested table references, caller-supplied tables, seeded reproducible rolls, and optional no-repeat sessions for built-in tables on the hosted service.

Key features

  1. 01Fantasy, sci-fi, and modern tables
  2. 02Recursive nested table rolls
  3. 03Custom weighted tables
  4. 04Reproducible seeded results
  5. 05No-repeat hosted sessions

Use cases

  1. 01Generate an encounter or plot hook
  2. 02Create NPC traits and secrets
  3. 03Roll loot or weather during play

MCP support

Exposes tools to roll and inspect built-in tables, list tables, and roll caller-supplied entries. It is available through the Pipeworx gateway or as a standalone local stdio MCP server; no-repeat sessions are hosted-only.

Configuration

Remote servers need no local install. Pick your client, then copy the config or install in one click.

Endpointhttps://gateway.pipeworx.io/random-tables/mcp
Copy install command
Claude CodeTerminal
Cursor.cursor/mcp.json
VS Code.vscode/mcp.json
Claude Desktopclaude_desktop_config.json
Windsurf~/.codeium/windsurf/mcp_config.json

Run commands in a terminal; paste JSON into the client’s MCP config and restart. Servers that need sign-in will prompt on first connect.

Tools

Details

From the project README

@pipeworx/random-tables

Pipeworx original composable random tables for tabletop and narrative play — encounters, loot, weather, complications, NPC traits, plot hooks, tavern scenes, rumours and settlement quirks — with nested {{table:<id>}} references resolved recursively, plus caller-supplied custom tables. Keyless, no upstream, no COGS.

Part of Pipeworx — an MCP gateway connecting AI agents to 1872+ live data sources. This is an independent, unofficial integration — not affiliated with, endorsed by, or published by the upstream provider.

Tools

  • roll_table(table, count?, seed?, session_id?) — roll 1-20 entries from a built-in table. Returns both the raw entry text and the fully resolved text (nested {{table:<id>}} references expanded). Reproducible via seed.
  • roll_custom_table(entries, count?, seed?) — roll from a table YOU supply ([{text, weight?}]); entries may reference built-in tables the same way.
  • list_random_tables(genre?) — every built-in table's id, title, genre and entry count, optionally filtered to fantasy | scifi | modern.
  • get_random_table(table) — one built-in table in full, unresolved (raw entry text, so any {{table:<id>}} references are visible as written).

Built-in tables

encounters_fantasy, encounters_scifi, encounters_modern, loot, weather, complication, npc_personality, npc_secret, npc_occupation, plot_hook, tavern, rumour, settlement_quirk, npc_full (a composed sentence that nests npc_personality + npc_occupation + npc_secret in one roll — the worked example of nested references).

Genre-tagged tables (encounters_*, loot, tavern) are fantasy/scifi/modern flavored; the rest are genre-agnostic and apply under any list_random_tables genre filter.

Nested references

An entry's text may embed {{table:<id>}}, which is resolved by rolling a weighted entry from that table and substituting it in, recursively, up to 6 levels of nesting. A reference to an unknown table id, or a cycle (a table that ends up referencing itself through a chain of other references), is a loud error naming the offending id or the full chain — never a silent truncation or an empty substitution. roll_custom_table's caller-supplied entries may reference built-in tables the same way, but not other entries in the same custom table (a custom table has no id of its own to reference).

Randomness and reproducibility

Every rolling tool takes an optional seed; the seed actually used is always returned (in meta.seed), whether you supplied one or not. The same seed and arguments reproduce the same draw. These are content generators, not divination — there is no separate "meaning" layer to keep apart from interpretation; the table text is the result, and how you use it at the table is up to you.

Sessions

session_id on roll_table draws without replacement across calls — useful when you don't want the same loot item or the same rumour to repeat while a session is live. It is hosted-only, backed by the gateway's shared KV (injectCacheKv: true); the npm standalone package has no KV, so a call that passes session_id there gets back session_supported: false and a plain seeded roll instead (every tool still works without session_id regardless of environment).

There is no separate "open session" tool. Pass any string as session_id on your first call for a table — the response tells you plainly whether it continued an existing session or had to open a new one, and gives you the real session_id to reuse on your next call. Omit session_id entirely for an ordinary independent weighted roll (the common case; no KV needed). roll_custom_table has no session support — sessions only track built-in tables, which have a stable id and size to key a session on.

Auth

Keyless.

Data sources

Pipeworx original content. No upstream API, no third-party data. Every table and every entry is written for this pack — none of it is copied, paraphrased or adapted from any commercial tabletop RPG product, sourcebook or supplement.

What else to know

  • Zero-row answers are loud errors, not quiet empty lists: an unknown table id, an unknown genre filter, an unknown or cyclic nested reference, or an empty/invalid entries array for roll_custom_table all throw a specific error naming the valid set, rather than returning [] or {}.
  • roll_table's default count is 1; the cap is 20 for both rolling tools.
  • roll_custom_table accepts up to 500 caller-supplied entries.

Quick Start

Add to your MCP client (Claude Desktop, Cursor, Windsurf, etc.):

{
  "mcpServers": {
    "random-tables": {
      "url": "https://gateway.pipeworx.io/random-tables/mcp"
    }
  }
}
What this endpoint actually serves

tools/list at https://gateway.pipeworx.io/random-tables/mcp returns the tools in the table above plus the shared Pipeworx meta-tools — ask_pipeworx, discover_tools, search_within, remember/recall and the rest of the gateway-wide set. So the tool count you see is larger than this table: a single-pack endpoint currently lists roughly 30 shared tools alongside the pack's own. The connection's initialize response states its exact scope, and is the authoritative answer for a given day.

This is deliberate, not multiplexing by accident. The meta-tools are what let a scoped connection answer a question this pack does not cover — via ask_pipeworx, which routes across the whole catalog — without you adding a second MCP server. There is currently no way to mount a pack endpoint without them; if the extra schemas cost you more context than the routing is worth, connect to the full gateway once rather than to several pack endpoints.

Or connect to the full Pipeworx gateway to get every pack's tools listed directly, instead of just this one's:

{
  "mcpServers": {
    "pipeworx": {
      "url": "https://gateway.pipeworx.io/mcp"
    }
  }
}

Both URLs reach the same gateway and the same 1872+ data sources. The only difference is which pack's tools are listed directly; ask_pipeworx reaches all of them from either one.

No MCP client? Call it over HTTP

curl -X POST https://gateway.pipeworx.io/v1/tools/roll_table \
  -H 'Content-Type: application/json' \
  -d '{"table":"npc_full","count":2,"seed":"pw-smoke-1"}'

No account needed for the first calls. Inspect any tool: GET https://gateway.pipeworx.io/v1/tools/roll_table. Find one: POST https://gateway.pipeworx.io/v1/tools/search_packs with {"query":"..."}.

Standalone (no gateway account)

This package also runs as a local stdio MCP server — no Pipeworx account, no gateway round-trip:

{
  "mcpServers": {
    "random-tables": {
      "command": "npx",
      "args": ["-y", "@pipeworx/mcp-random-tables"]
    }
  }
}

Or run it directly to confirm it starts:

npx -y @pipeworx/mcp-random-tables

It speaks MCP over stdin/stdout and answers initialize/tools/list/tools/call for only this pack's tools — none of the shared meta-tools the gateway connection above adds. Same source, same tools, no ask_pipeworx routing.

Using with ask_pipeworx

Instead of calling tools directly, you can ask questions in plain English — this works on the pack endpoint above as well as on the full gateway:

ask_pipeworx({ question: "your question about Random Tables data" })

The gateway picks the right tool and fills the arguments automatically.

More

License

MIT

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.