Bookie

io.github.yuens1002由 GitHub 账号 yuens1002 发布v0.8.5更新于 Oct 24, 2026

Double-entry bookkeeping MCP server — import bank CSVs, categorize, reconcile, tax reports.

概览

AI 生成的概览

Bookie 是一个复式记账 MCP 服务器,让助手导入银行 CSV、分类支出、对账并生成税务报表。

可以做什么
Bookie 在助手背后维护正确的复式账簿,使用整数分金额计算和确定性的分类规则。工具涵盖创建与归档账户、记录平衡交易、将一笔付款拆分到多个类别、导入银行或信用卡 CSV(支持预览与去重)、管理自动分类规则、重新分类条目、对账、附加收据,以及生成或导出月度与财年报表(如 Schedule C 和 Schedule E)。它还提供账户与年度报表资源,以及月末结账、分类未分类条目和税务汇总的预设提示。
适用场景
适合已经在支持 MCP 的助手中工作、希望账目真正准确而非临时拼凑电子表格的自由职业者、个体经营者和出租房产业主。不适合想要仪表盘界面、多用户访问,或已满足于 QuickBooks 的用户。
运行要求
需要 Node 24 或更高版本、一个 Neon Postgres 数据库(安装 neonctl 并注册免费 Neon 账户用于初始化),以及支持 MCP 的宿主,如 Claude Desktop、Claude.ai、Cursor 或 VS Code。必需的密钥为 BOOKIE_DB_URL、BOOKIE_DB_DIRECT_URL 和 BOOKIE_API_KEY,由初始化脚本打印。可选的邮件与收据存储需要 RESEND_API_KEY、RESEND_FROM 以及 AWS 存储桶凭据。
安装前请注意
财务数据存放在你的 Neon Postgres 数据库中,连接字符串和 BOOKIE_API_KEY 不得提交到版本控制。HTTP 传输要求每个请求都经过认证;在暴露到 localhost 之外前应设置 Bearer 令牌或 OAuth。相关工具会写入、修改和删除账簿数据、收据与规则,send_report 会通过 Resend 发送报表邮件,因此在提交导入或对账前请先确认预览。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Bookie,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

bookie

[npm] [Publish to npm]

An MCP server that keeps books for freelancers and landlords — driven from Claude or GPT instead of QuickBooks.

Ask your LLM to import a bank statement, categorize spending, reconcile a month, or generate a Schedule C. Bookie provides the correct double-entry ledger underneath — so the model reasons over real numbers, not a spreadsheet it's improvising on the fly.

This is for you if: you're a solopreneur, freelancer, or rental property owner already living in Claude or GPT, you're comfortable with a 5-minute setup, and you want books that are actually correct.

Not for you if: you want a dashboard UI, you need multi-user access, or you're satisfied with QuickBooks / a spreadsheet.

What you need before starting

  • Node ≥ 24
  • neonctl — npm install -g neonctl (free Neon account; needed for the DB)
  • An MCP-capable host: Claude Desktop, Claude.ai, Cursor, VS Code, or any host supporting the MCP stdio or HTTP transport

Quick start (local, stdio)

Recommended — from source, fully automated:

bash
git clone https://github.com/yuens1002/bookiecd bookienpm installnpm run setup   # creates Neon DB, generates secrets, writes .env, runs db:pushnpm run build

npm run setup opens a browser to log into Neon; new to Neon? Use the "Sign up for an account" link and pick GitHub/Google/Microsoft rather than email+password — it completes in the same browser round-trip, no email-verification detour that could interrupt the CLI mid-wait.

npm run setup prints a ready-to-paste Claude Desktop config block at the end:

json
{  "mcpServers": {    "bookie": {      "command": "node",      "args": ["/absolute/path/to/bookie/dist/index.js"],      "env": {        "BOOKIE_DB_URL": "<printed by setup>",        "BOOKIE_DB_DIRECT_URL": "<printed by setup>",        "BOOKIE_API_KEY": "<printed by setup>"      }    }  }}

Adding another machine to the same ledger — no clone needed: stdio is a local process — every machine running a stdio MCP client spawns its own copy of the server, so each one otherwise needs its own checkout. Once the Neon DB is provisioned (via npm run setup above, on any one machine), every other machine just needs the same connection strings — no git clone, no npm install, no npm run build to keep in sync. Point that machine's MCP host at the published package instead:

json
{  "mcpServers": {    "bookie": {      "command": "npx",      "args": ["-y", "bookie-mcp"],      "env": {        "BOOKIE_DB_URL": "<same value as your first machine>",        "BOOKIE_DB_DIRECT_URL": "<same value as your first machine>",        "BOOKIE_API_KEY": "<same value as your first machine>"      }    }  }}

npx fetches and runs the published version on demand — every machine pointed at the same BOOKIE_DB_URL shares one ledger, without any of them (besides the original) needing a checkout.

