Monarch Money MCP Server

Monarch Money MCP Server

A Model Context Protocol (MCP) server that enables AI assistants to interact with your Monarch Money personal finance data. Manage accounts, transactions, budgets, and analyze your finances programmatically.

Category
访问服务器

README

Monarch Money MCP Server

A Model Context Protocol (MCP) server that enables AI assistants to interact with your Monarch Money personal finance data. Manage accounts, transactions, budgets, and analyze your finances programmatically.

Features

🔐 Authentication

  • Email/password login with MFA support
  • Session persistence (sessions last ~90 days)
  • Automatic session management

💰 Account Management

  • View all linked accounts (banks, credit cards, investments, etc.)
  • Get account balance history
  • View investment holdings
  • Create/update/delete manual accounts
  • Refresh account data

📊 Transaction Operations

  • Search and filter transactions
  • Create, update, and delete transactions
  • Split transactions across categories
  • Add tags and categories
  • Get transaction summaries

📈 Budget & Cashflow

  • View and set budgets by category
  • Get cashflow summaries
  • Analyze spending by category and merchant
  • Track income vs expenses

🏷️ Organization

  • Manage categories and tags
  • View recurring transactions
  • Link to financial institutions

Installation

npm install
npm run build

Configuration

Environment Variables

Set these environment variables for automatic authentication:

export MONARCH_EMAIL="your@email.com"
export MONARCH_PASSWORD="your_password"
export MONARCH_MFA_SECRET="your_mfa_secret_key"  # Optional

Getting your MFA Secret Key:

  1. Go to Monarch Money Settings → Security
  2. Enable MFA
  3. Copy the "Two-factor text code" (TOTP secret)
  4. Use this as your MONARCH_MFA_SECRET

Claude Desktop Configuration

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "monarch-money": {
      "command": "node",
      "args": ["/path/to/monarch-money-mcp/dist/index.js"],
      "env": {
        "MONARCH_EMAIL": "your@email.com",
        "MONARCH_PASSWORD": "your_password",
        "MONARCH_MFA_SECRET": "your_mfa_secret"
      }
    }
  }
}

Usage Examples

Authentication

// Login manually
await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_login",
  arguments: {
    email: "your@email.com",
    password: "your_password",
    mfa_secret_key: "optional_mfa_secret"
  }
});

// Check authentication status
await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_check_auth"
});

View Accounts

// Get all accounts
const accounts = await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_get_accounts"
});

// Get account balance history
const history = await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_get_account_history",
  arguments: {
    account_id: "account-uuid",
    start_date: "2025-01-01",
    end_date: "2025-01-31"
  }
});

Manage Transactions

// Get recent transactions
const transactions = await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_get_transactions",
  arguments: {
    limit: 50,
    start_date: "2025-01-01",
    end_date: "2025-01-31"
  }
});

// Create a new transaction
await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_create_transaction",
  arguments: {
    amount: -45.50,
    date: "2025-02-01",
    account_id: "account-uuid",
    merchant_name: "Coffee Shop",
    category_id: "category-uuid",
    notes: "Morning coffee"
  }
});

// Update existing transaction
await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_update_transaction",
  arguments: {
    transaction_id: "transaction-uuid",
    category_id: "new-category-uuid",
    notes: "Updated note"
  }
});

// Split a transaction
await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_update_transaction_splits",
  arguments: {
    transaction_id: "transaction-uuid",
    splits: [
      { amount: -30.00, category_id: "groceries-uuid" },
      { amount: -15.00, category_id: "household-uuid" }
    ]
  }
});

Budget Management

// Get current budgets
const budgets = await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_get_budgets"
});

// Set a budget
await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_set_budget_amount",
  arguments: {
    category_id: "category-uuid",
    amount: 500.00,
    date: "2025-02-01"
  }
});

Cashflow Analysis

// Get cashflow summary
const cashflow = await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_get_cashflow",
  arguments: {
    start_date: "2025-01-01",
    end_date: "2025-01-31"
  }
});

// Analyze spending by category
const byCategory = await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_get_cashflow_by_category",
  arguments: {
    start_date: "2025-01-01",
    end_date: "2025-01-31"
  }
});

