A production-ready Model Context Protocol (MCP) server for private personal finance management.
Project description
Finance Intelligence MCP Server
Finance Intelligence MCP is a production-ready Model Context Protocol (MCP) server that enables AI assistants (like Claude, Cursor, and others) to securely manage and analyze personal finances through natural language.
Released under the MIT License and designed to be extended with additional finance tools.
๐ Overview
Unlike standard cloud-based personal finance apps, Finance Intelligence MCP keeps all financial data under your absolute control.
- No Accounts / Subscriptions: Direct connection to your private database with zero SaaS dependencies.
- Zero Telemetry: Your financial logs never go to external analytic APIs.
- Full AI Context: Your AI assistant can query history, check budget status, make charts, and answer financial questions instantly.
๐ ๏ธ Architecture
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ MCP Client โ
โ (Claude Desktop, Cursor, etc) โ
โโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโ
โ
โ (STDIO Transport Protocol)
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Finance Intelligence Server โ
โ (Local) โ
โโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโ
โ
โ (Direct SQL Pool Connection)
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ PostgreSQL Database โ
โ (Supabase, Local, RDS, etc) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โจ Features
- Expense Operations: Create, view, edit, and bulk-delete expense entries.
- Multi-level Budgeting: Set limits for
overallspending, specificcategorythresholds, or down to nestedsubcategorytargets. - Analytics Breakdowns: Aggregate expenses by category, subcategory, notes, or dates over weekly/monthly/yearly time blocks.
- Visual Charts: Exposes tools that generate Matplotlib line/bar charts of historical spending automatically.
- Excel Spreadsheet Export: Truncates long list responses and generates download-ready Excel spreadsheets for massive datasets.
- Financial Health Scoring: Calculates a deterministic financial health score grade based on 6 core personal finance KPIs.
โ๏ธ Requirements & Compatibility
- Transport:
stdio - Supported Platforms:
- Windows
- macOS
- Linux
- Python Compatibility: Python 3.10, 3.11, and 3.12 (Tested)
- Database: PostgreSQL 12+ (e.g. Supabase, RDS, or local Postgres)
- Supported Clients:
- Claude Desktop
- Cursor
- Compatible with any MCP client supporting stdio.
๐พ Installation & Setup
1. Quick Setup (Shortcut)
If you have uv installed, get started in 2 lines:
git clone https://github.com/Ronit-019/Finance-Intelligence-MCP.git
cd Finance-Intelligence-MCP
uv sync
2. Detailed Installation
Step A: Get a PostgreSQL Connection URL
The easiest, free option is Supabase:
- Go to Supabase and create a free project.
- Go to Project Settings (gear icon) > Database.
- Under Connection string, select URI and copy the string.
- Example:
postgresql://postgres.[your-project-ref]:[your-password]@aws-0-us-east-1.pooler.supabase.com:5432/postgres - (Replace
[your-password]with your database password).
- Example:
Step B: Clone the Repository
Clone the codebase to a directory on your machine:
git clone https://github.com/Ronit-019/Finance-Intelligence-MCP.git
cd Finance-Intelligence-MCP
Copy the absolute path of this directory (e.g. C:/Users/Admin/Desktop/Finance-Intelligence-MCP).
Note: Always use forward slashes (/) for paths in JSON configs.
Step C: Install Dependencies
If you do not have uv installed, install from the project metadata:
pip install -e .
3. Client Integration
Claude Desktop Setup
- Open your Claude configuration file (
claude_desktop_config.json):- Windows: Press
Win + R, paste%APPDATA%\Claude\claude_desktop_config.jsonand press Enter. - macOS: Paste
~/Library/Application Support/Claude/claude_desktop_config.jsonin Finder's Go to Folder.
- Windows: Press
- Add this entry to
mcpServers:
{
"mcpServers": {
"finance-intelligence": {
"command": "uv",
"args": [
"--directory",
"REPLACE_WITH_ABSOLUTE_PATH_TO_CLONED_DIRECTORY",
"run",
"python",
"main.py"
],
"env": {
"DATABASE_URL": "REPLACE_WITH_YOUR_SUPABASE_CONNECTION_STRING"
}
}
}
}
- Save and completely restart Claude Desktop.
Cursor IDE Setup
- Go to Settings > Features > MCP.
- Click + Add New MCP Server:
- Name:
Finance Intelligence - Type:
command - Command:
uv --directory "REPLACE_WITH_ABSOLUTE_PATH_TO_CLONED_DIRECTORY" run python main.py
- Name:
- Click + Add Env Var:
- Key:
DATABASE_URL - Value:
REPLACE_WITH_YOUR_SUPABASE_CONNECTION_STRING
- Key:
- Click Save and refresh.
๐ฌ Example Prompts
Once configured, try talking to your AI assistant:
- "Add โน250 for lunch today under food."
- "Show my spending breakdown this month."
- "Generate an Excel report of all my expenses between May and July."
- "Am I exceeding my monthly budget limit?"
- "How much did I spend on dining out this week?"
- "Calculate my monthly financial health score and give me feedback."
- "Generate a spending chart for the last 30 days."
๐ ๏ธ Available Tools
The server registers 12 core tools on the client:
| Tool Name | Parameters | Description |
|---|---|---|
add_expense |
date, amount, category, subcategory, note |
Inserts a new expense transaction. |
list_expenses |
start_date, end_date |
Lists transactions, exports to Excel if count > 50. |
expense_breakdown |
start_date, end_date, group_by, breakdown, category, subcategory |
Aggregates spending sums and counts. |
delete_expenses |
expense_ids, start_date, end_date, category, subcategory |
Deletes expenses matching filters. |
update_expenses |
expense_ids, filter_..., date, amount, category, subcategory, note |
Edits expense records. |
create_budget |
budget_type, amount, period, start_date, end_date, category, subcategory, budgets |
Registers new spending limits. |
list_budgets |
budget_type, category, subcategory, period |
Returns registered budgets. |
update_budgets |
budget_ids, filter_..., budget_type, amount, period, start_date, end_date, category, subcategory |
Modifies active budgets. |
delete_budgets |
budget_ids, start_date, end_date, budget_type, category, subcategory, period |
Deletes target budget limits. |
compare_budget_vs_expenses |
reference_date, budget_type, category, subcategory, period |
Compares budget vs actual spending. |
expense_summary |
period, group_by, category, subcategory, start_date, end_date |
Generates a Matplotlib line/bar chart. |
financial_health_score |
reference_month |
Evaluates 6 key personal finance indicators. |
๐ก Troubleshooting
1. uv: command not found
If the client cannot locate uv, update your config file to run standard Python:
- Ensure you ran
pip install -e .inside the repository. - Update config:
"finance-intelligence": {
"command": "python",
"args": [
"REPLACE_WITH_ABSOLUTE_PATH_TO_CLONED_DIRECTORY/main.py"
],
"env": {
"DATABASE_URL": "REPLACE_WITH_YOUR_SUPABASE_CONNECTION_STRING"
}
}
2. Invalid DATABASE_URL / PostgreSQL Connection Errors
- Make sure you replaced
[your-password]with your actual database password in the Supabase URI string. - Ensure there are no surrounding spaces or special characters in the URL string.
- Verify your Supabase instance is active and not paused.
3. Claude Not Detecting the Server
- Double check that the folder paths in
claude_desktop_config.jsonuse forward slashes (/), even on Windows. - Check the logs at
%APPDATA%\Claude\logs\mcp*.log(Windows) or~/Library/Logs/Claude/mcp*.log(macOS) to see the exact startup error.
๐ Repository Structure
โโโ src/ # Helper packages
โ โโโ __init__.py
โ โโโ budget.py # Budget database operations
โ โโโ analytics.py # Breakdown aggregations & Matplotlib routines
โ โโโ health.py # KPIs and financial health calculator
โโโ main.py # FastMCP Server application
โโโ categories.json # Category mapping catalog
โโโ pyproject.toml # Dependencies
โโโ LICENSE # MIT License file
โโโ README.md # This file
๐ค Contributing
Contributions, bug reports, and feature requests are welcome! Please open an issue before submitting major changes or pull requests.
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐จโ๐ป Author
Ronit Rajput
- Portfolio: https://ronitportfolio-seven.vercel.app/assistant
- GitHub: https://github.com/Ronit-019
- LinkedIn: https://www.linkedin.com/in/ronit-rajput/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file finance_intelligence_mcp-1.0.0.tar.gz.
File metadata
- Download URL: finance_intelligence_mcp-1.0.0.tar.gz
- Upload date:
- Size: 19.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
453431c8b4c02a33365a9f6dfddde865441e926c6a7686434d4c4d03ee162c9e
|
|
| MD5 |
c99b73377b43877baafe2c16e0d3bdee
|
|
| BLAKE2b-256 |
24390cda576ed3a2b52ced29445c8b82da7b6cc4530ee51e0e95f0ee15936fa4
|
File details
Details for the file finance_intelligence_mcp-1.0.0-py3-none-any.whl.
File metadata
- Download URL: finance_intelligence_mcp-1.0.0-py3-none-any.whl
- Upload date:
- Size: 15.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e6788b33b2d27dda0d8322d577da7498d160a626e7f648686b1a0b5073c661d8
|
|
| MD5 |
e07672a8696d91c22a16586af96d508b
|
|
| BLAKE2b-256 |
50b67f40a10f32a9b2ed00052e57a3ded5d46ba7952163c2f4ca89e13f6d460f
|