MCP connectors and remote MCP
pi-roundtable-mcp is a separate npm package with two plugins.
Both work over MCP, the protocol agents use to call tools on another server.
| Plugin | What it does |
|---|---|
mcpConnectors |
You add an MCP server in Discord, such as Notion or a calendar. Your agents can then use its tools. |
remoteMcp |
An agent outside Discord can send your agent a message and read the answer. It can also use Discord channels you chose to give it. |
Together they cover both directions: your agents reach tools on other servers, and agents elsewhere reach yours.
The package now lives in the pi-roundtable workspace as packages/mcp; see its README for every option and message.
Install
Section titled “Install”bun add pi-roundtable-mcp pi-roundtableUse Bun 1.4.4 or newer and pi-roundtable >=0.50.0 <0.51.0; the package needs the host’s PostgreSQL.
mcpConnectors also needs a ContextForge gateway that you run yourself, see below.
remoteMcp needs an HTTPS address that reaches the host’s public listener, such as a tunnel.
Turn them on
Section titled “Turn them on”List the plugins in roundtable.config.ts:
import type { RoundtableConfig } from "pi-roundtable";import { mcpConnectors, remoteMcp } from "pi-roundtable-mcp";
const env = (name: string): string => process.env[name] ?? "";
export default { // ... the rest of your config plugins: [ mcpConnectors({ contextForge: { url: env("CONTEXTFORGE_URL"), jwtSecret: env("CONTEXTFORGE_JWT_SECRET"), user: env("CONTEXTFORGE_USER"), }, }), remoteMcp({ dispatchToken: env("MCP_DISPATCH_TOKEN"), publicUrl: env("PUBLIC_URL"), }), ],} satisfies RoundtableConfig;You can use either plugin on its own.
mcpConnectors requires contextForge.url, contextForge.jwtSecret, and contextForge.user; serverPrefix defaults to roundtable-conn-, maxToolName to 45, and messages overrides its English text.
remoteMcp requires dispatchToken and publicUrl; persona changes the default conversation prompt, answer and claim must be supplied together for host-managed conversations, messages customizes its text, and toolNames defaults to agent_dispatch and agent_result.
Connectors
Section titled “Connectors”/roundtable connector add opens a private form for the server’s address and token.
list, describe, resync and remove manage what you added; resync reads a connector’s tools from its server again (every connector’s when none is named), so a tool the server renamed is attached without adding the connector again.
Only the owner can use these commands.
ContextForge keeps each upstream server and its token. Run IBM’s open-source MCP gateway next to the host and give both the same JWT secret.
The plugin gives your code the connector list. Your code chooses connectors for each agent and builds its tools from that list. The package README has an example.
Remote MCP
Section titled “Remote MCP”The plugin serves two endpoints on the host’s public listener.
| Endpoint | Who can call it | What it gives |
|---|---|---|
/mcp/personal |
An agent that sends your dispatch token | Two tools. One starts or continues a conversation with your agent and returns at once. The other reads the answer when it is ready. |
/mcp/discord/<token> |
An agent that holds a bundle’s address | Discord tools for the channels you granted, and only for the operations you granted. |
You grant channels in Discord with /roundtable mcp authorize, in the channel you want to share.
The bot asks which operations to allow.
grants lists them, revoke removes a channel, and token replaces a bundle’s address.
The plugin checks every call when it arrives and writes it to an audit table. Revoking a grant or replacing an address stops calls already running. Grants are limited to operations both you and the bot can perform in that channel.
If your bot already runs its own conversations
Section titled “If your bot already runs its own conversations”By default remoteMcp runs the relayed message as an owner conversation on the core.
A host that has its own owner conversations can pass answer and claim instead, so the same code answers.
The README shows how.
Wording
Section titled “Wording”The plugins keep their text in English, and both take a messages option to change it.
Write it in your own language there, for the Discord text, the error messages and the tool descriptions.