Protocol Wealth · Open Source

← Back to Nexus Core

Connect to the MCP server

Nexus Core speaks the Model Context Protocol, so any MCP-compatible AI client can call its public demo tools. Remote clients may complete transparent OAuth with no login. You can use the hosted server or run your own.

Option A — Use the hosted server (no install)

The server is live at https://nexusmcp.site/mcp/ (MCP over HTTP / Streamable HTTP). Clients that support remote MCP servers can add that URL directly.

Claude.ai (web & desktop app)

Settings → Connectors → Add custom connector, paste the URL above, and add it. Claude completes a transparent authorization automatically — there is no account or login (nexus-core is public); you may briefly see an authorize step that approves itself. No OAuth Client ID needs to be entered.

Claude Code

Claude Code speaks remote MCP over HTTP. Add the hosted server with one command:

claude mcp add --transport http nexus-core https://nexusmcp.site/mcp/

or commit a .mcp.json to your project root so the whole team picks it up:

{
  "mcpServers": {
    "nexus-core": {
      "type": "http",
      "url": "https://nexusmcp.site/mcp/"
    }
  }
}

Run /mcp inside Claude Code to confirm the connection and see the tool list.

Claude Desktop

Claude Desktop connects to local processes, so bridge to the hosted URL with mcp-remote. Add this to your claude_desktop_config.json (Settings → Developer → Edit Config):

{
  "mcpServers": {
    "nexus-core": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://nexusmcp.site/mcp/"]
    }
  }
}

Config file location — macOS: ~/Library/Application Support/Claude/claude_desktop_config.json; Windows: %APPDATA%\Claude\claude_desktop_config.json. Restart Claude Desktop, then look for the nexus-core tools in the tools menu.

Other clients (Cursor, Cline, custom)

Most clients that support remote MCP servers accept the URL directly — point them at https://nexusmcp.site/mcp/ with the HTTP / Streamable-HTTP transport. Any MCP-compatible AI client (Claude, GPT, Gemini), or an agent platform such as SmythOS, can register this read-only endpoint the same way — no account or API key.

Tools not showing up? Fully quit and reopen Claude Desktop (not just close the window). mcp-remote needs Node 18+ (check node -v); if npx errors, run npx -y mcp-remote@latest https://nexusmcp.site/mcp/ once in a terminal to pre-cache it. For the claude.ai web connector, if it won't attach, remove and re-add it — the authorize step approves itself and needs no Client ID.

Option B — Run it locally (stdio)

Install from source (Python 3.12+), then run the stdio server:

pip install "nexus-core[mcp] @ git+https://github.com/Protocol-Wealth/nexus-core.git"

# optional: a free FRED API key sharpens the macro signals
export FRED_API_KEY=your_key

nexus-core mcp        # MCP server over stdio

Point Claude Desktop at the local command:

{
  "mcpServers": {
    "nexus-core": {
      "command": "nexus-core",
      "args": ["mcp"]
    }
  }
}
The local stdio server defaults to the full profile. The hosted /mcp endpoint currently uses the closed-world demo profile, so its tool list is intentionally smaller. Call tools/list after connecting; external integrations that need a key (e.g. FRED for macro precision) degrade gracefully when the key is absent.

Full-profile tools

AreaTools
Regimecurrent macro regime classification + raw signal readings
Scoring8-check EMF asset score on SEC EDGAR fundamentals
Marketquotes & OHLCV history (stocks, ETFs, indices, crypto)
EconomicFRED economic series
OptionsBlack-Scholes price + Greeks; covered-call / cash-secured-put / collar overlays
Crypto optionsDeribit instruments + IV/Greeks (BTC, ETH, SOL, XRP, TRX, AVAX)
DeFiDefiLlama TVL by protocol and chain
Planning34 PII-free tools: Monte Carlo, goal funding, deterministic cash flow, healthcare/LTC stress, education, income layering, inherited IRA analysis, risk profile scoring, allocation optimization, performance math, Roth/IRMAA, report assembly
Accountingfour de-identified tools: historical pricing, public-chain event decoding, account-scoped FIFO cost basis, and realized-PnL reporting