Bootstrapping a DB without cloning at all: if you don't have connection strings yet from any machine (e.g. you created the Neon project manually instead of via npm run setup), push bookie's bundled schema directly:

bash
mkdir bookie-mcp && cd bookie-mcpnpm install bookie-mcpBOOKIE_DB_URL=<pooled> BOOKIE_DB_DIRECT_URL=<direct> npx prisma db push --schema=node_modules/bookie-mcp/prisma/schema.prisma

Then use the same npx -y bookie-mcp config above.

Quick start (remote, HTTP — for Claude.ai mobile)

Deploy to Railway with one click:

[Deploy on Railway]

Railway pulls the pre-built image from GHCR — no source build needed. Set the required env vars when prompted. See docs/DEPLOYING.md for the full walkthrough (env var reference, Neon + Resend setup, Claude.ai OAuth connector).

Why no UI?

The host LLM already reads CSVs, sees receipt images, and writes prose. Bookie owns the things an LLM shouldn't improvise: a correct double-entry ledger, integer-cent money math, deterministic categorization rules, and reproducible reports. The model handles language and vision; the server handles the books.

Tools

The full, always-current tool reference lives in docs/TOOLS.md (regenerate with npm run docs:tools). Today:

ToolWhat it does
manage_accountsCreate/list/archive accounts (segment-scoped categories carry a tax line)
add_transactionRecord one balanced double-entry (money flows from → to)
split_transactionOne payment leg + N category legs (a receipt split across categories)
import_transactionsImport a bank/card CSV as balanced entries — preview → confirm, with dedup
manage_rulesCreate/list/delete/test/suggest auto-categorization rules (categorize → account/property, or exclude) that power import-preview suggestions; action=suggest scans past categorizations and returns candidate rules for descriptions with 2+ occurrences
categorize_transactionRe-categorize the income/expense leg of an existing entry — explicit account or apply a stored rule
reconcileMatch a bank/card statement CSV against the ledger and mark postings cleared — preview then commit
manage_receiptsAttach, list, delete, or get a signed download URL for receipt data; optionally upload the original file (JPEG, PNG, WEBP, HEIC, or PDF) to Railway Bucket storage
generate_reportMonthly reconciliation summary, or fiscal-year Schedule C / Schedule E tax P&L
export_reportRender any report as markdown or CSV
send_reportRun a report and email it via Resend
query_transactionsList entries + postings by date range / account
account_balancesCurrent balance per account

Resources

Bookie exposes two MCP resources that an LLM can read without calling a tool:

Resource URIMIME typeWhat it contains
bookie://accountsapplication/jsonAll active accounts with their current balances
bookie://reports/{year}text/markdownAnnual fiscal snapshot: Schedule C, Schedule E, and a one-row-per-month summary (opening balance, net income, cleared postings count)

Prompts

Three canned workflow prompts guide the LLM through common bookkeeping tasks:

PromptParametersPurpose
monthly-closeyear, monthStep-by-step month-end close: import CSV → categorize → reconcile → report → (optional) email
categorize-uncategorized(none)Find journal entries with no income/expense leg and walk through categorizing each
prepare-tax-summaryyearGenerate Schedule C + E, export as markdown and CSV, optionally email

Configuration

See .env.example for the full reference. Key variables:

VariablePurpose
BOOKIE_TRANSPORTstdio (default) or http
BOOKIE_DB_URLNeon pooled connection string
BOOKIE_DB_DIRECT_URLNeon direct connection string (for db push)
BOOKIE_API_KEYStatic Bearer token (Claude Desktop / direct API)
PUBLIC_URLPublic HTTPS base URL of the deployed server (Claude.ai connector)
JWT_SECRETHS256 signing secret for OAuth JWT access tokens
OAUTH_CLIENT_IDOAuth client ID (default: claude-ai-connector)
OAUTH_CLIENT_SECRETRequired when using OAuth: /authorize refuses all requests when unset (prevents any visitor from authorizing); /token also validates it. Enter this value in the Claude.ai connector settings.
RESEND_API_KEYResend API key for send_report
RESEND_FROMVerified sender address for send_report (e.g. Bookie <[email protected]>)
AWS_ENDPOINT_URL / AWS_S3_BUCKET_NAME / AWS_ACCESS_KEY_ID / AWS_SECRET_ACCESS_KEY / AWS_DEFAULT_REGIONRailway Bucket credentials — auto-injected when you connect a bucket to the service (use AWS SDK Generic style); enables receipt file upload in manage_receipts

Docs

Safety

Bookie stores financial data in your Neon Postgres database; connection strings live in .env (gitignored) and Railway env vars — never commit them. The HTTP transport requires auth on every /mcp request: either a static Bearer token (BOOKIE_API_KEY) or an OAuth JWT issued by the /token endpoint. Always set at least one before exposing the server beyond localhost. See docs/DEPLOYING.md for the full Claude.ai connector OAuth setup.

License

MIT

来源:README.md,提交 02ca240

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v0.8.5最新Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分