Skip to main content
Glama
Expense Tracker MCP

Expense Tracker MCP

by BRachana

Expense Tracker MCP

A powerful FastMCP server for tracking expenses with full CRUD, budgets, recurring expenses, and reporting capabilities.

Quick Start

Local Development:

# Install dependencies
uv sync

# Run server
uv run python main.py

# Test with inspector
uv run fastmcp inspector main.py:mcp

Horizon Deployment: See HORIZON_SETUP.md for step-by-step instructions.

Related MCP server: Trackor

Features

Core:

  • ✅ Add, update, delete, and list expenses

  • ✅ Categorized expenses with subcategories

  • ✅ Case-insensitive category matching with fuzzy suggestions

Advanced:

  • ✅ Monthly budgets with spending alerts

  • ✅ Recurring expenses (auto-generate monthly)

  • ✅ CSV export with filtering

  • ✅ Monthly trend reports

API:

  • 🛠️ 14 Tools - Full expense management

  • 📖 3 Resources - Recent, summary, categories

  • 💬 2 Prompts - Weekly report, categorize expense

Directory Structure

data/          → Database (expenses.db)
config/        → Configuration (categories.json)
exports/       → Generated CSV files
logs/          → Application logs

See DIRECTORY_STRUCTURE.md for details.

Tools

Tool

Purpose

add_expense

Add new expense

get_expense

Get expense by ID

update_expense

Update expense

delete_expense

Delete expense

list_expenses

List all expenses

summarize_expenses

Summary by category

set_budget

Set category budget

check_budget_status

Check budget usage

add_recurring_expense

Add recurring item

list_recurring_expenses

List recurring items

generate_due_recurring_expenses

Generate due items

export_expenses_csv

Export to CSV

monthly_report

Monthly analytics

Environment Variables

EXPENSE_TRACKER_DB_PATH=/path/to/expenses.db          # Database location
EXPENSE_TRACKER_CONFIG_PATH=/path/to/categories.json  # Config location

Technology Stack

  • Python 3.12+

  • FastMCP 3.4.7+ - MCP server framework

  • aiosqlite - Async SQLite

  • asyncio - Async I/O

Deployment

Local: uv run python main.py

Docker:

docker build -t expense-tracker .
docker run -v expense_data:/data expense-tracker

Horizon: See HORIZON_SETUP.md

License

MIT

Available Tools

13 tools
add_expenseC

Add a new expense to the tracker.

Inputs: amount (required), category (required), description (required), subcategory, +1 more. Returns: object

add_recurring_expenseC

Add a recurring monthly expense.

Inputs: amount (required), category (required), description (required), subcategory, +1 more. Returns: object

check_budget_statusC

Check spending against budget for a category/month.

Inputs: month, category. Returns: object

delete_expenseB

Delete an expense.

Inputs: expense_id (required). Returns: object

export_expenses_csvB

Export expenses to a CSV file.

Inputs: category, end_date, start_date. Returns: object

generate_due_recurring_expensesB

Generate expenses for recurring items that are due.

Inputs: no named parameters. Returns: object

get_expenseA

Get a single expense by ID.

Inputs: expense_id (required). Returns: object

list_expensesA

List all expenses or filter by category.

Inputs: category. Returns: result

list_recurring_expensesC

List all recurring expenses.

Inputs: active_only. Returns: result

monthly_reportC

Generate a monthly expense report.

Inputs: months. Returns: object

set_budgetA

Set or update a budget for a category.

Inputs: category (required), monthly_limit (required). Returns: object

summarize_expensesB

Summarize expenses by category with optional date range and category filter.

Inputs: category, end_date, start_date. Returns: object

update_expenseC

Update an existing expense.

Inputs: expense_id (required), amount, category, description, +2 more. Returns: object

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.1/5.0

    Scored across 13 tools

    Disambiguation4/5

    Most tools target a clear, distinct action: CRUD operations on expenses, recurring expenses, budgets, and reporting. Some overlap exists between monthly_report and summarize_expenses, as both provide aggregated views, but their descriptions sufficiently clarify the monthly vs. customizable category/date scope.

    Naming Consistency4/5

    The majority of tools follow a consistent verb_noun snake_case pattern (add_expense, get_expense, list_expenses, set_budget). The main deviation is monthly_report, which is a noun phrase rather than a verb-led name, making the set slightly less uniform but still predictable.

    Tool Count5/5

    Thirteen tools is appropriate for an expense tracker covering core CRUD, recurring expenses, budgets, reporting, and export. Each tool addresses a meaningful aspect of the domain without excessive duplication or unnecessary surface area.

    Completeness4/5

    Expense CRUD is complete, with solid support for recurring expense generation, budgets, summaries, and export. Minor gaps exist: recurring expenses can be added and listed but not updated or deleted, and there is no explicit budget deletion, though these are workable limitations.

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables users to track and manage personal expenses through natural language, including adding entries, filtering by date/category, viewing statistics, and exporting data in JSON or CSV format.
      3
      -
    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables users to track expenses by adding, listing, and summarizing them with category support through natural language.
      -
    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables AI-driven expense tracking and budget management, including adding expenses, setting budgets, analyzing trends, forecasting, and managing savings goals via natural language.
      -