Everything is read-only, public, and educational — no side effects, no advice. The exact, always-current tool list is what your client shows after connecting (or call tools/list).

Try it — example prompts

Once connected, just ask in plain language; the client picks the tool and fills the arguments. A few prompts that exercise the regime engine and the planning tools end to end:

The planning tools take the request as a single JSON object in a body argument, matching the pwplan-core wire contract (contractVersion 0.1.0). The client assembles it from your prompt; inputs are de-identified — age, never date of birth.

Verify the connection

Inspect the server interactively with the official MCP Inspector:

# hosted
npx @modelcontextprotocol/inspector https://nexusmcp.site/mcp/

# local
npx @modelcontextprotocol/inspector nexus-core mcp

Connecting pwplan-core to nexus-core

pwplan-core is the open-source, browser-based financial-planning shell. It runs entirely in the browser and calls nexus-core's planning engine directly over HTTP — no SDK. These are plain REST endpoints (distinct from the MCP transport above). Production callers can send a Nexus service API key through the REST/JSON boundary when restricted mode is enabled.

The handshake

Call GET /api/planning/tools first — it returns the contract version and the available tool ids, so the client can confirm compatibility before sending any work:

GET https://nexusmcp.site/api/planning/tools
→ { "contractVersion": "0.1.0", "tools": [ ... ] }

The wire contract is contractVersion 0.1.0 — every successful tool response echoes it, and the client rejects a mismatch.

The planning tools

Invoke a tool with POST /api/planning/tools/{tool_id} and a JSON body. Legacy /mcp/tools aliases remain for older clients:

monte_carlo_decumulation takes an optional retirementAge: the portfolio accumulates untouched until that age, then decumulates. Omit it and the engine withdraws from currentAge; pwplan-core's UI defaults the field to 65. Optional spendSchedule entries adjust the gross spend after retirement age: delta adds a recurring bump/reduction over an age range, override replaces the base spend for an age range, and one_time adds a single lump expense. Optional guardrails enables Guyton-Klinger dynamic withdrawals. Optional ltcShock models a healthcare-cost stress and reports a same-seed with/without-shock impact; S12 v1 does not combine ltcShock with guardrails, so run those as separate scenarios. Inputs are de-identified — the engine is PII-free and works on age, never date of birth. Monte Carlo and scenario outputs are illustrative model results from hypothetical assumptions — not predictions or guarantees of any individual outcome.

A worked request — the primary tool

monte_carlo_decumulation over a de-identified portfolio. The response echoes contractVersion and carries successProbability with a Wilson interval, a terminalValues percentile map, medianBalanceByYear, depletionStats, sticky depletionCurve, conditionalShortfall, firstDecadeReturnVsOutcome deciles, and a regimePathSummary for the regime-aware models:

curl -s https://nexusmcp.site/mcp/tools/monte_carlo_decumulation \
  -H 'content-type: application/json' \
  -d '{
    "contractVersion": "0.1.0",
    "currentAge": 62, "retirementAge": 65, "horizonAge": 95,
    "accounts": [
      {"type": "traditional", "balance": 1200000,
       "allocation": {"us_equity": 0.6, "us_bonds": 0.4}}
    ],
    "assetClasses": [
      {"id": "us_equity", "label": "US Equity",
       "expectedReturn": 0.07, "volatility": 0.16, "lambda": 0.35},
      {"id": "us_bonds", "label": "US Bonds",
       "expectedReturn": 0.03, "volatility": 0.05, "lambda": 0.1}
    ],
    "annualSpend": 120000, "spendColaRate": 0.025,
    "guaranteedIncome": [
      {"label": "Social Security", "annualAmount": 42000,
       "startAge": 67, "colaRate": 0.02}
    ],
    "spendSchedule": [
      {"mode": "delta", "startAge": 91, "endAge": 95, "amount": 70000}
    ],
    "filingStatus": "married_joint", "returnModel": "emf_regime", "paths": 10000
  }'