Documentation

MCP server

Connect theoinvest to your coding agent (Claude Code, Cursor, Claude Desktop, …). The agent reads your product and codebase, fills a company brief, and calls these tools to scope → generate → refine/analyze → export a bottoms-up monthly financial model. Everything runs on your own stored provider keys.

Grounded scaffold, not a finished model. Code tells the agent what's real (products, pricing tiers, infra → COGS, rough headcount). It does not contain the assumptions that dominate a model — CAC, conversion, churn, market size, hiring plan. The agent should confirm those with you, and the output is a starting point you finish, not financial advice.

Prerequisites

  • A theoinvest account.
  • At least one AI provider key saved in Settings (the token runs on these keys).
  • Node.js 18+ — only needed for stdio-only clients that use the mcp-remotebridge (e.g. Claude Desktop, Zed). Native URL clients (Cursor, Warp, VS Code, …) don't need it.

1 · Create a personal API token

In Settings → Personal access tokens, create a token and copy it — it's shown only once and starts with theo_pat_. We store only a hash; revoke it anytime.

2 · Configure your client

Pick your editor below. The fastest path is the copy-pasteable AI prompt — paste it into that tool's agent and it sets up the server for you. Prefer to do it by hand? Use the manual config: point your client at the hosted endpoint https://theoinvest.app/api/mcp/mcp and send your token in the Authorization: Bearer … header. For local dev, use http://localhost:3060/api/mcp/mcp instead.

Config location: CLI (claude mcp add) — writes to ~/.claude.json / project .mcp.json

Copy this into Claude Code's agent

Paste it into the chat and it'll set up the server for you.

Set up the "theoinvest" MCP server in Claude Code. theoinvest turns a product/codebase into a bottoms-up financial model (tools: scope_model, generate_model, refine_model, analyze_model, export_model).

Do this:
1. Add an MCP server named "theoinvest" that connects over HTTP (Streamable HTTP):
   - URL: https://theoinvest.app/api/mcp/mcp (or my local URL http://localhost:3060/api/mcp/mcp for local dev)
   - Header: Authorization: Bearer <my token; ask me — it starts with theo_pat_>
   Run this in a terminal (fill in your token): claude mcp add --transport http theoinvest https://theoinvest.app/api/mcp/mcp --header "Authorization: Bearer theo_pat_xxx"
2. Run `claude mcp list` and confirm theoinvest shows as connected.
3. Verify the server is connected, list its tools (scope_model, generate_model, refine_model, analyze_model, export_model), and read the resource theoinvest://schema/company-brief to confirm it works.

Important: ask me for the token instead of inventing it, and keep my token out of any logs or committed files.

Or configure manually

claude mcp add --transport http theoinvest https://theoinvest.app/api/mcp/mcp \
  --header "Authorization: Bearer theo_pat_xxx"

Replace theo_pat_xxx with a personal access token from Settings.

3 · Verify

Inspect the server (lists tools and lets you run them) with the MCP Inspector:

npx @modelcontextprotocol/inspector

In the Inspector, set the transport to Streamable HTTP, enter https://theoinvest.app/api/mcp/mcp (or http://localhost:3060/api/mcp/mcp for local dev), and add an Authorization header with value Bearer <your token>. Connect, then read the theoinvest://schema/company-brief resource and run scope_modelgenerate_model export_model. A model JSON plus an inline file (base64) confirm the full path works.

Tools

  • scope_model— clarify/scope a brief; returns Theo's reply, questions, or a proposed plan.
  • generate_model — build a full monthly model (+ KPI summary) from the brief and optional plan. Can take a few minutes.
  • refine_model — apply a natural-language change to a model (structure-preserving).
  • analyze_model — deterministic checks plus an analyst-style review.
  • export_model — render the model as .xlsx, .csv, or a branded .pdf. Over the hosted endpoint the file is returned inline as base64(an MCP embedded resource) for your agent to save — it isn't written to disk server-side.

The company brief

Read the theoinvest://schema/company-brief resource for the full field list and what to infer from code vs. ask the user. Every field is optional; the richer the brief, the better the model. A minimal example:

{
  "companyName": "Acme",
  "description": "B2B SaaS that …",
  "stage": "seed",
  "businessModel": "subscription",
  "pricing": "3 tiers: $0 / $49 / $199 per seat / month",
  "currency": "USD",
  "periods": 36,
  "products": [{ "name": "Pro", "type": "subscription" }],
  "prompt": "Assumptions confirmed with the founder: CAC $1,200, 3% trial→paid, 2% monthly churn, hire 4 eng in year 1."
}

Example workflow

Once connected, prompt your agent in the repo, e.g.:

Read this repo, draft a theoinvest company brief from the code (products, pricing, infra), ask me for CAC / churn / hiring assumptions, then scope and generate a 36-month model and export it to Excel.

Troubleshooting

  • missing_token / 401 — the Authorization: Bearer … header is missing, or the token was revoked. Recheck the header, or create a new token in Settings.
  • missing_user_key — add a provider key in Settings; the token runs on your keys.
  • Long generations generate_model can run several minutes; the server streams progress. Give the client a generous timeout.
  • Wrong URL — point your client (or the mcp-remote URL argument) at https://theoinvest.app/api/mcp/mcp, or http://localhost:3060/api/mcp/mcp for local dev.

Security

  • Tokens are stored as a hash; the plaintext is shown once.
  • Your provider keys never leave the server — the MCP process only forwards your API token.
  • Revoke a token anytime in Settings; it stops working immediately.

Projections are estimates generated from your inputs — not financial advice.