// Top merchants
const byMerchant = await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_get_cashflow_by_merchant",
  arguments: {
    start_date: "2025-01-01",
    end_date: "2025-01-31",
    limit: 10
  }
});

Categories and Tags

// Get all categories
const categories = await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_get_categories"
});

// Create a new category
await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_create_category",
  arguments: {
    name: "Side Projects",
    icon: "💻"
  }
});

// Create and apply tags
await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_create_tag",
  arguments: {
    name: "Business Expense",
    color: "#4CAF50"
  }
});

await use_mcp_tool({
  server_name: "monarch-money",
  tool_name: "monarch_set_transaction_tags",
  arguments: {
    transaction_id: "transaction-uuid",
    tag_ids: ["tag-uuid-1", "tag-uuid-2"]
  }
});

API Reference

Authentication Tools

  • monarch_login - Login with email/password (supports MFA)
  • monarch_check_auth - Check authentication status

Account Tools

  • monarch_get_accounts - Get all accounts
  • monarch_get_account_history - Get balance history
  • monarch_get_account_holdings - Get investment holdings
  • monarch_get_account_types - List account types
  • monarch_create_manual_account - Create manual account
  • monarch_update_account - Update account details
  • monarch_delete_account - Delete account
  • monarch_refresh_accounts - Sync with institutions

Transaction Tools

  • monarch_get_transactions - Search transactions
  • monarch_get_transaction_details - Get transaction details
  • monarch_get_transaction_splits - Get split information
  • monarch_get_transactions_summary - Get summary stats
  • monarch_create_transaction - Create transaction
  • monarch_update_transaction - Update transaction
  • monarch_delete_transaction - Delete transaction
  • monarch_update_transaction_splits - Split transaction

Budget Tools

  • monarch_get_budgets - Get all budgets
  • monarch_set_budget_amount - Set/update budget

Cashflow Tools

  • monarch_get_cashflow - Get cashflow summary
  • monarch_get_cashflow_by_category - Breakdown by category
  • monarch_get_cashflow_by_merchant - Breakdown by merchant

Organization Tools

  • monarch_get_categories - Get categories
  • monarch_get_tags - Get tags
  • monarch_create_category - Create category
  • monarch_delete_category - Delete category
  • monarch_create_tag - Create tag
  • monarch_set_transaction_tags - Apply tags

Other Tools

  • monarch_get_recurring_transactions - View recurring transactions
  • monarch_get_subscription - Subscription details
  • monarch_get_institutions - Linked institutions

Development

Build

npm run build

Test with MCP Inspector

npm run inspector

Security Notes

  • Session Storage: Sessions are stored in ~/.monarch_session.json
  • Credentials: Never commit credentials to version control
  • MFA Recommended: Always enable MFA on your Monarch Money account
  • Environment Variables: Use environment variables or secure secret management

Common Use Cases

Monthly Budget Review

  1. Get budgets for current month
  2. Get actual spending by category
  3. Identify over-budget categories
  4. Adjust budgets as needed

Transaction Categorization

  1. Get uncategorized transactions
  2. Update categories based on merchant
  3. Add tags for tracking
  4. Split transactions if needed

Financial Analysis

  1. Get cashflow over time periods
  2. Analyze spending trends
  3. Identify top expenses
  4. Track savings rate

Account Management

  1. Create manual accounts for cash/assets
  2. Update balances regularly
  3. Track investment holdings
  4. Monitor account history

Troubleshooting

Authentication Issues

  • Verify email/password are correct
  • Check MFA secret key if using auto-MFA
  • Try deleting ~/.monarch_session.json and re-logging in

GraphQL Errors

  • Check Monarch Money API status
  • Verify account UUIDs are correct
  • Ensure dates are in YYYY-MM-DD format

Session Expiration

  • Sessions typically last ~90 days
  • Re-authenticate if receiving 401 errors
  • Save session after successful login

Credits

Built with:

Inspired by community Python libraries for Monarch Money API access.

License

MIT

Disclaimer

This is an unofficial MCP server for Monarch Money. It is not affiliated with, endorsed by, or connected to Monarch Money in any way. Use at your own risk.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选